[vlmc-devel] ProjectManager: Remove empty files from the recent projects list.

Hugo Beauzée-Luyssen git at videolan.org
Wed Sep 5 17:43:03 CEST 2012


vlmc | branch: master | Hugo Beauzée-Luyssen <hugo at beauzee.fr> | Wed Sep  5 16:22:40 2012 +0300| [d406ddedee55936b7eeb16ca30a5f33af436a229] | committer: Hugo Beauzée-Luyssen

ProjectManager: Remove empty files from the recent projects list.

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

 src/Project/ProjectManager.cpp |    2 ++
 1 file changed, 2 insertions(+)

diff --git a/src/Project/ProjectManager.cpp b/src/Project/ProjectManager.cpp
index 0ea3dbf..1145b57 100644
--- a/src/Project/ProjectManager.cpp
+++ b/src/Project/ProjectManager.cpp
@@ -48,6 +48,8 @@ ProjectManager::ProjectManager() : m_projectFile( NULL ), m_needSave( false )
 {
     QSettings s;
     m_recentsProjects = s.value( "RecentsProjects" ).toStringList();
+    //If the variable was empty, it will return a list with one empty string in it.
+    m_recentsProjects.removeAll( "" );
 
     SettingValue    *fps = VLMC_CREATE_PROJECT_DOUBLE( "video/VLMCOutputFPS", 29.97,
                                 QT_TRANSLATE_NOOP( "PreferenceWidget", "Output video FPS" ),



More information about the Vlmc-devel mailing list