[vlmc-devel] Change projectUpdated to projectNameChanged

Yikai Lu git at videolan.org
Tue Mar 8 13:01:22 CET 2016


vlmc | branch: master | Yikai Lu <luyikei.qmltu at gmail.com> | Tue Mar  8 14:24:00 2016 +0900| [821eee88fecd7c726ca8274ab558fac55d77cb5e] | committer: Hugo Beauzée-Luyssen

Change projectUpdated to projectNameChanged

projectUpdated is so vague that we don't know when it is actually emitted.

Signed-off-by: Hugo Beauzée-Luyssen <hugo at beauzee.fr>

> https://code.videolan.org/videolan/vlmc/commit/821eee88fecd7c726ca8274ab558fac55d77cb5e
---

 src/Gui/MainWindow.cpp  | 6 +++---
 src/Gui/MainWindow.h    | 2 +-
 src/Project/Project.cpp | 6 +++---
 src/Project/Project.h   | 4 ++--
 4 files changed, 9 insertions(+), 9 deletions(-)

diff --git a/src/Gui/MainWindow.cpp b/src/Gui/MainWindow.cpp
index 2df028a..609e710 100644
--- a/src/Gui/MainWindow.cpp
+++ b/src/Gui/MainWindow.cpp
@@ -107,8 +107,8 @@ MainWindow::MainWindow( Backend::IBackend* backend, QWidget *parent )
     connect( this, SIGNAL( toolChanged( ToolButtons ) ),
              m_timeline, SLOT( setTool( ToolButtons ) ) );
 
-    connect( Core::getInstance()->project(), SIGNAL( projectUpdated(QString) ),
-             this, SLOT( projectUpdated( QString ) ) );
+    connect( Core::getInstance()->project(), SIGNAL( projectNameChanged(QString) ),
+             this, SLOT( projectNameChanged( QString ) ) );
     connect( Core::getInstance()->project(), SIGNAL( outdatedBackupFileFound() ),
              this, SLOT( onOudatedBackupFile() ) );
     connect( Core::getInstance()->project(), SIGNAL( backupProjectLoaded() ),
@@ -793,7 +793,7 @@ MainWindow::closeEvent( QCloseEvent* e )
 }
 
 void
-MainWindow::projectUpdated( const QString& projectName )
+MainWindow::projectNameChanged( const QString& projectName )
 {
     QString title = tr( "%1 VideoLAN Movie Creator [*]" ).arg( projectName );
     setWindowTitle( title );
diff --git a/src/Gui/MainWindow.h b/src/Gui/MainWindow.h
index b4f5d7f..8f7d4bc 100644
--- a/src/Gui/MainWindow.h
+++ b/src/Gui/MainWindow.h
@@ -166,7 +166,7 @@ private slots:
     void                    on_actionCrash_triggered();
     void                    on_actionImport_triggered();
     void                    toolButtonClicked( QAction *action );
-    void                    projectUpdated(const QString& projectName);
+    void                    projectNameChanged(const QString& projectName);
     void                    cleanStateChanged( bool isClean );
     void                    canUndoChanged( bool canUndo );
     void                    canRedoChanged( bool canRedo );
diff --git a/src/Project/Project.cpp b/src/Project/Project.cpp
index 20ab0ca..dee00e9 100644
--- a/src/Project/Project.cpp
+++ b/src/Project/Project.cpp
@@ -216,7 +216,7 @@ Project::initSettings()
                                     QT_TRANSLATE_NOOP( "PreferenceWidget", "Project name" ),
                                     QT_TRANSLATE_NOOP( "PreferenceWidget", "The project name" ),
                                     SettingValue::NotEmpty );
-    connect( pName, SIGNAL( changed( QVariant ) ), this, SLOT( projectUpdated( QVariant ) ) );
+    connect( pName, SIGNAL( changed( QVariant ) ), this, SLOT( projectNameChanged( QVariant ) ) );
 }
 
 void
@@ -315,9 +315,9 @@ Project::libraryCleanChanged(bool val)
 }
 
 void
-Project::projectUpdated(const QVariant &projectName)
+Project::projectNameChanged(const QVariant &projectName)
 {
-    emit projectUpdated( projectName.toString() );
+    emit projectNameChanged( projectName.toString() );
 }
 
 void
diff --git a/src/Project/Project.h b/src/Project/Project.h
index 42c0db7..17062d3 100644
--- a/src/Project/Project.h
+++ b/src/Project/Project.h
@@ -84,7 +84,7 @@ class Project : public QObject
     public slots:
         void                cleanChanged( bool val );
         void                libraryCleanChanged( bool val );
-        void                projectUpdated( const QVariant& projectName); // Proxy slot for projectUpdated(QString)
+        void                projectNameChanged( const QVariant& projectName); // Proxy slot for projectNameChanged(QString)
         void                autoSaveRequired();
         void                autoSaveEnabledChanged( const QVariant& enabled );
         void                autoSaveIntervalChanged( const QVariant& interval );
@@ -96,7 +96,7 @@ class Project : public QObject
          *      - The project name has changed
          *      - The revision (if activated) has changed
          */
-        void                projectUpdated( const QString& projectName );
+        void                projectNameChanged( const QString& projectName );
 
         /**
          *  \brief      Used to signal that the project has been saved.



More information about the Vlmc-devel mailing list