Use the new Layer::get_non_empty_description() method to show the description (or...
[synfig.git] / synfig-studio / trunk / src / synfigapp / actions / layermove.cpp
index 341cc01..4d67c77 100644 (file)
@@ -2,7 +2,7 @@
 /*!    \file layermove.cpp
 **     \brief Template File
 **
-**     $Id: layermove.cpp,v 1.1.1.1 2005/01/07 03:34:37 darco Exp $
+**     $Id$
 **
 **     \legal
 **     Copyright (c) 2002-2005 Robert B. Quattlebaum Jr., Adrian Bentley
@@ -32,6 +32,8 @@
 #include "layermove.h"
 #include <synfigapp/canvasinterface.h>
 
+#include <synfigapp/general.h>
+
 #endif
 
 using namespace std;
@@ -42,14 +44,14 @@ using namespace Action;
 
 /* === M A C R O S ========================================================= */
 
-ACTION_INIT(Action::LayerMove);
+ACTION_INIT_NO_GET_LOCAL_NAME(Action::LayerMove);
 ACTION_SET_NAME(Action::LayerMove,"layer_move");
-ACTION_SET_LOCAL_NAME(Action::LayerMove,_("Move Layer"));
+ACTION_SET_LOCAL_NAME(Action::LayerMove,N_("Move Layer"));
 ACTION_SET_TASK(Action::LayerMove,"move");
 ACTION_SET_CATEGORY(Action::LayerMove,Action::CATEGORY_LAYER);
 ACTION_SET_PRIORITY(Action::LayerMove,0);
 ACTION_SET_VERSION(Action::LayerMove,"0.0");
-ACTION_SET_CVS_ID(Action::LayerMove,"$Id: layermove.cpp,v 1.1.1.1 2005/01/07 03:34:37 darco Exp $");
+ACTION_SET_CVS_ID(Action::LayerMove,"$Id$");
 
 /* === G L O B A L S ======================================================= */
 
@@ -64,6 +66,15 @@ Action::LayerMove::LayerMove():
 {
 }
 
+synfig::String
+Action::LayerMove::get_local_name()const
+{
+       if (layer)
+               return strprintf("%s '%s'", _("Move Layer"), layer->get_non_empty_description().c_str());
+       else
+               return _("Move Layer");
+}
+
 Action::ParamVocab
 Action::LayerMove::get_param_vocab()
 {