[vlc-commits] macosx: disable native fullscreen checkbox in prefs if a change would have no effect

David Fuhrmann git at videolan.org
Sat Mar 10 20:40:06 CET 2012


vlc | branch: master | David Fuhrmann <david.fuhrmann at googlemail.com> | Sat Mar 10 20:36:29 2012 +0100| [50134d9405852b74a9844e44f154049a91eaef9e] | committer: David Fuhrmann

macosx: disable native fullscreen checkbox in prefs if a change would have no effect

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=50134d9405852b74a9844e44f154049a91eaef9e
---

 modules/gui/macosx/simple_prefs.m |   15 +++++++++++++--
 1 files changed, 13 insertions(+), 2 deletions(-)

diff --git a/modules/gui/macosx/simple_prefs.m b/modules/gui/macosx/simple_prefs.m
index 8ae369f..1ef0b27 100644
--- a/modules/gui/macosx/simple_prefs.m
+++ b/modules/gui/macosx/simple_prefs.m
@@ -464,12 +464,23 @@ static inline char * __config_GetLabel( vlc_object_t *p_this, const char *psz_na
     [self setupButton: o_intf_art_pop forIntList: "album-art"];
 
     [self setupButton: o_intf_fspanel_ckb forBoolValue: "macosx-fspanel"];
+
     [self setupButton: o_intf_nativefullscreen_ckb forBoolValue: "macosx-nativefullscreenmode"];
+    BOOL b_correct_sdk = NO;
+#ifdef MAC_OS_X_VERSION_10_7
+    b_correct_sdk = YES;
+#endif
+    if( !b_correct_sdk || !OSX_LION )
+    {
+        [o_intf_nativefullscreen_ckb setState: NSOffState];
+        [o_intf_nativefullscreen_ckb setEnabled: NO];
+    }
+
     [self setupButton: o_intf_embedded_ckb forBoolValue: "embedded-video"];
 
-[self setupButton: o_intf_appleremote_ckb forBoolValue: "macosx-appleremote"];
+    [self setupButton: o_intf_appleremote_ckb forBoolValue: "macosx-appleremote"];
 
-[self setupButton: o_intf_mediakeys_ckb forBoolValue: "macosx-mediakeys"];
+    [self setupButton: o_intf_mediakeys_ckb forBoolValue: "macosx-mediakeys"];
     if( [[SUUpdater sharedUpdater] lastUpdateCheckDate] != NULL )
         [o_intf_last_update_lbl setStringValue: [NSString stringWithFormat: _NS("Last check on: %@"), [[[SUUpdater sharedUpdater] lastUpdateCheckDate] descriptionWithLocale: [[NSUserDefaults standardUserDefaults] dictionaryRepresentation]]]];
     else



More information about the vlc-commits mailing list