[vlc-commits] macosx: Rename preferences helpers to better describe purpose

David Fuhrmann git at videolan.org
Sun Jul 30 17:59:46 CEST 2017


vlc | branch: master | David Fuhrmann <dfuhrmann at videolan.org> | Sun Jul 30 17:22:20 2017 +0200| [c2a1ef597e250ed597935d7eeac9c5eb16a69b21] | committer: David Fuhrmann

macosx: Rename preferences helpers to better describe purpose

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

 modules/gui/macosx/VLCCoreInteraction.h       | 2 +-
 modules/gui/macosx/VLCCoreInteraction.m       | 2 +-
 modules/gui/macosx/VLCMain+OldPrefs.h         | 2 +-
 modules/gui/macosx/VLCMain+OldPrefs.m         | 4 ++--
 modules/gui/macosx/VLCMain.m                  | 2 +-
 modules/gui/macosx/VLCSimplePrefsController.m | 2 +-
 modules/gui/macosx/prefs.m                    | 2 +-
 7 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/modules/gui/macosx/VLCCoreInteraction.h b/modules/gui/macosx/VLCCoreInteraction.h
index 1ad578ec6e..6d49c9a9e2 100644
--- a/modules/gui/macosx/VLCCoreInteraction.h
+++ b/modules/gui/macosx/VLCCoreInteraction.h
@@ -83,7 +83,7 @@
 
 - (void)toggleFullscreen;
 
-- (BOOL)fixPreferences;
+- (BOOL)fixIntfSettings;
 
 - (void)setVideoFilter: (const char *)psz_name on:(BOOL)b_on;
 - (void)setVideoFilterProperty: (const char *)psz_property forFilter: (const char *)psz_filter withValue: (vlc_value_t)value;
diff --git a/modules/gui/macosx/VLCCoreInteraction.m b/modules/gui/macosx/VLCCoreInteraction.m
index 3f0ab75cf3..deeeca92e8 100644
--- a/modules/gui/macosx/VLCCoreInteraction.m
+++ b/modules/gui/macosx/VLCCoreInteraction.m
@@ -674,7 +674,7 @@ static int BossCallback(vlc_object_t *p_this, const char *psz_var,
 
 #pragma mark - uncommon stuff
 
-- (BOOL)fixPreferences
+- (BOOL)fixIntfSettings
 {
     NSMutableString * o_workString;
     NSRange returnedRange;
diff --git a/modules/gui/macosx/VLCMain+OldPrefs.h b/modules/gui/macosx/VLCMain+OldPrefs.h
index ed135ca011..281e2af453 100644
--- a/modules/gui/macosx/VLCMain+OldPrefs.h
+++ b/modules/gui/macosx/VLCMain+OldPrefs.h
@@ -26,6 +26,6 @@
 @interface VLCMain (OldPrefs)
 
 - (void)resetAndReinitializeUserDefaults;
-- (void)removeOldPreferences;
+- (void)migrateOldPreferences;
 
 @end
diff --git a/modules/gui/macosx/VLCMain+OldPrefs.m b/modules/gui/macosx/VLCMain+OldPrefs.m
index c916eb7c0f..48da488a24 100644
--- a/modules/gui/macosx/VLCMain+OldPrefs.m
+++ b/modules/gui/macosx/VLCMain+OldPrefs.m
@@ -53,7 +53,7 @@ static const int kCurrentPreferencesVersion = 3;
     [[NSUserDefaults standardUserDefaults] synchronize];
 }
 
-- (void)removeOldPreferences
+- (void)migrateOldPreferences
 {
     NSUserDefaults * defaults = [NSUserDefaults standardUserDefaults];
     int version = [defaults integerForKey:kVLCPreferencesVersion];
@@ -71,7 +71,7 @@ static const int kCurrentPreferencesVersion = 3;
         [defaults setInteger:kCurrentPreferencesVersion forKey:kVLCPreferencesVersion];
         [defaults synchronize];
 
-        if (![[VLCCoreInteraction sharedInstance] fixPreferences])
+        if (![[VLCCoreInteraction sharedInstance] fixIntfSettings])
             return;
         else
             config_SaveConfigFile(getIntf()); // we need to do manually, since we won't quit libvlc cleanly
diff --git a/modules/gui/macosx/VLCMain.m b/modules/gui/macosx/VLCMain.m
index 33fcea320a..6b4a4d2a54 100644
--- a/modules/gui/macosx/VLCMain.m
+++ b/modules/gui/macosx/VLCMain.m
@@ -292,7 +292,7 @@ static VLCMain *sharedInstance = nil;
 
     [_coreinteraction updateCurrentlyUsedHotkeys];
 
-    [self removeOldPreferences];
+    [self migrateOldPreferences];
 
     /* Handle sleep notification */
     [[[NSWorkspace sharedWorkspace] notificationCenter] addObserver:self selector:@selector(computerWillSleep:)
diff --git a/modules/gui/macosx/VLCSimplePrefsController.m b/modules/gui/macosx/VLCSimplePrefsController.m
index 310e039895..b97d3ff1f7 100644
--- a/modules/gui/macosx/VLCSimplePrefsController.m
+++ b/modules/gui/macosx/VLCSimplePrefsController.m
@@ -1022,7 +1022,7 @@ static inline void save_string_list(intf_thread_t * p_intf, id object, const cha
         _hotkeyChanged = NO;
     }
 
-    [[VLCCoreInteraction sharedInstance] fixPreferences];
+    [[VLCCoreInteraction sharedInstance] fixIntfSettings];
 
     /* okay, let's save our changes to vlcrc */
     config_SaveConfigFile(p_intf);
diff --git a/modules/gui/macosx/prefs.m b/modules/gui/macosx/prefs.m
index aa167f0621..b984b9e3ad 100644
--- a/modules/gui/macosx/prefs.m
+++ b/modules/gui/macosx/prefs.m
@@ -214,7 +214,7 @@
 {
     /* TODO: call savePrefs on Root item */
     [_rootTreeItem applyChanges];
-    [[VLCCoreInteraction sharedInstance] fixPreferences];
+    [[VLCCoreInteraction sharedInstance] fixIntfSettings];
     config_SaveConfigFile(getIntf());
     [self.window orderOut:self];
 }



More information about the vlc-commits mailing list