Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How can I write an autostarting dock app for the Mac?

I have an application I'd like to build that starts when you start the mac and will appear in the dock.

I have some experience with Objective-C and iPhone dev but none with Mac dev, I'm also a PC user normally so I'm not au fait with the norms of Mac usage. Any guidance here is appreciated.

How do you get an application to autostart?

*edit Can you run an app in the status bar? (with the clock etc) or do apps only run in the dock?

like image 875
Tristan Warner-Smith Avatar asked Nov 19 '25 22:11

Tristan Warner-Smith


1 Answers

To write a program in the Status Bar check out this great tutorial.

To get an application to auto start on login, look for information on launch daemon or just make your application installer to place an entry on /Library/StartupItems.

About the dock: usually, user controls what's on his/her dock. When your UI application is running, it will usually be in the dock. If you want the icon to stick there permanently, you will need the user dragging the icon from the Finder to the dock, or, right-click on the dock icon while is running in select Options->Keep In Dock menu option.

like image 154
Pablo Santa Cruz Avatar answered Nov 21 '25 16:11

Pablo Santa Cruz



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!