Class Design for delegate, outlets, and mouse events
Class Design for delegate, outlets, and mouse events
- Subject: Class Design for delegate, outlets, and mouse events
- From: Walker Argendeli <email@hidden>
- Date: Tue, 26 May 2009 16:47:38 -0400
Here's a simplification:
I have an application with several buttons. If it is the first time
the application is launching, I want to do some special things. In my
AppController class, which is a delegate of NSApp, I use the delegate
method -applicationDidFinishLaunching: to perform the test. After I've
detected that it is the first time, I first want to access some
IBOutlets. Then, I'd like to be able to get mouse events for each
button, so that I can do other things.
I can't figure out want to do with the classes. I'd like to make a new
class (FirstLaunch) for the first launch, but I'm not sure what to
call from AppDelegate. Also, to get mouse events, shouldn't I be a
sublass of the buttons, and considering that I have multiple buttons,
I'm confused. I could probably tackle these issues one-by-one, but
taken all together, they're confusing me.
Broken down, I need to access & manipulate IBOutlets I have set in IB,
determine when buttons are clicked (and which button was clicked). I'd
like to be able to do this from another class so as to not clutter up
the AppDelegate.
Thanks for the help!
- Walker Argendeli
_______________________________________________
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