ResidualVM logo Forum Index - ResidualVM website - Contact us - Rules Login    Register     Search curved edge
It is currently Mon Dec 11, 2017 1:12 pm

All times are UTC




Post new topic Reply to topic  [ 2 posts ] 
Author Message
PostPosted: Sat Dec 12, 2015 11:13 pm 
Offline

Joined: Tue Dec 08, 2015 5:39 am
Posts: 1
So, I was wondering if there was a way to add a "Full Screen" menu item on Mac OS X? I know that the file I would need to edit is:
/backends/platform/sdl/macosx/appmenu_osx.mm

but, every thing I've tried only produces a greyed-out menu item. Here's a few examples of the code I've tried:

Code:
 // Add "Full Screen" menu item
    nsString = constructNSStringFromCString(_("Full Screen"), stringEncoding);
    menuItem = [[NSMenuItem alloc] initWithTitle:nsString action:@selector(fullscreen:) keyEquivalent:@"\r"];
    [setKeyEquivalentModifierMask:NSAlternateKeyMask | NSCommandKeyMask];
    [windowMenu addItem:menuItem];
    [nsString release];



    // Add "Full Screen" menu item
   nsString = constructNSStringFromCString(_("Full Screen"), stringEncoding);
   menuItem = (NSMenuItem *)[appleMenu addItemWithTitle:nsString action:@selector(fullscreen:) keyEquivalent:@“\r”];
   [menuItem setKeyEquivalentModifierMask:(NSAlternateKeyMask)];


Any help/suggestions would be greatly appreciated.


Top
 Profile  
 
PostPosted: Tue Dec 15, 2015 8:55 am 
Offline
ResidualVM Developer

Joined: Thu Feb 28, 2013 5:48 pm
Posts: 178
This seems to suggest the selector you want is "toggleFullScreen:", maybe?

https://developer.apple.com/library/mac ... e_txt.html

And this suggests a "setEnabled:" method,

https://developer.apple.com/library/mac ... Items.html

Hope that helps, I don't have access to an OSX machine to try it right now


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ] 

All times are UTC


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group
Forum design by ScummVM team, icons by raina, adopted for ResidualVM
curved edge   curved edge