changeset 359:1f2a4ad79967 tonioni

Introduce a new canSaveAs which is active whenever there is a main model; avoid silently overwriting existing session file when saving to audio path
author Chris Cannam
date Fri, 13 Jun 2014 10:37:04 +0100
parents 2da91cceed64
children 88bf6cc73275 b38268e34c09
files framework/MainWindowBase.cpp framework/MainWindowBase.h
diffstat 2 files changed, 2 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/framework/MainWindowBase.cpp	Thu Jun 12 18:52:52 2014 +0100
+++ b/framework/MainWindowBase.cpp	Fri Jun 13 10:37:04 2014 +0100
@@ -528,6 +528,7 @@
     emit canClearSelection(haveSelection);
     emit canEditSelection(haveSelection && haveCurrentEditableLayer);
     emit canSave(m_sessionFile != "" && m_documentModified);
+    emit canSaveAs(haveMainModel);
     emit canSelectPreviousPane(havePrevPane);
     emit canSelectNextPane(haveNextPane);
     emit canSelectPreviousLayer(havePrevLayer);
--- a/framework/MainWindowBase.h	Thu Jun 12 18:52:52 2014 +0100
+++ b/framework/MainWindowBase.h	Fri Jun 13 10:37:04 2014 +0100
@@ -156,6 +156,7 @@
     void canSelectPreviousLayer(bool);
     void canSelectNextLayer(bool);
     void canSave(bool);
+    void canSaveAs(bool);
     void hideSplash();
     void sessionLoaded();
     void audioFileLoaded();