From: joncruz Date: Mon, 5 Jun 2006 08:10:41 +0000 (+0000) Subject: Allow "new layer" action when no layer selected X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=56a1bf211a8a67436df1a898b456639f69f04c06;p=inkscape.git Allow "new layer" action when no layer selected --- diff --git a/ChangeLog b/ChangeLog index bcf3baae6..38d217201 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2006-06-02 Jon A. Cruz + + * src/dialogs/layers-panel.cpp: + + Allow action when no layer selected. + Fixes bugs #1494646. + 2006-06-02 Jon A. Cruz * trace/siox.cpp: @@ -9,7 +16,7 @@ * src/dialogs/layers-panel.h, src/dialogs/layers-panel.cpp: Blocked signal when changes are not from the layers UI. - Fixes bug #1495406. + Fixes bugs #1495406 and most of #1494646. 2006-06-02 Colin Marquardt diff --git a/src/dialogs/layers-panel.cpp b/src/dialogs/layers-panel.cpp index 82def825c..e89e5050d 100644 --- a/src/dialogs/layers-panel.cpp +++ b/src/dialogs/layers-panel.cpp @@ -314,9 +314,13 @@ bool LayersPanel::_executeAction() { // Make sure selected layer hasn't changed since the action was triggered if ( _pending - && !( (_desktop && _desktop->currentLayer()) - && (_desktop->currentLayer() != _pending->_target) - ) ) { + && ( + (_pending->_actionCode == BUTTON_NEW) + || !( (_desktop && _desktop->currentLayer()) + && (_desktop->currentLayer() != _pending->_target) + ) + ) + ) { int val = _pending->_actionCode; // SPObject* target = _pending->_target;