[vlmc-devel] [PATCH] Fixed vlmc trying to save projects without assigned project file.

Paweł Wegner pawel.wegner95 at gmail.com
Sun Mar 13 12:58:29 CET 2016


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

diff --git a/src/Gui/MainWindow.cpp b/src/Gui/MainWindow.cpp
index fc88afd..8f404e9 100644
--- a/src/Gui/MainWindow.cpp
+++ b/src/Gui/MainWindow.cpp
@@ -778,7 +778,8 @@ MainWindow::saveSettings()
 void
 MainWindow::closeEvent( QCloseEvent* e )
 {
-    if ( Core::getInstance()->project()->isClean() == false )
+    Project *project = Core::getInstance()->project();
+    if ( project->isClean() == false && project->hasProjectFile() )
     {
         QMessageBox msgBox;
         msgBox.setText( QObject::tr( "The project has been modified." ) );
diff --git a/src/Project/Project.h b/src/Project/Project.h
index 17062d3..98debfa 100644
--- a/src/Project/Project.h
+++ b/src/Project/Project.h
@@ -118,7 +118,7 @@ class Project : public QObject
         void                backupProjectLoaded();
         void                outdatedBackupFileFound();
 
-private:
+    private:
         bool                loadWorkflow( const QDomDocument& root );
 
     private:
-- 
2.7.0



More information about the Vlmc-devel mailing list