Commit 90970a4d authored by Hugo Beauzée-Luyssen's avatar Hugo Beauzée-Luyssen

Core: Fix projectLoaded semantic. Turn it into projectLoading

parent df3cb278
......@@ -81,8 +81,8 @@ MainWindow::MainWindow( Backend::IBackend* backend, QWidget *parent )
m_ui.setupUi( this );
Core::getInstance()->logger()->setup();
connect( Core::getInstance(), SIGNAL( projectLoaded( Project* ) ),
this, SLOT( onProjectLoaded( Project* ) ) );
connect( Core::getInstance(), SIGNAL( projectLoading( Project* ) ),
this, SLOT( onProjectLoading( Project* ) ), Qt::DirectConnection );
//Preferences
initVlmcPreferences();
//All preferences have been created: restore them:
......@@ -833,7 +833,7 @@ MainWindow::canRedoChanged( bool canRedo )
}
void
MainWindow::onProjectLoaded(Project* project)
MainWindow::onProjectLoading(Project* project)
{
createProjectPreferences();
connect( project, SIGNAL( projectUpdated( const QString&, bool ) ), this, SLOT( projectUpdated( const QString&, bool ) ) );
......
......@@ -159,7 +159,7 @@ private slots:
void cleanStateChanged( bool isClean );
void canUndoChanged( bool canUndo );
void canRedoChanged( bool canRedo );
void onProjectLoaded( Project* project );
void onProjectLoading( Project* project );
signals:
void toolChanged( ToolButtons );
......
......@@ -101,7 +101,7 @@ Core::onProjectLoaded( Project* project )
m_automaticBackup->setProject( project );
m_recentProjects->setProject( project );
emit projectLoaded( project );
emit projectLoading( project );
}
Settings*
......
......@@ -55,7 +55,15 @@ class Core : public QObject, public Singleton<Core>
void onProjectLoaded( Project* project );
signals:
void projectLoaded( Project* project );
/**
* @brief projectLoaded Will be emited right before a project starts loading.
*
* When this is emited, all Project related instances are created. The project itself
* however won't be loaded (no settings, no media, ...)
* This should be used with Qt::DirectConnection in order not to miss any media/clip
* loading events.
*/
void projectLoading( Project* project );
private:
Core();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment