Re: NSView subclass IB plug-ins conundrum
Re: NSView subclass IB plug-ins conundrum
- Subject: Re: NSView subclass IB plug-ins conundrum
- From: "Sean McBride" <email@hidden>
- Date: Thu, 23 Oct 2008 14:12:25 -0400
- Organization: Rogue Research
On 10/23/08 2:01 PM, Martin-Gilles Lavoie said:
>However, for some reason, IB itself doesn't recognise our view as
>being a subclass of NSView and it wont let me drop objects inside it,
>like it does for recular custom views. The object is treated as a non-
>container.
Salut Martin-Gilles!
// We allow all subviews to be manipulatable in IB
- (NSArray*)ibDefaultChildren
{
NSArray* array = [NSArray arrayWithArray:[self subviews]];
return array;
}
// We allow all child views to be moved in IB
- (BOOL)ibIsChildViewUserMovable:(NSView*)child
{
return YES;
}
// We allow all child views to be resized in IB
- (BOOL)ibIsChildViewUserSizable:(NSView*)child
{
return YES;
}
// Returns the container view for the children of the receiver
- (NSView*)ibDesignableContentView
{
return self;
}
--
____________________________________________________________
Sean McBride, B. Eng email@hidden
Rogue Research www.rogue-research.com
Mac Software Developer Montréal, Québec, Canada
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden