Commit fe3dd635 authored by luyikei's avatar luyikei Committed by Hugo Beauzée-Luyssen

MainWindow: Use Qt5 connections for Project

Signed-off-by: Hugo Beauzée-Luyssen's avatarHugo Beauzée-Luyssen <hugo@beauzee.fr>
parent f5ab750c
......@@ -93,14 +93,14 @@ MainWindow::MainWindow( Backend::IBackend* backend, QWidget *parent )
setupCrashTester();
#endif
connect( Core::instance()->project(), SIGNAL( projectNameChanged(QString) ),
this, SLOT( projectNameChanged( QString ) ) );
connect( Core::instance()->project(), SIGNAL( outdatedBackupFileFound() ),
this, SLOT( onOudatedBackupFile() ) );
connect( Core::instance()->project(), SIGNAL( backupProjectLoaded() ),
this, SLOT( onBackupFileLoaded() ) );
connect( Core::instance()->project(), SIGNAL( projectSaved() ),
this, SLOT( onProjectSaved() ) );
connect( Core::instance()->project(), &Project::projectNameChanged,
this, &MainWindow::projectNameChanged );
connect( Core::instance()->project(), &Project::outdatedBackupFileFound,
this, &MainWindow::onOudatedBackupFile );
connect( Core::instance()->project(), &Project::backupProjectLoaded,
this, &MainWindow::onBackupFileLoaded );
connect( Core::instance()->project(), &Project::projectSaved,
this, &MainWindow::onProjectSaved );
connect( Core::instance()->project(), &Project::cleanStateChanged,
this, &MainWindow::cleanStateChanged );
connect( Core::instance()->recentProjects(), &RecentProjects::updated,
......
......@@ -351,12 +351,6 @@ Project::libraryCleanChanged( bool val )
emit cleanStateChanged( m_libraryCleanState == true && m_isClean == true );
}
void
Project::projectNameChanged( const QVariant& projectName )
{
emit projectNameChanged( projectName.toString() );
}
void
Project::autoSaveRequired()
{
......
......@@ -91,7 +91,6 @@ class Project : public QObject
public slots:
void cleanChanged( bool val );
void libraryCleanChanged( bool val );
void projectNameChanged( const QVariant& projectName ); // Proxy slot for projectNameChanged(QString)
void autoSaveRequired();
void autoSaveEnabledChanged( const QVariant& enabled );
void autoSaveIntervalChanged( const QVariant& interval );
......
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