Re: Instantiate custom NSWindow
Re: Instantiate custom NSWindow
- Subject: Re: Instantiate custom NSWindow
- From: Fritz Anderson <email@hidden>
- Date: Mon, 24 Sep 2007 13:29:28 -0500
On 24 Sep 2007, at 1:10 PM, Jere Gmail wrote:
My problem now is I have a window and had created a custom class for
this window (DataWindow).
This is surprising. NSWindow is almost never subclassed, at least for
the apparently-routine sort of display that the name DataWindow implies.
Now in the application controller I have this:
#include "DataWindow.h"
so I can instantiate this class.
But if I write this
NSWindow *r=[DataWindow new];
[NSApp beginSheet:r modalForWindow:window modalDelegate:self
didEndSelector:nil contextInfo:NULL];
[NSApp runModalForWindow:r];
all that I obtain is an empty window.
What I'm doing wrong?
Impossible to tell, without knowing how you implement DataWindow;
especially how you populate its contentView.
— F
_______________________________________________
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