Panik Posted March 12, 2008 Share Posted March 12, 2008 I have an app that is taking up real estate in my dock (even though I need it running all the time). It would be nice to potentially make a menubar icon [NSStatusItem/NSMenuExtra] for the program instead of having a dock icon for it. I'm no XCode dev, but I assume this entails using Cocoa. Macosxhints suggests the following: In order to get rid of the dock icon, you must modify the file named 'Info.plist' inside the Application's package: <key>NSUIElement</key> <string>1</string> Or use DockDodger, instead. Would be nice to have a way to add the app to the menubar now... Link to comment https://www.insanelymac.com/forum/topic/93148-hiding-dock-icon-of-running-app/ Share on other sites More sharing options...
stroke Posted March 13, 2008 Share Posted March 13, 2008 When you say an app, do you mean an app you made? If not, there's no way to make an NSStatusItem for it. However, here's a sample project to show you how to make an NSStatusItem if it is your own app. Link to comment https://www.insanelymac.com/forum/topic/93148-hiding-dock-icon-of-running-app/#findComment-664761 Share on other sites More sharing options...
Panik Posted March 13, 2008 Author Share Posted March 13, 2008 Nope, not an app I made. An existing app. I would give anything for a solution like this. Decompiling, altering, recompiling? Link to comment https://www.insanelymac.com/forum/topic/93148-hiding-dock-icon-of-running-app/#findComment-664816 Share on other sites More sharing options...
stroke Posted March 13, 2008 Share Posted March 13, 2008 You can't decompile Mach-O binaries into Objective-C code and magically recompile them into a .app. Unless you're extremely proficient in ASM and somehow modify the program without changing the byte count, forget about it. Link to comment https://www.insanelymac.com/forum/topic/93148-hiding-dock-icon-of-running-app/#findComment-664826 Share on other sites More sharing options...
Panik Posted March 13, 2008 Author Share Posted March 13, 2008 No way to attach some AppleScript to launch with the app? The only functionality I'm looking for in the NSStatusItem is to open the app window. Link to comment https://www.insanelymac.com/forum/topic/93148-hiding-dock-icon-of-running-app/#findComment-664835 Share on other sites More sharing options...
stroke Posted March 13, 2008 Share Posted March 13, 2008 Can you paste a link to what app you're talking about? I'll see if I can do something for it. Link to comment https://www.insanelymac.com/forum/topic/93148-hiding-dock-icon-of-running-app/#findComment-664845 Share on other sites More sharing options...
Panik Posted March 13, 2008 Author Share Posted March 13, 2008 It's the ZyDas WLan utility for AirLink USB adapters. The installer adds a kext and alters networking kext (I'm assuming) then installs WLan.app. Here is the app sans installer pkg. (I'm hoping this is copacetic, since the app is freeware). Link to comment https://www.insanelymac.com/forum/topic/93148-hiding-dock-icon-of-running-app/#findComment-664859 Share on other sites More sharing options...
stroke Posted March 14, 2008 Share Posted March 14, 2008 Well unfortunately your goal is kind of impossible, after investigating some. NSUIElement (when set to 1) basically gets rid of any trace of a GUI for an app — in other words, no windows will show up. I made a template that will work ONLY if you do not set NSUIElement to 1… which basically defeats the purpose of your original goal. However, if you still want this app, I can give it to you. Link to comment https://www.insanelymac.com/forum/topic/93148-hiding-dock-icon-of-running-app/#findComment-666269 Share on other sites More sharing options...
Panik Posted March 14, 2008 Author Share Posted March 14, 2008 Anyway to hide the dock icon with your add-on while setting NSUIElement to 0? Send over the app want to see what you came up with... Link to comment https://www.insanelymac.com/forum/topic/93148-hiding-dock-icon-of-running-app/#findComment-666353 Share on other sites More sharing options...
Recommended Posts