• 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
LSUIElement=1 application activation causes menu items of other applications to be wrongly enabled
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

LSUIElement=1 application activation causes menu items of other applications to be wrongly enabled


  • Subject: LSUIElement=1 application activation causes menu items of other applications to be wrongly enabled
  • From: Johnny Lai <email@hidden>
  • Date: Thu, 18 Jun 2009 15:44:57 +0800

I have encountered a strange issue regarding the enable/disable status of menu items when my menu extra only application (LSUIElement = 1) activates itself. It activates itself so that it can bring its window to the front.

The issue occurs if you follow the following steps:
1. Open a normal application, say "System Preferences"
2. Cause my menu extra to activate. My menu extra calls "[NSApp activateIgnoringOtherApps:YES]" then immediately shows a window.
3. While the menu extra's window is focused, click on the menus on the application opened in Step 1. The "Window" menu's items are not all disabled, which seems to be an error.
4. Switch to the normal application. Some of the menu items are no longer disabled, like they should be. (In "System Preferences" case, the "Back" and "Forward" items should be disabled).

If you clicked the normal application's menu before Step 2, the "Window" menu's items in Step 3 are all disabled, and in Step 4, the menu items are correctly disabled.

If Step 2 is omitted, and the user manually activates my menu extra, this behaviour also does not occur.

This was on 10.5.7.

I have also tried activating using SetFrontProcess in Step 2 and it has the same issues.

Does anyone know or have any tips on how to avoid this issue?
(I want to activate because I want the menu extra's newly-created window to be on top. It does not actually need to be activated.)

Thanks in advance

Cheers

Johnny
_______________________________________________

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

  • Prev by Date: Jerky/juttery (core-)animation in a screensaver
  • Next by Date: Re: Jerky/juttery (core-)animation in a screensaver
  • Previous by thread: Re: Jerky/juttery (core-)animation in a screensaver
  • Next by thread: Programmatically creating a NSMatrix with a prototype cell question
  • Index(es):
    • Date
    • Thread