From: dooglus Date: Sun, 3 Feb 2008 19:22:07 +0000 (+0000) Subject: Improve the description of a ValueNode to include its exported name if requested... X-Git-Url: https://git.pterodactylus.net/?a=commitdiff_plain;h=82140c53ab82809987a3206f4691062582f6c04c;p=synfig.git Improve the description of a ValueNode to include its exported name if requested to do so. git-svn-id: http://svn.voria.com/code@1566 1f10aa63-cdf2-0310-b900-c93c546f37ac --- diff --git a/synfig-core/trunk/src/synfig/valuenode.cpp b/synfig-core/trunk/src/synfig/valuenode.cpp index 51cd1ff..af1fb0d 100644 --- a/synfig-core/trunk/src/synfig/valuenode.cpp +++ b/synfig-core/trunk/src/synfig/valuenode.cpp @@ -314,10 +314,18 @@ ValueNode::set_id(const String &x) String ValueNode::get_description(bool show_exported_name)const { + String ret(_("ValueNode")); + if (dynamic_cast(this)) return (dynamic_cast(this))->get_description(-1, show_exported_name); - return "ValueNode"; + if (show_exported_name && !is_exported()) + show_exported_name = false; + + if (show_exported_name) + ret += strprintf(" (%s)", get_id().c_str()); + + return ret; } ValueNodeList::ValueNodeList():