开发者

NSWindowController showWindow only works once

I have a subclass of NSWindowController that has its own nib and another class that has an IBAction to show the window and loads it like so.

if (!propertiesController){
    propertiesController = [[PropertiesController alloc] init];
}
[propertiesController showWindow:self];

It the first time but after I close the window and call th开发者_如何学JAVAis method again the window is not displayed. I am sure the window is not getting released. Do I possibly have to override showWindow to order the window to the front? Or do I have to specify what window the controller uses in the nib?


have you tried

[propertiesController.window makeKeyAndOrderFront:self];

?

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜