Thanks again, Graham. This was actually the key to solving it. I had been hung up on the idea to present the sheet for each item as the item became available, i.e. within the same loop that generates the items. Which, of course, lead to the run-away train situation.

What I am doing now instead, is to put each item into an array as it becomes available, then I call a new method that looks at the array and if there is anything in it will present the sheet for the first item. It also removes the first item from the array.

Then the method that runs when the sheet is dismissed calls the above method again, which will present the sheet for the next item, or if there is no item left in the array will simply do nothing.

Rainer


On Jan 6, 2010, at 22:33 , Graham Cox wrote:


On 07/01/2010, at 5:10 PM, Rainer Standke wrote:

How do I go about solving this?


This is down to the logic of your app. While a sheet is up, events are being processed as normal, so presumably you are relying on the event loop to process the items. You'll need to rework your design so that each item can be processed in response to some other thing occurring (like the previous one completing) rather than using the event loop.

Sorry this is vague, but so's your question. If you show the code of how you are processing the items, better/more concrete advice can probably be offered!

--Graham



_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to