Re: Getting reference to NSWindowController from subviews
Re: Getting reference to NSWindowController from subviews
- Subject: Re: Getting reference to NSWindowController from subviews
- From: Mike Abdullah <email@hidden>
- Date: Thu, 3 Dec 2009 11:33:16 +0000
Bear in mind that if one of your views needs to know about the window controller, it's a good sign of a poor design. You're probably better off giving the view in question its own -delegate or -dataSource property which can be set to the window controller.
On 3 Dec 2009, at 02:09, PCWiz wrote:
> Thanks, worked great.
>
> On 2009-12-02, at 6:37 PM, Graham Cox wrote:
>
>>
>> On 03/12/2009, at 12:26 PM, PCWiz wrote:
>>
>>> What is the best way to get a reference to my NSWindowController object from subviews of its window?
>>
>>
>> [[theView window] windowController];
>>
>> --Graham
>>
>>
>
> _______________________________________________
>
> 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
_______________________________________________
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