Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

the-dream

macrumors newbie
Original poster
Sep 19, 2008
2
0
Hi there.

I want to create a window, with a checkbox in the bottom left. If the checkbox is unchecked, the window will display each time the application is launched, if it is checked, the window stops displaying on launch.

I am relatively new to Mac application development, and couldn't find a tutorial anywhere, so a tutorial, or some sample code would really help.

Thanks,
~ Christian
 

kainjow

Moderator emeritus
Jun 15, 2000
7,958
7
It's pretty simple. When the application launches, you check to see if the preferences contains a FirstRun object. If it doesn't, then you show the window. When the window closes and the checkbox is marked, you save a FirstRun object to preferences (usually a boolean set to true).

Since you didn't give what API you're using I can only provide you the concept of how to implement it but that should be plenty enough.
 

the-dream

macrumors newbie
Original poster
Sep 19, 2008
2
0
I really am a noob when it comes to this, I know the bare basics but thats about it.

I am using Cocoa/Obj-C CoreData. If thats any help?
 

kainjow

Moderator emeritus
Jun 15, 2000
7,958
7
You need then to familiarize yourself with NSUserDefaults, NSWindow, and bindings (specifically NSUserDefaultsController).
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.