Could someone point me to any examples on how to write full-screen apps for Mac OS X in Ojective-C with Cocoa?
相关问题
- CALayer - backgroundColor flipped?
- Core Data lightweight migration crashes after App
- back button text does not change
- iOS (objective-c) compression_decode_buffer() retu
- how to find the index position of the ARRAY Where
相关文章
- 现在使用swift开发ios应用好还是swift?
- Visual Studio Code, MAC OS X, OmniSharp server is
- TCC __TCCAccessRequest_block_invoke
- xcode 4 garbage collection removed?
- IntelliJ IDEA can't open projects or add SDK o
- Automator: How do I use the Choose from List actio
- Unable to process app at this time due to a genera
- How can I add media attachments to my push notific
Add the following code to the NSView you want to make fullscreen:
[view enterFullScreenMode:[NSScreen mainScreen] withOptions:nil];
It's exactly the same, the only thing you need to watch for is if you have any NSWindow specific code...
http://developer.apple.com/library/mac/#documentation/Cocoa/Reference/ApplicationKit/Classes/NSView_Class/Reference/NSView.html
http://nehe.gamedev.net/data/lessons/lesson.asp?lesson=02
There is an OSX Cocoa example for many of the tutorials.
Try this:
You can connect this to the fullscreen menu item in the Window menu (after inserting that into your nib) but be sure to change the action that the menu item fires to your toggleMyViewFullScreen: . Or your can invoke toggleMyViewFullScreen programmatically or when your app loads.