• 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: modal windows (again)
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: modal windows (again)


  • Subject: Re: modal windows (again)
  • From: Shawn Erickson <email@hidden>
  • Date: Tue, 9 Mar 2004 12:39:25 -0800

On Mar 9, 2004, at 11:11 AM, Devon E Bowen wrote:

I don't see another option other than something really
complex like breaking things into threads or daughter processes.

Threads are your friend for this type of thing and not that hard to implement in reality. I believe your product will be a much better citizen as a result. No need for daughter processes.

With that said if you use some of the network services of Cocoa and CoreFoundation they could take care of such thread / event management for you. Using "NSModalPanelRunLoopMode" in NSFileHandle's readInBackgroundAndNotifyForModes (etc.) should get the resulting event to still be processed while app or window modal.

A while back I tried to get
info about doing non-blocking file writes and people thought I was
crazy.

Note it would be fairly trivial to write a writeDataInBackgroundAndNotify method that spawned a worker thread. Put it in a category against NSFileHandle and all your file handles benefit from it in your application.

-Shawn
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.


References: 
 >Re: modal windows (again) (From: Devon E Bowen <email@hidden>)

  • Prev by Date: Re: NSTableView eating keyDowns?
  • Next by Date: Re: Please don't use "reply" to start threads.
  • Previous by thread: Re: modal windows (again)
  • Next by thread: Re: modal windows (again)
  • Index(es):
    • Date
    • Thread