[PyObjC-svn] r2406 - in trunk/pyobjc/pyobjc-framework-Cocoa: Lib/AppKit Lib/CoreFoundation Lib/Foundation Modules PyObjCTest
[email protected] Sun, 07 Feb 2010 13:20:54 -0600
| Newsgroups | gmane.comp.python.pyobjc.cvs |
|---|---|
| Message-ID | <[email protected]> |
Author: ronaldoussoren
Date: Sun Feb 7 13:20:53 2010
New Revision: 2406
Log:
Fix most, if not all, 64-bit issues in the Cocoa wrappers.
Modified:
trunk/pyobjc/pyobjc-framework-Cocoa/Lib/AppKit/PyObjC.bridgesupport
trunk/pyobjc/pyobjc-framework-Cocoa/Lib/CoreFoundation/PyObjC.bridgesupport
trunk/pyobjc/pyobjc-framework-Cocoa/Lib/Foundation/PyObjC.bridgesupport
trunk/pyobjc/pyobjc-framework-Cocoa/Modules/_AppKit_nsbitmap.m
trunk/pyobjc/pyobjc-framework-Cocoa/Modules/_AppKit_nsview.m
trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_convenience.py
trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsarray.py
trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsatstypesetter.py
trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsbitmapimagerep.py
trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nscolor.py
trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsdictionary.py
trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsgraphicscontext.py
trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsmatrix.py
trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsnumber.py
trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsopenpanel.py
trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsview.py
Modified: trunk/pyobjc/pyobjc-framework-Cocoa/Lib/AppKit/PyObjC.bridgesupport
==============================================================================
--- trunk/pyobjc/pyobjc-framework-Cocoa/Lib/AppKit/PyObjC.bridgesupport (original)
+++ trunk/pyobjc/pyobjc-framework-Cocoa/Lib/AppKit/PyObjC.bridgesupport Sun Feb 7 13:20:53 2010
@@ -2123,8 +2123,8 @@
<arg type='@' type64='@' />
<arg type='@' type64='@' />
<arg type='@' type64='@' />
- <arg sel_of_type='v@:@i^v' type=':' />
- <arg sel_of_type='v@:@i^v' type=':' type64=':' />
+ <arg sel_of_type='v@:@i^v' sel_of_type64='v@:@q^v' type=':' />
+ <arg sel_of_type='v@:@i^v' sel_of_type64='v@:@q^v' type=':' type64=':' />
<arg type='^v' type64='^v' />
<arg type='@' type64='@' printf_format='true' />
</function>
@@ -2136,8 +2136,8 @@
<arg type='@' type64='@' />
<arg type='@' type64='@' />
<arg type='@' type64='@' />
- <arg sel_of_type='v@:@i^v' type=':' />
- <arg sel_of_type='v@:@i^v' type=':' type64=':' />
+ <arg sel_of_type='v@:@i^v' sel_of_type64='v@:@q^v' type=':' />
+ <arg sel_of_type='v@:@i^v' sel_of_type64='v@:@q^v' type=':' type64=':' />
<arg type='^v' type64='^v' />
<arg type='@' type64='@' printf_format='true' />
</function>
@@ -2149,8 +2149,8 @@
<arg type='@' type64='@' />
<arg type='@' type64='@' />
<arg type='@' type64='@' />
- <arg sel_of_type='v@:@i^v' type=':' />
- <arg sel_of_type='v@:@i^v' type=':' type64=':' />
+ <arg sel_of_type='v@:@i^v' sel_of_type64='v@:@q^v' type=':' />
+ <arg sel_of_type='v@:@i^v' sel_of_type64='v@:@q^v' type=':' type64=':' />
<arg type='^v' type64='^v' />
<arg type='@' type64='@' printf_format='true' />
</function>
@@ -2700,9 +2700,9 @@
<informal_protocol name='NSDraggingDestination'>
<method selector='concludeDragOperation:' type='v@:@' />
<method selector='draggingEnded:' type='v@:@' />
- <method selector='draggingEntered:' type='I@:@' />
+ <method selector='draggingEntered:' type='I@:@' type64='Q@:@'/>
<method selector='draggingExited:' type='v@:@' />
- <method selector='draggingUpdated:' type='I@:@' />
+ <method selector='draggingUpdated:' type='I@:@' type64='Q@:@'/>
<method selector='performDragOperation:' type='B@:@' />
<method selector='prepareForDragOperation:' type='B@:@' />
<method selector='wantsPeriodicDraggingUpdates' type='B@:' />
@@ -2710,9 +2710,9 @@
<informal_protocol name='NSDraggingSource'>
<method selector='draggedImage:beganAt:' type='v@:@{_NSPoint=ff}' type64='v@:@{CGPoint=dd}' />
<method selector='draggedImage:endedAt:deposited:' type='v@:@{_NSPoint=ff}B' type64='v@:@{CGPoint=dd}B' />
- <method selector='draggedImage:endedAt:operation:' type='v@:@{_NSPoint=ff}I' />
+ <method selector='draggedImage:endedAt:operation:' type='v@:@{_NSPoint=ff}I' type64='v@:@{CGPoint=dd}I' />
<method selector='draggedImage:movedTo:' type='v@:@{_NSPoint=ff}' type64='v@:@{CGPoint=dd}' />
- <method selector='draggingSourceOperationMaskForLocal:' type='I@:B' />
+ <method selector='draggingSourceOperationMaskForLocal:' type='I@:B' type64='Q@:B'/>
<method selector='ignoreModifierKeysWhileDragging' type='B@:' />
<!-- <method selector='namesOfPromisedFilesDroppedAtDestination:' type='@@:@' /> -->
</informal_protocol>
@@ -2747,7 +2747,7 @@
</informal_protocol>
<informal_protocol name='NSImageDelegate'>
<method selector='image:didLoadPartOfRepresentation:withValidRows:' type='v@:@@i' type64='v@:@@q' />
- <method selector='image:didLoadRepresentation:withStatus:' type='v@:@@I' />
+ <method selector='image:didLoadRepresentation:withStatus:' type='v@:@@I' type64='v@:@@Q'/>
<method selector='image:didLoadRepresentationHeader:' type='v@:@@' />
<method selector='image:willLoadRepresentation:' type='v@:@@' />
<method selector='imageDidNotDraw:inRect:' type='@@:@{_NSRect={_NSPoint=ff}{_NSSize=ff}}' type64='@@:@{CGRect={CGPoint=dd}{CGSize=dd}}' />
@@ -2792,7 +2792,7 @@
<method selector='outlineView:persistentObjectForItem:' type='@@:@@' /> -->
<method selector='outlineView:setObjectValue:forTableColumn:byItem:' type='v@:@@@@' />
<method selector='outlineView:sortDescriptorsDidChange:' type='v@:@@' />
- <method selector='outlineView:validateDrop:proposedItem:proposedChildIndex:' type='I@:@@@i' />
+ <method selector='outlineView:validateDrop:proposedItem:proposedChildIndex:' type='I@:@@@i' type64='Q@:@@@q' />
<method selector='outlineView:writeItems:toPasteboard:' type='B@:@@@' />
</informal_protocol>
<informal_protocol name='NSOutlineViewDelegate'>
@@ -2837,9 +2837,9 @@
<method class_method='true' selector='setDefaultPlaceholder:forMarker:withBinding:' type='v@:@@@' />
</informal_protocol>
<informal_protocol name='NSRuleEditorDelegateMethods'>
- <method selector='ruleEditor:child:forCriterion:withRowType:' type='@@:@i@I' />
+ <method selector='ruleEditor:child:forCriterion:withRowType:' type='@@:@i@I' type64='@@:@q@Q' />
<method selector='ruleEditor:displayValueForCriterion:inRow:' type='@@:@@i' type64='@@:@@q' />
- <method selector='ruleEditor:numberOfChildrenForCriterion:withRowType:' type='i@:@@I' />
+ <method selector='ruleEditor:numberOfChildrenForCriterion:withRowType:' type='i@:@@I' type64='q@:@@Q'/>
<method selector='ruleEditor:predicatePartsForCriterion:withDisplayValue:inRow:' type='@@:@@@i' type64='@@:@@@q' />
<method selector='ruleEditorRowsDidChange:' type='v@:@' />
</informal_protocol>
@@ -2891,12 +2891,12 @@
</informal_protocol>
<informal_protocol name='NSTableDataSource'>
<method selector='numberOfRowsInTableView:' type='i@:@' type64='q@:@' />
- <method selector='tableView:acceptDrop:row:dropOperation:' type='B@:@@iI' />
+ <method selector='tableView:acceptDrop:row:dropOperation:' type='B@:@@iI' type64='B@:@@qQ' />
<!-- <method selector='tableView:namesOfPromisedFilesDroppedAtDestination:forDraggedRowsWithIndexes:' type='@@:@@@' /> -->
<method selector='tableView:objectValueForTableColumn:row:' type='@@:@@i' type64='@@:@@q' />
<method selector='tableView:setObjectValue:forTableColumn:row:' type='v@:@@@i' type64='v@:@@@q' />
<method selector='tableView:sortDescriptorsDidChange:' type='v@:@@' />
- <method selector='tableView:validateDrop:proposedRow:proposedDropOperation:' type='I@:@@iI' />
+ <method selector='tableView:validateDrop:proposedRow:proposedDropOperation:' type='I@:@@iI' type64='Q@:@@qQ'/>
<method selector='tableView:writeRows:toPasteboard:' type='B@:@@@' />
<method selector='tableView:writeRowsWithIndexes:toPasteboard:' type='B@:@@@' />
</informal_protocol>
@@ -2971,7 +2971,7 @@
<method selector='tokenFieldCell:readFromPasteboard:' type='@@:@@' />
<method selector='tokenFieldCell:representedObjectForEditingString:' type='@@:@@' /> -->
<method selector='tokenFieldCell:shouldAddObjects:atIndex:' type='@@:@@I' type64='@@:@@Q' />
- <method selector='tokenFieldCell:styleForRepresentedObject:' type='I@:@@' />
+ <method selector='tokenFieldCell:styleForRepresentedObject:' type='I@:@@' type64='Q@:@@'/>
<method selector='tokenFieldCell:writeRepresentedObjects:toPasteboard:' type='B@:@@@' />
</informal_protocol>
<informal_protocol name='NSTokenFieldDelegate'>
@@ -3144,11 +3144,11 @@
</method>
<method selector='shouldBreakLineByHyphenatingBeforeCharacterAtIndex:'>
<retval type='B' />
- <arg index='0' type='I' />
+ <arg index='0' type='I' type64='Q' />
</method>
<method selector='shouldBreakLineByWordBeforeCharacterAtIndex:'>
<retval type='B' />
- <arg index='0' type='I' />
+ <arg index='0' type='I' type64='Q' />
</method>
<method selector='substituteGlyphsInRange:withGlyphs:'>
<arg index='0' type='{_NSRange=II}' type64='{_NSRange=QQ}' />
@@ -5734,7 +5734,7 @@
</method>
<method selector='sortUsingFunction:context:'>
<arg index='0' function_pointer='true' function_pointer_retained='false'>
- <retval type='i'/>
+ <retval type='i' type64='q'/>
<arg type='@' />
<arg type='@' />
<arg type='@' />
@@ -5742,7 +5742,7 @@
<arg index='1' type='@' />
</method>
<method selector='sortUsingSelector:'>
- <arg index='0' sel_of_type='i@:@' />
+ <arg index='0' sel_of_type='i@:@' sel_of_type64='q@:@' />
</method>
<method selector='tabKeyTraversesCells'>
<retval type='B' />
@@ -6431,7 +6431,7 @@
</method>
<method selector='draggedImage:endedAt:operation:'>
<arg index='1' type='{_NSPoint=ff}' type64='{CGPoint=dd}' />
- <arg index='2' type='I' />
+ <arg index='2' type='I' type64='Q' />
</method>
<method selector='draggedImage:movedTo:'>
<arg index='1' type='{_NSPoint=ff}' type64='{CGPoint=dd}' />
@@ -6440,7 +6440,7 @@
<retval type='{_NSPoint=ff}' type64='{CGPoint=dd}' />
</method>
<method selector='draggingEntered:'>
- <retval type='I' />
+ <retval type='I' type64='Q' />
</method>
<method selector='draggingLocation'>
<retval type='{_NSPoint=ff}' type64='{CGPoint=dd}' />
@@ -6449,14 +6449,14 @@
<retval type='i' type64='q' />
</method>
<method selector='draggingSourceOperationMask'>
- <retval type='I' />
+ <retval type='I' type64='Q' />
</method>
<method selector='draggingSourceOperationMaskForLocal:'>
- <retval type='I' />
+ <retval type='I' type64='Q' />
<arg index='0' type='B' />
</method>
<method selector='draggingUpdated:'>
- <retval type='I' />
+ <retval type='I' type64='Q' />
</method>
<method selector='drawWithFrame:inView:'>
<retval type='v' />
@@ -6515,7 +6515,7 @@
<arg index='2' type='i' type64='q' />
</method>
<method selector='image:didLoadRepresentation:withStatus:'>
- <arg index='2' type='I' />
+ <arg index='2' type='I' type64='Q' />
</method>
<method selector='imageDidNotDraw:inRect:'>
<arg index='1' type='{_NSRect={_NSPoint=ff}{_NSSize=ff}}' type64='{CGRect={CGPoint=dd}{CGSize=dd}}' />
@@ -6673,7 +6673,7 @@
<arg index='5' type='{_NSPoint=ff}' type64='{CGPoint=dd}' />
</method>
<method selector='outlineView:validateDrop:proposedItem:proposedChildIndex:'>
- <retval type='I' />
+ <retval type='I' type64='Q' />
<arg index='3' type='i' type64='q' />
</method>
<method selector='outlineView:writeItems:toPasteboard:'>
@@ -6709,7 +6709,7 @@
<retval type='B' />
</method>
<method selector='pathControl:validateDrop:'>
- <retval type='I' />
+ <retval type='I' type64='Q' />
</method>
<method selector='pathControl:willDisplayOpenPanel:'>
<retval type='v' />
@@ -6731,14 +6731,14 @@
</method>
<method selector='ruleEditor:child:forCriterion:withRowType:'>
<arg index='1' type='i' type64='q' />
- <arg index='3' type='I' />
+ <arg index='3' type='I' type64='Q' />
</method>
<method selector='ruleEditor:displayValueForCriterion:inRow:'>
<arg index='2' type='i' type64='q' />
</method>
<method selector='ruleEditor:numberOfChildrenForCriterion:withRowType:'>
<retval type='i' type64='q' />
- <arg index='2' type='I' />
+ <arg index='2' type='I' type64='Q' />
</method>
<method selector='ruleEditor:predicatePartsForCriterion:withDisplayValue:inRow:'>
<arg index='3' type='i' type64='q' />
@@ -6852,7 +6852,7 @@
<method selector='tableView:acceptDrop:row:dropOperation:'>
<retval type='B' />
<arg index='2' type='i' type64='q' />
- <arg index='3' type='I' />
+ <arg index='3' type='I' type64='Q' />
</method>
<method selector='tableView:dataCellForTableColumn:row:'>
<retval type='@' />
@@ -6908,9 +6908,9 @@
<arg index='2' type='i' type64='q' />
</method>
<method selector='tableView:validateDrop:proposedRow:proposedDropOperation:'>
- <retval type='I' />
+ <retval type='I' type64='Q' />
<arg index='2' type='i' type64='q' />
- <arg index='3' type='I' />
+ <arg index='3' type='I' type64='Q' />
</method>
<method selector='tableView:willDisplayCell:forTableColumn:row:'>
<retval type='v' />
@@ -6956,7 +6956,7 @@
</method>
<method selector='textView:completions:forPartialWordRange:indexOfSelectedItem:'>
<arg index='2' type='{_NSRange=II}' type64='{_NSRange=QQ}' />
- <arg index='3' type_modifier='N' type='^i' type64='^l' />
+ <arg index='3' type_modifier='N' type='^i' type64='^q' />
</method>
<method selector='textView:doCommandBySelector:'>
<retval type='B' />
@@ -7007,7 +7007,7 @@
</method>
<method selector='tokenField:completionsForSubstring:indexOfToken:indexOfSelectedItem:'>
<arg index='2' type='i' type64='q' />
- <arg index='3' type_modifier='o' type='^i' type64='^l'/>
+ <arg index='3' type_modifier='o' type='^i' type64='^q'/>
</method>
<method selector='tokenField:hasMenuForRepresentedObject:'>
<retval type='B' />
@@ -7016,14 +7016,14 @@
<arg index='2' type='I' type64='Q' />
</method>
<method selector='tokenField:styleForRepresentedObject:'>
- <retval type='I' />
+ <retval type='I' type64='Q' />
</method>
<method selector='tokenField:writeRepresentedObjects:toPasteboard:'>
<retval type='B' />
</method>
<method selector='tokenFieldCell:completionsForSubstring:indexOfToken:indexOfSelectedItem:'>
<arg index='2' type='i' type64='q' />
- <arg index='3' type_modifier='o' type='^i' type64='^l' />
+ <arg index='3' type_modifier='o' type='^i' type64='^q' />
</method>
<method selector='tokenFieldCell:hasMenuForRepresentedObject:'>
<retval type='B' />
@@ -7032,7 +7032,7 @@
<arg index='2' type='I' type64='Q' />
</method>
<method selector='tokenFieldCell:styleForRepresentedObject:'>
- <retval type='I' />
+ <retval type='I' type64='Q' />
</method>
<method selector='tokenFieldCell:writeRepresentedObjects:toPasteboard:'>
<retval type='B' />
@@ -7190,11 +7190,11 @@
<retval type='B' />
</method>
<method selector='beginForDirectory:file:types:modelessDelegate:didEndSelector:contextInfo:'>
- <arg index='4' sel_of_type='v@:@i^v' type=':' />
+ <arg index='4' sel_of_type='v@:@i^v' sel_of_type64='v@:@q^v' type=':' />
<arg index='5' type='^v' />
</method>
<method selector='beginSheetForDirectory:file:types:modalForWindow:modalDelegate:didEndSelector:contextInfo:'>
- <arg index='5' sel_of_type='v@:@i^v' />
+ <arg index='5' sel_of_type='v@:@i^v' sel_of_type64='v@:@q^v' />
<arg index='6' type='^v' />
</method>
<method selector='canChooseDirectories'>
@@ -7273,7 +7273,7 @@
</class>
<class name='NSPageLayout'>
<method selector='beginSheetWithPrintInfo:modalForWindow:delegate:didEndSelector:contextInfo:'>
- <arg index='3' sel_of_type='v@:@i^v' />
+ <arg index='3' sel_of_type='v@:@i^v' sel_of_type64='v@:@q^v' />
<arg index='4' type='^v' />
</method>
</class>
@@ -7548,7 +7548,7 @@
</class>
<class name='NSPrintPanel'>
<method selector='beginSheetWithPrintInfo:modalForWindow:delegate:didEndSelector:contextInfo:'>
- <arg index='3' sel_of_type='v@:@i^v' />
+ <arg index='3' sel_of_type='v@:@i^v' sel_of_type64='v@:@q^v' />
<arg index='4' type='^v' />
</method>
</class>
@@ -7772,15 +7772,15 @@
<retval type='B' />
</method>
<method selector='beginSheetForDirectory:file:types:modalForWindow:modalDelegate:didEndSelector:contextInfo:'>
- <arg index='5' sel_of_type='v@:@i^v' />
+ <arg index='5' sel_of_type='v@:@i^v' sel_of_type64='v@:@q^v' />
<arg index='6' type='^v' />
</method>
<method selector='beginForDirectory:file:types:modelessDelegate:didEndSelector:contextInfo:'>
- <arg index='4' sel_of_type='v@:@i^v' type=':' />
+ <arg index='4' sel_of_type='v@:@i^v' type=':' sel_of_type64='v@:@q^v' />
<arg index='5' type='^v' />
</method>
<method selector='beginSheetForDirectory:file:modalForWindow:modalDelegate:didEndSelector:contextInfo:'>
- <arg index='4' sel_of_type='v@:@i^v' />
+ <arg index='4' sel_of_type='v@:@i^v' sel_of_type64='v@:@q^v' />
<arg index='5' type='^v' />
</method>
<method selector='canCreateDirectories'>
@@ -9356,9 +9356,11 @@
</method>
<method selector='shouldBreakLineByHyphenatingBeforeCharacterAtIndex:'>
<retval type='B' />
+ <arg index='0' type='I' type64='Q' />
</method>
<method selector='shouldBreakLineByWordBeforeCharacterAtIndex:'>
<retval type='B' />
+ <arg index='0' type='I' type64='Q' />
</method>
<method selector='substituteGlyphsInRange:withGlyphs:'>
<arg index='0' type='{_NSRange=II}' type64='{_NSRange=QQ}' />
Modified: trunk/pyobjc/pyobjc-framework-Cocoa/Lib/CoreFoundation/PyObjC.bridgesupport
==============================================================================
--- trunk/pyobjc/pyobjc-framework-Cocoa/Lib/CoreFoundation/PyObjC.bridgesupport (original)
+++ trunk/pyobjc/pyobjc-framework-Cocoa/Lib/CoreFoundation/PyObjC.bridgesupport Sun Feb 7 13:20:53 2010
@@ -3930,7 +3930,7 @@
<arg type='l' type64='l' />
</function>
<function name='CFURLGetPortNumber'>
- <retval type='l' type64='l' />
+ <retval type='l' type64='i' />
<arg type='^{__CFURL=}' />
</function>
<function name='CFURLGetString'>
Modified: trunk/pyobjc/pyobjc-framework-Cocoa/Lib/Foundation/PyObjC.bridgesupport
==============================================================================
--- trunk/pyobjc/pyobjc-framework-Cocoa/Lib/Foundation/PyObjC.bridgesupport (original)
+++ trunk/pyobjc/pyobjc-framework-Cocoa/Lib/Foundation/PyObjC.bridgesupport Sun Feb 7 13:20:53 2010
@@ -847,7 +847,7 @@
<enum name='NSDataReadingMapped' value='1' />
<enum name='NSDataReadingUncached' value='2' />
<enum name='NSDataWritingAtomic' value='1' />
- <enum name='NSUndefinedDateComponent' value='2147483647' value64='-1' />
+ <enum name='NSUndefinedDateComponent' value='2147483647' value64='9223372036854775807' />
<enum name='NSUndoCloseGroupingRunLoopOrdering' value='350000' />
<enum name='NSUnicodeStringEncoding' value='10' />
<enum name='NSUnionSetExpressionType' value='5' />
@@ -2267,28 +2267,28 @@
</method>
<method selector='sortedArrayUsingComparator:'>
<arg index='0' block='true' >
- <retval type='i'/>
+ <retval type='l'/>
<arg type='@' />
<arg type='@' />
</arg>
</method>
<method selector='sortedArrayWithOptions:usingComparator:'>
<arg index='1' block='true' >
- <retval type='i'/>
+ <retval type='l'/>
<arg type='@' />
<arg type='@' />
</arg>
</method>
<method selector='indexOfObject:inSortedRange:options:usingComparator:'>
<arg index='3' block='true' >
- <retval type='i'/>
+ <retval type='l'/>
<arg type='@' />
<arg type='@' />
</arg>
</method>
<method selector='sortedArrayUsingFunction:context:' >
<arg index='0' function_pointer='true' function_pointer_retained='false'>
- <retval type='i'/>
+ <retval type='l'/>
<arg type='@' />
<arg type='@' />
<arg type='@' />
@@ -2297,7 +2297,7 @@
</method>
<method selector='sortedArrayUsingFunction:context:hint:' >
<arg index='0' function_pointer='true' function_pointer_retained='false'>
- <retval type='i'/>
+ <retval type='l'/>
<arg type='@' />
<arg type='@' />
<arg type='@' />
@@ -2768,7 +2768,7 @@
</method>
<method selector='keysSortedByValueWithOptions:usingComparator:'>
<arg index='1' block='true' >
- <retval type='i'/>
+ <retval type='i' type64='q'/>
<arg type='@' />
<arg type='@' />
</arg>
@@ -3286,21 +3286,21 @@
<class name='NSMutableArray'>
<method selector='sortUsingComparator:'>
<arg index='0' block='true' >
- <retval type='i'/>
+ <retval type='l'/>
<arg type='@' />
<arg type='@' />
</arg>
</method>
<method selector='sortWithOptions:usingComparator:'>
<arg index='1' block='true' >
- <retval type='i'/>
+ <retval type='l'/>
<arg type='@' />
<arg type='@' />
</arg>
</method>
<method selector='sortUsingFunction:context:' >
<arg index='0' function_pointer='true' function_pointer_retained='false' >
- <retval type='i' />
+ <retval type='l' />
<arg type='@' />
<arg type='@' />
<arg type='@' />
@@ -3309,7 +3309,7 @@
</method>
<method selector='sortUsingFunction:context:range:' >
<arg index='0' function_pointer='true' function_pointer_retained='false' >
- <retval type='i' />
+ <retval type='l' />
<arg type='@' />
<arg type='@' />
<arg type='@' />
@@ -4185,7 +4185,7 @@
</method>
<method selector='spellServer:findMisspelledWordInString:language:wordCount:countOnly:'>
<retval type='{_NSRange=II}' type64='{_NSRange=QQ}' />
- <arg index='3' type_modifier='o' type="^i" type64="^l" />
+ <arg index='3' type_modifier='o' type="^i" type64="^q" />
<arg index='4' type='B' />
</method>
<method selector='spellServer:suggestCompletionsForPartialWordRange:inString:language:'>
@@ -4193,7 +4193,7 @@
</method>
<method selector='stream:handleEvent:'>
<retval type='v' />
- <arg index='1' type='I' />
+ <arg index='1' type='I' type64='Q' />
</method>
<method selector='superclass'>
<retval type='#' />
Modified: trunk/pyobjc/pyobjc-framework-Cocoa/Modules/_AppKit_nsbitmap.m
==============================================================================
--- trunk/pyobjc/pyobjc-framework-Cocoa/Modules/_AppKit_nsbitmap.m (original)
+++ trunk/pyobjc/pyobjc-framework-Cocoa/Modules/_AppKit_nsbitmap.m Sun Feb 7 13:20:53 2010
@@ -150,7 +150,7 @@
{
PyObject* result;
PyObject* maybeNone;
- char *dataPlanes[5];
+ unsigned char *dataPlanes[5];
int garbage;
int width, height;
int bps, spp;
@@ -214,7 +214,7 @@
PyObjCSelector_GetClass(method),
PyObjCObject_GetObject(self));
- newImageRep = objc_msgSendSuper(&super,
+ newImageRep = ((id(*)(struct objc_super*, SEL, unsigned char**, NSInteger, NSInteger, NSInteger, NSInteger, BOOL, BOOL, id, NSInteger, NSInteger))objc_msgSendSuper)(&super,
PyObjCSelector_GetSelector(method),
dataPlanes, width, height, bps, spp,
hasAlpha, isPlanar, colorSpaceNameString,
@@ -387,5 +387,5 @@
return -1;
}
- return -1;
+ return 0;
}
Modified: trunk/pyobjc/pyobjc-framework-Cocoa/Modules/_AppKit_nsview.m
==============================================================================
--- trunk/pyobjc/pyobjc-framework-Cocoa/Modules/_AppKit_nsview.m (original)
+++ trunk/pyobjc/pyobjc-framework-Cocoa/Modules/_AppKit_nsview.m Sun Feb 7 13:20:53 2010
@@ -7,7 +7,7 @@
PyObject* v;
NSRect* rects;
PyObject* arg1, *arg2;
- int count;
+ NSInteger count;
if (!PyArg_ParseTuple(arguments, "OO", &arg1, &arg2)) {
return NULL;
@@ -29,7 +29,7 @@
PyObjCObject_GetObject(self));
- objc_msgSendSuper(&super,
+ ((void(*)(struct objc_super*, SEL, NSRect**, NSInteger*))objc_msgSendSuper)(&super,
PyObjCSelector_GetSelector(method),
&rects, &count);
PyObjC_HANDLER
Modified: trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_convenience.py
==============================================================================
--- trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_convenience.py (original)
+++ trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_convenience.py Sun Feb 7 13:20:53 2010
@@ -19,7 +19,7 @@
def testHash(self):
for hashValue in (0, sys.maxint, sys.maxint + 1L, 0xFFFFFFFFL):
- expect = struct.unpack('i', struct.pack('I', hashValue))[0]
+ expect = struct.unpack('l', struct.pack('L', hashValue))[0]
# Python can't hash to -1. Surprise! :)
if expect == -1:
expect = -2
Modified: trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsarray.py
==============================================================================
--- trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsarray.py (original)
+++ trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsarray.py Sun Feb 7 13:20:53 2010
@@ -434,12 +434,12 @@
self.assertArgIsIn(NSMutableArray.removeObjectsFromIndices_numIndices_, 0)
self.assertArgSizeInArg(NSMutableArray.removeObjectsFromIndices_numIndices_, 0, 1)
- self.assertArgIsFunction(NSArray.sortedArrayUsingFunction_context_, 0, 'i@@@', False)
+ self.assertArgIsFunction(NSArray.sortedArrayUsingFunction_context_, 0, 'l@@@', False)
self.assertArgHasType(NSArray.sortedArrayUsingFunction_context_, 1, '@')
- self.assertArgIsFunction(NSArray.sortedArrayUsingFunction_context_hint_, 0, 'i@@@', False)
+ self.assertArgIsFunction(NSArray.sortedArrayUsingFunction_context_hint_, 0, 'l@@@', False)
self.assertArgHasType(NSArray.sortedArrayUsingFunction_context_hint_, 1, '@')
- self.assertArgIsFunction(NSMutableArray.sortUsingFunction_context_, 0, 'i@@@', False)
+ self.assertArgIsFunction(NSMutableArray.sortUsingFunction_context_, 0, 'l@@@', False)
self.assertArgHasType(NSMutableArray.sortUsingFunction_context_, 1, '@')
self.assertIsNullTerminated(NSArray.arrayWithObjects_)
@@ -469,19 +469,19 @@
objc._C_NSBOOL + '@'+objc._C_NSUInteger+'o^'+objc._C_NSBOOL)
self.assertArgIsBlock(NSArray.sortedArrayUsingComparator_,
- 0, 'i@@')
+ 0, 'l@@')
self.assertArgIsBlock(NSArray.sortedArrayWithOptions_usingComparator_,
- 1, 'i@@')
+ 1, 'l@@')
self.assertArgIsBlock(NSArray.indexOfObject_inSortedRange_options_usingComparator_,
- 3, 'i@@')
+ 3, 'l@@')
self.assertArgHasType(NSArray.indexOfObject_inSortedRange_options_usingComparator_, 1, NSRange.__typestr__)
self.assertArgIsBlock(NSMutableArray.sortUsingComparator_,
- 0, 'i@@')
+ 0, 'l@@')
self.assertArgIsBlock(NSMutableArray.sortWithOptions_usingComparator_,
- 1, 'i@@')
+ 1, 'l@@')
Modified: trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsatstypesetter.py
==============================================================================
--- trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsatstypesetter.py (original)
+++ trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsatstypesetter.py Sun Feb 7 13:20:53 2010
@@ -69,11 +69,11 @@
m = o.willSetLineFragmentRect_forGlyphRange_usedRect_baselineOffset_.__metadata__()
self.assertStartswith(m['arguments'][2]['type'], 'N^{')
self.assertStartswith(m['arguments'][4]['type'], 'N^{')
- self.assertStartswith(m['arguments'][5]['type'], 'N^f')
+ self.assertStartswith(m['arguments'][5]['type'], 'N^' + objc._C_CGFloat)
m = o.shouldBreakLineByWordBeforeCharacterAtIndex_.__metadata__()
self.assertEqual(m['retval']['type'], objc._C_NSBOOL)
- self.assertEqual(m['arguments'][2]['type'], objc._C_UINT)
+ self.assertEqual(m['arguments'][2]['type'], objc._C_NSUInteger)
m = o.shouldBreakLineByHyphenatingBeforeCharacterAtIndex_.__metadata__()
self.assertEqual(m['retval']['type'], objc._C_NSBOOL)
Modified: trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsbitmapimagerep.py
==============================================================================
--- trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsbitmapimagerep.py (original)
+++ trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsbitmapimagerep.py Sun Feb 7 13:20:53 2010
@@ -78,7 +78,7 @@
self.assertEqual(len(bitmapData), len(singlePlane))
self.assertEqual(bitmapData, singlePlane)
- a = array.array('I', [255]*4)
+ a = array.array('L', [255]*4)
self.assertArgIsOut(NSBitmapImageRep.getPixel_atX_y_, 0)
d = i2.getPixel_atX_y_(a, 1, 1)
self.assertIsObject(a, d)
Modified: trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nscolor.py
==============================================================================
--- trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nscolor.py (original)
+++ trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nscolor.py Sun Feb 7 13:20:53 2010
@@ -1,6 +1,7 @@
from PyObjCTools.TestSupport import *
from AppKit import *
import array
+import sys
class TestRegressions (TestCase):
def testQualifiersInSignature(self):
@@ -41,7 +42,10 @@
self.assertIsInstance(b, float)
self.assertIsInstance(a, float)
- a = array.array('f', [0] * 6)
+ if sys.maxint > 2**32:
+ a = array.array('d', [0] * 6)
+ else:
+ a = array.array('f', [0] * 6)
v = color.getComponents_(a)
self.assertEqual(a[0], 1.0)
Modified: trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsdictionary.py
==============================================================================
--- trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsdictionary.py (original)
+++ trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsdictionary.py Sun Feb 7 13:20:53 2010
@@ -282,7 +282,7 @@
self.assertArgIsBlock(NSDictionary.enumerateKeysAndObjectsUsingBlock_, 0, 'v@@o^'+objc._C_NSBOOL)
self.assertArgIsBlock(NSDictionary.enumerateKeysAndObjectsWithOptions_usingBlock_, 1, 'v@@o^'+objc._C_NSBOOL)
self.assertArgIsBlock(NSDictionary.keysSortedByValueUsingComparator_, 0, 'i@@')
- self.assertArgIsBlock(NSDictionary.keysSortedByValueWithOptions_usingComparator_, 1, 'i@@')
+ self.assertArgIsBlock(NSDictionary.keysSortedByValueWithOptions_usingComparator_, 1, objc._C_NSInteger + b'@@')
self.assertArgIsBlock(NSDictionary.keysOfEntriesPassingTest_, 0, objc._C_NSBOOL + '@@o^' + objc._C_NSBOOL)
self.assertArgIsBlock(NSDictionary.keysOfEntriesWithOptions_passingTest_, 1, objc._C_NSBOOL + '@@o^' + objc._C_NSBOOL)
Modified: trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsgraphicscontext.py
==============================================================================
--- trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsgraphicscontext.py (original)
+++ trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsgraphicscontext.py Sun Feb 7 13:20:53 2010
@@ -39,8 +39,8 @@
None, 255, 255, 8, 4, True, False, NSCalibratedRGBColorSpace, 0, 0, 0)
context = NSGraphicsContext.graphicsContextWithBitmapImageRep_(img)
self.assertIsInstance(context, NSGraphicsContext)
- port = context.graphicsPort()
if Quartz is not None:
+ port = context.graphicsPort()
self.assertIsInstance(port, Quartz.CGContextRef)
self.assertArgHasType(NSGraphicsContext.graphicsContextWithGraphicsPort_flipped_, 0, '^{CGContext=}')
Modified: trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsmatrix.py
==============================================================================
--- trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsmatrix.py (original)
+++ trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsmatrix.py Sun Feb 7 13:20:53 2010
@@ -13,8 +13,8 @@
self.assertResultIsBOOL(NSMatrix.allowsEmptySelection)
self.assertArgIsBOOL(NSMatrix.setAllowsEmptySelection_, 0)
self.assertArgIsBOOL(NSMatrix.sendAction_to_forAllCells_, 2)
- self.assertArgIsSEL(NSMatrix.sendAction_to_forAllCells_, 0, objc._C_NSBOOL + '@:@')
- self.assertArgIsSEL(NSMatrix.sortUsingSelector_, 0, 'i@:@')
+ self.assertArgIsSEL(NSMatrix.sendAction_to_forAllCells_, 0, objc._C_NSBOOL + b'@:@')
+ self.assertArgIsSEL(NSMatrix.sortUsingSelector_, 0, objc._C_NSInteger + b'@:@')
self.assertArgIsOut(NSMatrix.getNumberOfRows_columns_, 0)
self.assertArgIsOut(NSMatrix.getNumberOfRows_columns_, 1)
self.assertArgIsOut(NSMatrix.getRow_column_ofCell_, 0)
@@ -22,7 +22,7 @@
self.assertArgIsOut(NSMatrix.getRow_column_forPoint_, 0)
self.assertArgIsOut(NSMatrix.getRow_column_forPoint_, 1)
- self.assertArgIsFunction(NSMatrix.sortUsingFunction_context_, 0, 'i@@@', False)
+ self.assertArgIsFunction(NSMatrix.sortUsingFunction_context_, 0, objc._C_NSInteger + b'@@@', False)
self.assertArgHasType(NSMatrix.sortUsingFunction_context_, 1, objc._C_ID)
Modified: trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsnumber.py
==============================================================================
--- trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsnumber.py (original)
+++ trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsnumber.py Sun Feb 7 13:20:53 2010
@@ -46,7 +46,7 @@
n = NSNumber.numberWithInt_(1)
self.assertRaises(AttributeError, setattr, n, 'foo', 2)
- n = NSNumber.numberWithLongLong_(sys.maxint + 2)
+ n = NSNumber.numberWithLongLong_(2**32 + 2)
self.assertRaises(AttributeError, setattr, n, 'foo', 2)
def testUseAsBasicType(self):
@@ -63,17 +63,17 @@
# NSNumber stores unsigned numbers as signed numbers
# This is a bug in Cocoa... (RADAR #4007594), fixed in 10.5
if sdkForPython() < (10, 5):
- self.assertEqual(NSNumber.numberWithUnsignedInt_(sys.maxint+1),
- -sys.maxint-1)
+ self.assertEqual(NSNumber.numberWithUnsignedInt_(2**31),
+ -(2**31))
else:
- self.assertEqual(NSNumber.numberWithUnsignedInt_(sys.maxint+1),
- sys.maxint+1)
+ self.assertEqual(NSNumber.numberWithUnsignedInt_(2**31),
+ (2**31))
def testMethods(self):
- v = NSNumber.numberWithUnsignedInt_(sys.maxint+1)
+ v = NSNumber.numberWithUnsignedInt_(2**31)
- self.assertEqual(v.unsignedIntValue(), sys.maxint+1)
- self.assertEqual(v.intValue(), -sys.maxint-1)
+ self.assertEqual(v.unsignedIntValue(), 2**31)
+ self.assertEqual(v.intValue(), -(2**31))
v = NSNumber.numberWithInt_(10)
self.assertEqual(v.doubleValue(), float(10))
@@ -140,13 +140,13 @@
self.assert_(isinstance(n, (int, long)))
self.assert_(isinstance(n, NSNumber))
- n = NSNumber.numberWithLongLong_(sys.maxint * 1024L)
- self.assertEqual(n, sys.maxint * 1024L)
+ n = NSNumber.numberWithLongLong_(2**32 * 1024L)
+ self.assertEqual(n, 2**32 * 1024L)
self.assert_(isinstance(n, (int, long)))
self.assert_(isinstance(n, NSNumber))
- n = NSNumber.numberWithUnsignedLongLong_(sys.maxint + 100)
- self.assertEqual(n, sys.maxint + 100)
+ n = NSNumber.numberWithUnsignedLongLong_(2**32 + 100)
+ self.assertEqual(n, 2**32 + 100)
self.assert_(isinstance(n, (int, long)))
self.assert_(isinstance(n, NSNumber))
Modified: trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsopenpanel.py
==============================================================================
--- trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsopenpanel.py (original)
+++ trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsopenpanel.py Sun Feb 7 13:20:53 2010
@@ -26,11 +26,11 @@
self.assertArgIsBOOL(NSOpenPanel.setCanChooseFiles_, 0)
panel = NSOpenPanel.openPanel()
- self.assertArgIsSEL(panel.beginSheetForDirectory_file_types_modalForWindow_modalDelegate_didEndSelector_contextInfo_, 5, 'v@:@i^v')
- self.assertArgHasType(panel.beginSheetForDirectory_file_types_modalForWindow_modalDelegate_didEndSelector_contextInfo_, 6, '^v')
+ self.assertArgIsSEL(panel.beginSheetForDirectory_file_types_modalForWindow_modalDelegate_didEndSelector_contextInfo_, 5, b'v@:@' + objc._C_NSInteger + b'^v')
+ self.assertArgHasType(panel.beginSheetForDirectory_file_types_modalForWindow_modalDelegate_didEndSelector_contextInfo_, 6, b'^v')
- self.assertArgIsSEL(panel.beginForDirectory_file_types_modelessDelegate_didEndSelector_contextInfo_, 4, 'v@:@i^v')
- self.assertArgHasType(panel.beginForDirectory_file_types_modelessDelegate_didEndSelector_contextInfo_, 5, '^v')
+ self.assertArgIsSEL(panel.beginForDirectory_file_types_modelessDelegate_didEndSelector_contextInfo_, 4, b'v@:@'+objc._C_NSInteger+b'^v')
+ self.assertArgHasType(panel.beginForDirectory_file_types_modelessDelegate_didEndSelector_contextInfo_, 5, b'^v')
Modified: trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsview.py
==============================================================================
--- trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsview.py (original)
+++ trunk/pyobjc/pyobjc-framework-Cocoa/PyObjCTest/test_nsview.py Sun Feb 7 13:20:53 2010
@@ -17,11 +17,13 @@
def test_knowsPageRange(self):
method = ObjCTestNSView_KnowPageRange.knowsPageRange_
- self.assertEqual(method.__metadata__()['arguments'][2]['type'], 'o^{_NSRange=II}')
+ self.assertEqual(method.__metadata__()['arguments'][2]['type'], 'o^' + NSRange.__typestr__)
def test_rectForPage(self):
method = ObjCTestNSView_KnowPageRange.rectForPage_
- self.assertEqual(objc.splitSignature(method.signature), objc.splitSignature("{_NSRect={_NSPoint=ff}{_NSSize=ff}}12@0:4i8"))
+
+
+ self.assertEqual(objc.splitSignature(method.signature), objc.splitSignature(NSRect.__typestr__+b"@:" + objc._C_NSInteger))
class TestHeader (TestCase):
------------------------------------------------------------------------------
The Planet: dedicated and managed hosting, cloud storage, colocation
Stay online with enterprise data centers and the best network in the business
Choose flexible plans and management services without long-term contracts
Personal 24x7 support from experience hosting pros just a phone call away.
http://p.sf.net/sfu/theplanet-com