On Oct 22, 2009, at 8:44 AM, Motti Shneor wrote:

Thanks again.

Regarding the Carbon Window problem, the FrontWindow() call was just an illustration. The WindowRef I'm supplying is of a visible (usually active and front) Document window. The problems are not even consistent, and will randomly occur. The desired behavior, though, will very rarely occur. (I'd say one in a hundred times).

In short --- Are there any specific implications to opening a cocoa sheet over a carbon (document) window? Is there any specific setup I need to know about? What are the limitations of Cocoa NSWindow wrappers around Carbon windows?

The problem is, my Plugin is written using cocoa, but runs within a Carbon application. I need to attach my NSOpen/NSSave panels onto a given application window, which is, of course, a Carbon window. I get this bogus behavior and even worse, both running with my Host application, and with simplistic test programs like the one below.


There's one fundamental problem - sheets are designed to be document modal, not application modal, which requires support from the underlying application in order to work correctly.

So a sheet is not support to block the app like runModal does, but to work in conjunction with document architecture.

You're basically fighting the frameworks, and the frameworks always win...

Glenn Andreas                      [email protected]
 <http://www.gandreas.com/> wicked fun!
Mad, Bad, and Dangerous to Know

_______________________________________________

Cocoa-dev mailing list ([email protected])

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 [email protected]

Reply via email to