Best way to implement calling another controller/class?
Best way to implement calling another controller/class?
- Subject: Best way to implement calling another controller/class?
- From: Chad Armstrong <email@hidden>
- Date: Tue, 27 Jan 2004 10:42:38 -0600
I'm trying to determine what would be the best way to implement some
functionality in one of my programs. My program has three class
controllers. One operates the functionality of the window and which
tab window should be in front. Then I have two other class controllers
which manage the functionality of each of the tabbed windows.
I want to be able to drop files onto my application, and the window
controller will take in the files, decide what to do with them, and
then send them off to the proper controller. Will I need to call a new
class instance, or can I send the information some other way, or
perhaps just make the information global between all three of the
classes?
Here is a general idea in what I'm trying to do.
- (BOOL) application:(NSApplication *)theApplication openFile:(NSString
*)filename
{
if (some_case)
{
// call one controller class and send file name(s)
}
else
{
// call the other controller class and send file name(s)
}
return NO;
}
Chad Armstrong
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.