Wondering: Why doesn't Apple release the API to properly implement menubar items?

Discussion in 'Mac Programming' started by ravenvii, Nov 11, 2009.

  1. macrumors 604

    ravenvii

    Joined:
    Mar 17, 2004
    Location:
    Melenkurion Skyweir
    #1
    Currently apps that use the menubar have to use a hack of sorts. It's obvious they are not equal to Apple's own menubar items. You can't arrange the third-party icons to mingle with the Apple ones. When you click an item of Apple's, and move your mouse to another Apple item, the menu activates normally, but when you mouse over a third party's icon, it doesn't activate. You have to click to deactivate the menu, and click again the activate the third party menu.

    I am wondering why Apple refuses to reveal the proper APIs for third parties to use for menubar items?
     
  2. macrumors 68030

    Catfish_Man

    Joined:
    Sep 13, 2001
    Location:
    Portland, OR
    #2
    The "proper" menu items run in SystemUIServer rather than in the applications that provide them, which is a bit of a risky thing to do. Some sort of in-between solution (perhaps something like how DockTile plugins work) seems appropriate. Have you filed a request with Apple for this at bugreport.apple.com?
     
  3. macrumors 601

    sammich

    Joined:
    Sep 26, 2006
    Location:
    Sarcasmville.
    #3
    I've never noticed that. Now I'm gonna get annoyed by it :mad: However, iStatMenus doesn't behave like this, it activates like a menu item should, but others like Bowtie and Adium don't, like you said.

    Chances are Apple wants to keep things clean and uncluttered.
     
  4. Moderator emeritus

    kainjow

    Joined:
    Jun 15, 2000
    #4
    It's been like this since the beginning (AFAIK). I guess there isn't enough demand from developers for Apple to change it. Like Catfish_Man mentioned they probably will never open the existing API because each menu is a plugin managed by SystemUIServer and if one of those plugins crash, down goes the entire SystemUIServer process and all those menu items are gone (until it relaunches). I've seen it happen several times with Spotlight being the culprit.

    There's no reason they can't come up with some solution for integrating Apple menus with third-parties smoothly. I think they're just lazy ;)
     
  5. macrumors 601

    HiRez

    Joined:
    Jan 6, 2004
    Location:
    Western US
    #5
    MenuMeters seems to function "correctly" (it'll drop down its menus after clicking on an Apple menu and moving to MM).
     
  6. Moderator emeritus

    kainjow

    Joined:
    Jun 15, 2000
    #6
    Looks like they use MenuCracker though.
     

Share This Page