[NSEvent data1]
[NSEvent data1]
i'm building a 64bit app.
in response to USB input, i create and post an application defined
event. for the data1 field, i pass the address of an
NSMutableDictionary as follows:
... data1: (NSInteger)dataDict ...
in my application object's sendEvent override, i'm only getting (via
[anEvent data1]) the bottom 32 bits of the address i passed in.
the data1 method of NSEvent is defined to return an NSInteger, as is
the data1 parameter of the NSEvent method otherEventWithType, and if
i examining the value of data1 after i've created my custom event and
posted it (but prior to receiving/processing it in sendEvent), it
contains the proper 64 bit value.
so it appears that somewhere between posting the event and its
getting processed by [NSApp sendevent:] the parameter is getting
truncated to 32 bits. is this a bug in the 64 bit runtime? or a bug
in my understanding? and if not a misunderstanding on my part, anyone
know of a workaround (other my simply decomposing the 64bit address
manually into 2 32bit pieces and using data1 and data2)?
thanx,
ken
ps. running on leopard 10.5.7, with Xcode 3.1.3.
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden