If they are throwing Carbon into the mix then they also get
additional points for a even greater degree of difficulty.
Well, SWT uses carbon for its UI drawing and events, apparently due
to the
fact that carbon and SWT have a very similar event model, so it was
the easy
way out at the time SWT was written.
It was the only way out. This went back to 1.3 and earlier when the
JVM was actually Carbon. It became Cocoa at 1.4.
So what needs to be done is a JNI layer to add the openDoc listeners
through carbon, which seems to be how Azureus does it (from what I
can tell).
I'm learning much more than I ever wanted to know about this :)
That is basically how you can using JNI with Carbon handle
AppleEvent's. Specifically written for 'gurl' type AppleEvent's since
I assumed 'open document' was dealt with already. You can take a look
at that, pretty simple. Actually I am trying to come up with a more
involved Cocoa version that I figured would work better with the more
usual (non-SWT) current JVM environment. Not complete, and no code
posted yet, and not much help to you. Just another floating entry on
the to-do list.
The above might be of a little assistance to you though. You would
unfortunately still need to get some understanding of 'odoc' events
and how they are handled. Samples should be about all over the place
via Google though and in the Apple AppleScript samples.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Java-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/java-dev/email@hidden