阅读背景:

从故事板、OS X、swift中的视图控制器访问菜单项

来源:互联网 

I am building an OS X app in Xcode using storyboards. I have found that working with menu items is difficult and non-intuitive. The menu items are in a different scene (the application) than the view controller, and can not be connected to the view controller by the usual control-drag methods to create an outlet/action. I need to access menu items from the main view controller. I have figured out how to connect actions via first responder chain. However, I also would like to enable/disable menu items from the view controller, and I see no way to create an outlet to be able to do this.I am building an OS X app in Xcode using storyb




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: