Mailing Lists: Apple Mailing Lists
Image of Mac OS face in stamp
Re: Timing issue with new Java Update
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Timing issue with new Java Update



On Mar 16, 2011, at 2:01 PM, Joshua Smith wrote:

> My users are occasionally seeing an "Open" dialog box come up in my application when they've double-clicked a file that my app handles.
>
> That would indicate that the handleOpenFile is not being called, or, I suspect, that the timing of this call has changed.
>
> VERY near the top of main(), I call:
>
>        com.apple.mrj.MRJApplicationUtils.registerOpenDocumentHandler(this);
>
> It's not the very first thing I do, but it's darn close.  (I call setProperty a few times).
>
> I present the open dialog box if this has not been called by the time I'm ready to read the file.  So I suppose it's possible the O/S is just calling that really, really late.
>
> Anybody else seeing this?
>
> Two things that make me suspect timing:
>
> 1) Closing my app and double-clicking my document usually corrects the issue;
>
> 2) This happened consistently when the user was trying to run my app simultaneously with sharing in webex.
>
> Perhaps I should sleep on the Mac for a little while to give it time to call handleOpenFile?
>
> Thoughts?

This sounds like a bug. The eAWT open files delegate should either be set to the legacy ApplicationEvent handler, or not (there shouldn't be a weird in-between state). Do you have a small reproducible test case that we can build, bundle using Jar Bundler, and test? Please file it at <http://bugreporter.apple.com>.

Thanks,
Mike Swingler
Java Engineering
Apple Inc.

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Java-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >Timing issue with new Java Update (From: Joshua Smith <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2011 Apple Inc. All rights reserved.