• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Understanding the Run loop idea and the updating of controls during long operations
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Understanding the Run loop idea and the updating of controls during long operations


  • Subject: Re: Understanding the Run loop idea and the updating of controls during long operations
  • From: Andy Lee <email@hidden>
  • Date: Sun, 07 Nov 2010 09:50:12 -0500

On Nov 7, 2010, at 6:05 AM, eveningnick eveningnick wrote:
>>> I assume i should call a one run through the runloop manually, but how?
>> I recommend that you not attempt to "invert" the event loop or build one
>> yourself.  The "modal session" methods of NSApplication
>> (-beginModalSessionForWindow:, -runModalSession:, and -endModalSession:)
>> seem like a good fit for your requirements.  It does entail implementing
>> your long operation as a bunch of short work units.
>>
> Could you please explain what will happen when i call these methods?

<http://www.google.com/search?q=beginModalSessionForWindow+site:developer.apple.com>

(The "site:developer.apple.com" is a handy trick.)

<http://developer.apple.com/library/mac/#documentation/Cocoa/Conceptual/WinPanel/Concepts/UsingModalWindows.html>

<http://developer.apple.com/library/mac/#documentation/Cocoa/Reference/ApplicationKit/Classes/NSApplication_Class/Reference/Reference.html>

I think it would be better to refer to specific parts of the docs that are not clear than to ask a general "what will happen" question.

That said, I wonder if anyone knows of a blog entry or Apple example that specifically shows how to display progress in a modal window or sheet.

--Andy

_______________________________________________

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

References: 
 >Understanding the Run loop idea and the updating of controls during long operations (From: eveningnick eveningnick <email@hidden>)
 >Re: Understanding the Run loop idea and the updating of controls during long operations (From: Ken Thomases <email@hidden>)
 >Re: Understanding the Run loop idea and the updating of controls during long operations (From: eveningnick eveningnick <email@hidden>)

  • Prev by Date: Re: Over-released NSMenuItem on using "Open Recent" via Help menu search
  • Next by Date: Re: Understanding the Run loop idea and the updating of controls during long operations
  • Previous by thread: Re: Understanding the Run loop idea and the updating of controls during long operations
  • Next by thread: Re: Understanding the Run loop idea and the updating of controls during long operations
  • Index(es):
    • Date
    • Thread