From 828216f2051e31236e9edbc79be2cf7833abbc7e Mon Sep 17 00:00:00 2001 From: dooglus Date: Thu, 10 Jan 2008 23:22:51 +0000 Subject: [PATCH] Show the layer name in the history dialog when adding a new layer from the 'new layer' menu. git-svn-id: http://svn.voria.com/code@1320 1f10aa63-cdf2-0310-b900-c93c546f37ac --- synfig-studio/trunk/src/synfigapp/actions/layeradd.cpp | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/synfig-studio/trunk/src/synfigapp/actions/layeradd.cpp b/synfig-studio/trunk/src/synfigapp/actions/layeradd.cpp index 9275d0a..f1e55f1 100644 --- a/synfig-studio/trunk/src/synfigapp/actions/layeradd.cpp +++ b/synfig-studio/trunk/src/synfigapp/actions/layeradd.cpp @@ -44,7 +44,7 @@ using namespace Action; /* === M A C R O S ========================================================= */ -ACTION_INIT(Action::LayerAdd); +ACTION_INIT_NO_GET_LOCAL_NAME(Action::LayerAdd); ACTION_SET_NAME(Action::LayerAdd,"layer_add"); ACTION_SET_LOCAL_NAME(Action::LayerAdd,N_("Add Layer")); ACTION_SET_TASK(Action::LayerAdd,"add"); @@ -63,6 +63,15 @@ Action::LayerAdd::LayerAdd() { } +synfig::String +Action::LayerAdd::get_local_name()const +{ + if (layer) + return strprintf("%s '%s'", _("Add Layer"), layer->get_local_name().c_str()); + else + return _("Add Layer"); +} + Action::ParamVocab Action::LayerAdd::get_param_vocab() { -- 2.7.4