Re: Show / hide application menu / icon in dock / windows cycling / ...
Re: Show / hide application menu / icon in dock / windows cycling / ...
- Subject: Re: Show / hide application menu / icon in dock / windows cycling / ...
- From: Ken Thomases <email@hidden>
- Date: Mon, 27 May 2013 08:07:09 -0500
On May 27, 2013, at 6:30 AM, Robert Vojta wrote:
> Tried to change activation policy and it does work partially. LSUIElement = 1 equals to NSApplicationActivationPolicyAccessory. According to the documentation, I can change it to NSApplicationActivationPolicyRegular to show menu and show app icon in cycling. But anyway, it's not possible to go back from NSApplicationActivationPolicyRegular to NSApplicationActivationPolicyAccessory. setActivationPolicy: always returns NO and it's correct according to the documentation: Currently, NSApplicationActivationPolicyNone and NSApplicationActivationPolicyAccessory may be changed to NSApplicationActivationPolicyRegular, but other modifications are not supported.
That's what the docs say although, apparently, since Lion you can also set it to NSApplicationActivationPolicyProhibited. See <http://www.cocoabuilder.com/archive/cocoa/318334-turning-app-into-background-app.html>, keeping in mind that Eric Schlegel is an Apple developer.
That doesn't particularly help you, though.
> Is there another way how can I achieve this behavior? LSUIElement = YES application with menu/app icon in dock/... for just one particular window? Other windows can't be opened in the same time and this is just the only visible window.
No. The usual recommendation is to launch a helper app, one which is not an LSUIElement, to handle the interaction.
Regards,
Ken
_______________________________________________
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