# HG changeset patch # User Chris Cannam # Date 1396425111 -3600 # Node ID c11701af6bb4a558800ecdbafe92bbea16fcd30e # Parent b2ca08d16293805f4e4b6e135a659efe8fd1fe95# Parent dd07d48d7d4f7d033299a9142e04718b86c0ef1d Merge from branch tonioni diff -r b2ca08d16293 -r c11701af6bb4 framework/Document.cpp --- a/framework/Document.cpp Tue Mar 11 17:35:02 2014 +0000 +++ b/framework/Document.cpp Wed Apr 02 08:51:51 2014 +0100 @@ -1193,6 +1193,7 @@ m_d(d), m_view(view), m_layer(layer), + m_wasDormant(layer->isLayerDormant(view)), m_name(qApp->translate("RemoveLayerCommand", "Delete %1 Layer").arg(layer->objectName())), m_added(true) { @@ -1246,7 +1247,7 @@ Document::RemoveLayerCommand::unexecute() { m_view->addLayer(m_layer); - m_layer->setLayerDormant(m_view, false); + m_layer->setLayerDormant(m_view, m_wasDormant); m_d->addToLayerViewMap(m_layer, m_view); m_added = true; diff -r b2ca08d16293 -r c11701af6bb4 framework/Document.h --- a/framework/Document.h Tue Mar 11 17:35:02 2014 +0000 +++ b/framework/Document.h Wed Apr 02 08:51:51 2014 +0100 @@ -377,6 +377,7 @@ Document *m_d; View *m_view; // I don't own this Layer *m_layer; // Document owns this, but I determine its lifespan + bool m_wasDormant; QString m_name; bool m_added; };