[vlmc-devel] QSettings: Do not use fallback. Our own file is fine enough so far

Hugo Beauzée-Luyssen git at videolan.org
Sun Feb 9 22:14:05 CET 2014


vlmc | branch: master | Hugo Beauzée-Luyssen <hugo at beauzee.fr> | Sun Feb  9 23:09:00 2014 +0200| [23e1f81951cc7397ff6d40d5cfdd1b25abc4c994] | committer: Hugo Beauzée-Luyssen

QSettings: Do not use fallback. Our own file is fine enough so far

> http://git.videolan.org/gitweb.cgi/vlmc.git/?a=commit;h=23e1f81951cc7397ff6d40d5cfdd1b25abc4c994
---

 src/EffectsEngine/EffectsEngine.cpp |    1 +
 src/Gui/MainWindow.cpp              |    1 +
 src/Main/guimain.cpp                |    1 +
 src/Settings/SettingsManager.cpp    |    2 ++
 4 files changed, 5 insertions(+)

diff --git a/src/EffectsEngine/EffectsEngine.cpp b/src/EffectsEngine/EffectsEngine.cpp
index 9eddcfb..d343959 100644
--- a/src/EffectsEngine/EffectsEngine.cpp
+++ b/src/EffectsEngine/EffectsEngine.cpp
@@ -56,6 +56,7 @@ EffectsEngine::EffectsEngine()
 #endif
 
                              QSettings::IniFormat, this );
+    m_cache->setFallbacksEnabled( false );
     //Create the names entry. A bit ugly but faster (I guess...) afterward.
     m_names.push_back( QStringList() );
     m_names.push_back( QStringList() );
diff --git a/src/Gui/MainWindow.cpp b/src/Gui/MainWindow.cpp
index e7dabe9..3b79b37 100644
--- a/src/Gui/MainWindow.cpp
+++ b/src/Gui/MainWindow.cpp
@@ -339,6 +339,7 @@ MainWindow::loadVlmcPreferences()
 {
     //FIXME: Manually load vlmc version to force settings clear?
     QSettings       s;
+    s.setFallbacksEnabled( false );
     foreach ( QString key, s.allKeys() )
     {
         QVariant value = s.value( key );
diff --git a/src/Main/guimain.cpp b/src/Main/guimain.cpp
index 1899bb7..5518d69 100644
--- a/src/Main/guimain.cpp
+++ b/src/Main/guimain.cpp
@@ -69,6 +69,7 @@ VLMCmain( int argc, char **argv )
     qRegisterMetaType<QUuid>( "QUuid" );
 
     QSettings s;
+    s.setFallbacksEnabled( false );
     LanguageHelper::getInstance()->languageChanged(
             s.value( "vlmc/VLMCLang", "default" ) );
 
diff --git a/src/Settings/SettingsManager.cpp b/src/Settings/SettingsManager.cpp
index 7efe871..108aea4 100644
--- a/src/Settings/SettingsManager.cpp
+++ b/src/Settings/SettingsManager.cpp
@@ -51,6 +51,7 @@ SettingsManager::setValue( const QString &key,
                 return true;
 
             QSettings    sett;
+            sett.setFallbacksEnabled( false );
             sett.setValue( key, value );
             sett.sync();
             return true;
@@ -109,6 +110,7 @@ SettingsManager::save() const
     m_classicSettings.lockForRead();
 
     QSettings       sett;
+    sett.setFallbacksEnabled( false );
     SettingsContainer::SettingMap::const_iterator it = m_classicSettings.settings().begin();
     SettingsContainer::SettingMap::const_iterator ed = m_classicSettings.settings().end();
 



More information about the Vlmc-devel mailing list