开发者

Why can't I access the NSApp global variable from a controller?

I am inside of a controller, and would like to access and close the currently displayed mainWindow. But when I try:

[NSApp mainWindow] close];

not开发者_如何转开发hing happens. So how do I access it?


I needed to use something like:

 [[NSApp delegate] closeFilePanel];
0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜