Re: Dismissing Open dlog before doc actually opens
Re: Dismissing Open dlog before doc actually opens
- Subject: Re: Dismissing Open dlog before doc actually opens
- From: Alex Zavatone <email@hidden>
- Date: Wed, 14 Aug 2013 15:01:59 -0400
Can't you make the opening a two stage process and use a notification when the window hasbeenclosed to issue the "real" opening?
I wonder if there is a delegate to the open dialog that has events for that.
Issuing delays to start a thread blocking operation at this point seems to beg for potential race conditions IMO.
Sent from my iPad
On Aug 14, 2013, at 2:44 PM, Steve Mills <email@hidden> wrote:
> On Aug 14, 2013, at 13:11:31, Quincey Morris <email@hidden> wrote:
>
>> Actually, it's going to be the Window Server that removes the window from the screen. However, it may be that ordering-out an app window triggers a run loop source or event, which in turn notifies the Window Server. If so, the 'sleep' approach isn't going to work.
>
> I only used sleep in that example to illustrate that orderOut was not hiding the window, and that there were not "deeper issues" in our code base.
>
>> My guess, in Steve's scenario, is that a later part of the document-opening sequence is blocking the main thread for a while, but the interaction with the Window Server isn't fully finished yet, so that it gets "snagged" by the later blockage, even though the app has gone way beyond its own Open-dialog-handling code.
>
> The document loading code loads a complex document structure, which naturally blocks the main thread.
>
> --
> Steve Mills
> office: 952-818-3871
> home: 952-401-6255
> cell: 612-803-6157
>
>
>
> _______________________________________________
>
> 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
_______________________________________________
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