From 5b22a003be75c72b07ae9ed90496be9f5bee4992 Mon Sep 17 00:00:00 2001 From: Nathan Lee <2431820-nathanal@users.noreply.gitlab.com> Date: Wed, 6 Nov 2019 09:37:05 +1100 Subject: Use same label for Layers and Objects dialogs Also prevent crash for unset ids in Object Properties Fix https://gitlab.com/inkscape/inbox/issues/1129 --- src/ui/dialog/layers.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/ui/dialog/layers.cpp') diff --git a/src/ui/dialog/layers.cpp b/src/ui/dialog/layers.cpp index 06af29a6e..a2684267b 100644 --- a/src/ui/dialog/layers.cpp +++ b/src/ui/dialog/layers.cpp @@ -312,9 +312,9 @@ bool LayersPanel::_checkForUpdated(const Gtk::TreePath &/*path*/, const Gtk::Tre * with the correct value (sp-object bug?). So use the inkscape:label attribute instead which * has the correct value (bug #168351) */ - //row[_model->_colLabel] = layer->label() ? layer->label() : layer->getId(); + //row[_model->_colLabel] = layer->label() ? layer->label() : layer->defaultLabel(); gchar const *label = layer->getAttribute("inkscape:label"); - row[_model->_colLabel] = label ? label : layer->getId(); + row[_model->_colLabel] = label ? label : layer->defaultLabel(); row[_model->_colVisible] = SP_IS_ITEM(layer) ? !SP_ITEM(layer)->isHidden() : false; row[_model->_colLocked] = SP_IS_ITEM(layer) ? SP_ITEM(layer)->isLocked() : false; -- cgit v1.2.3