X-Git-Url: https://git.pterodactylus.net/?a=blobdiff_plain;f=synfig-studio%2Ftrunk%2Fsrc%2Fsynfigapp%2Factions%2Flayeractivate.cpp;h=948bc6fcdc1c2f1745317b0f6d4200f0485b792c;hb=fc62d51d61bc6ca78c9e96eb2974e3adfcc4468d;hp=e7f6ee1c310498442143766c1b23e884b6cd059f;hpb=c34eaa5441242b3e9a7b7645e9ee4983d14eae85;p=synfig.git diff --git a/synfig-studio/trunk/src/synfigapp/actions/layeractivate.cpp b/synfig-studio/trunk/src/synfigapp/actions/layeractivate.cpp index e7f6ee1..948bc6f 100644 --- a/synfig-studio/trunk/src/synfigapp/actions/layeractivate.cpp +++ b/synfig-studio/trunk/src/synfigapp/actions/layeractivate.cpp @@ -2,7 +2,7 @@ /*! \file layeractivate.cpp ** \brief Template File ** -** $Id: layeractivate.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 "layeractivate.h" #include +#include + #endif using namespace std; @@ -41,18 +43,15 @@ using namespace synfigapp; using namespace Action; /* === M A C R O S ========================================================= */ -#define ACTION_INIT2(class) \ - Action::Base* class::create() { return new class(); } \ - synfig::String class::get_name()const { return name__; } -ACTION_INIT2(Action::LayerActivate); +ACTION_INIT_NO_GET_LOCAL_NAME(Action::LayerActivate); ACTION_SET_NAME(Action::LayerActivate,"layer_activate"); -ACTION_SET_LOCAL_NAME(Action::LayerActivate,_("Activate Layer")); +ACTION_SET_LOCAL_NAME(Action::LayerActivate,N_("Activate Layer")); ACTION_SET_TASK(Action::LayerActivate,"activate"); ACTION_SET_CATEGORY(Action::LayerActivate,Action::CATEGORY_LAYER); ACTION_SET_PRIORITY(Action::LayerActivate,0); ACTION_SET_VERSION(Action::LayerActivate,"0.0"); -ACTION_SET_CVS_ID(Action::LayerActivate,"$Id: layeractivate.cpp,v 1.1.1.1 2005/01/07 03:34:37 darco Exp $"); +ACTION_SET_CVS_ID(Action::LayerActivate,"$Id$"); /* === G L O B A L S ======================================================= */ @@ -69,13 +68,12 @@ Action::LayerActivate::get_local_name()const { if(!layer) return _("Activate Layer"); - String name; - if(layer->get_description().empty()) - name=layer->get_local_name(); - else - name=layer->get_description(); - return (new_status?_("Activate "):_("Deactivate "))+name; + return strprintf("%s '%s'", + new_status + ? _("Activate Layer") + : _("Deactivate Layer"), + layer->get_non_empty_description().c_str()); } Action::ParamVocab