Re: Multiple delegates Window

2009-07-25 Thread Andy Lee
On Jul 25, 2009, at 6:21 PM, Andy Lee wrote: On Jul 25, 2009, at 5:55 PM, Gevik wrote: I was wondering if it is possible to connect more than one delegate from the Window in IB. No, but you could make an object that forwards delegate messages to multiple other objects, and have that be the

Re: Multiple delegates Window

2009-07-25 Thread Andy Lee
On Jul 25, 2009, at 5:55 PM, Gevik wrote: I was wondering if it is possible to connect more than one delegate from the Window in IB. No, but you could make an object that forwards delegate messages to multiple other objects, and have that be the window delegate. --Andy __

Re: Multiple delegates Window

2009-07-25 Thread WT
Correction... I meant to say "There is only one DELEGATE outlet..." not "There is only one WINDOW outlet..." ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the mod

Re: Multiple delegates Window

2009-07-25 Thread WT
There is only one window outlet, so you can only hook up one object as the window's delegate. I am currently running into a similar issue with a text field delegate. See the discussion in the thread "[iPhone] Why can't a UITextField be its own delegate?" My solution, which has stirred some

Re: Multiple delegates Window

2009-07-25 Thread Stephen J. Butler
On Sat, Jul 25, 2009 at 4:55 PM, Gevik wrote: > I was wondering if it is possible to connect more than one delegate from the > Window in IB. > When I create a new Cocoa application in XCode, the Delegate_AppDelegate.m/h > is created automatically. > I would like to add a second object with specific

Re: Multiple delegates Window

2009-07-25 Thread Kyle Sluder
On Sat, Jul 25, 2009 at 2:55 PM, Gevik wrote: > How do I do this? You don't. Read up on the delegate pattern again, and how it's implemented in Cocoa. You can't have one pointer point at two different things, so therefore you can't have two delegates hooked up to one outlet. --Kyle Sluder _

Multiple delegates Window

2009-07-25 Thread Gevik
I was wondering if it is possible to connect more than one delegate from the Window in IB. When I create a new Cocoa application in XCode, the Delegate_AppDelegate.m/h is created automatically. I would like to add a second object with specific functionality as a delegate object. How do I do th