> Great, because that's exactly what I'm using it for

The toolbar case or the "certain control" one? When you're in fullscreen mode, 
the toolbar isn't actually attached to your window. It's attached to a separate 
one so it can slide down with the menubar. But if it's the control, it wouldn't 
surprise me if Apple forgot they'd mentioned that option and didn't think about 
it when they decided whether this delegate method needed to be called.

________________________________________
From: cocoa-dev-bounces+lrucker=vmware....@lists.apple.com 
[cocoa-dev-bounces+lrucker=vmware....@lists.apple.com] on behalf of Arjan van 
Leeuwen [arj...@opera.com]
Sent: Wednesday, February 25, 2015 6:47 AM
To: cocoa-dev@lists.apple.com
Subject: window:willPositionSheet:usingRect: not called in full-screen mode

Hi,

To open a save file sheet, I'm starting an NSSavePanel as a sheet
via beginSheetModalForWindow:completionHandler:. Because my application
needs custom positioning for the sheet, the window delegate of my main
window overrides window:willPositionSheet:usingRect:. According to the
documentation, this

Tells the delegate that the window is about to show a sheet at the
> specified location, giving it the opportunity to return a custom location
> for the attachment of the sheet to the window.


And

This method is useful in many situations. If your window has a toolbar, for
> example, you can specify a location for the sheet that is just below it. If
> you want the sheet associated with a certain control or view, you could
> position the sheet so that it appears to originate from the object (through
> animation) or is positioned next to it.


Great, because that's exactly what I'm using it for :). However, when my
app is in full-screen mode, this function never gets called. Other related
delegate functions, like windowWillBeginSheet: and windowDidEndSheet: do
get called correctly on the delegate, so the delegate is obviously still
there and as far as I can see should be receiving a call to
window:willPositionSheet:usingRect:.

Does anyone know what I can do to make the framework call
window:willPositionSheet:usingRect:, even in full-screen mode? Or if not,
what other way should I use to position the sheet that will work in all
situations?

Thanks,

Arjan
_______________________________________________

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:
https://lists.apple.com/mailman/options/cocoa-dev/lrucker%40vmware.com

This email sent to lruc...@vmware.com
_______________________________________________

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

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

Reply via email to