X-Git-Url: https://git.pterodactylus.net/?a=blobdiff_plain;ds=inline;f=synfig-core%2Ftrunk%2Fsrc%2Fsynfig%2Fvaluenode_greyed.cpp;fp=synfig-core%2Ftrunk%2Fsrc%2Fsynfig%2Fvaluenode_greyed.cpp;h=4e3536ea2877b65becbf0f97a0628626e35c98ec;hb=78f44c3bf98f8b0b6a6b74ef5aba07c345639d65;hp=0000000000000000000000000000000000000000;hpb=66f34e1afba6a05b41bada24417f62c0ca0ea2c4;p=synfig.git diff --git a/synfig-core/trunk/src/synfig/valuenode_greyed.cpp b/synfig-core/trunk/src/synfig/valuenode_greyed.cpp new file mode 100644 index 0000000..4e3536e --- /dev/null +++ b/synfig-core/trunk/src/synfig/valuenode_greyed.cpp @@ -0,0 +1,82 @@ +/* === S Y N F I G ========================================================= */ +/*! \file valuenode_greyed.cpp +** \brief Implementation of the "Greyed" valuenode conversion. +** +** $Id$ +** +** \legal +** Copyright (c) 2008 Chris Moore +** +** This package is free software; you can redistribute it and/or +** modify it under the terms of the GNU General Public License as +** published by the Free Software Foundation; either version 2 of +** the License, or (at your option) any later version. +** +** This package is distributed in the hope that it will be useful, +** but WITHOUT ANY WARRANTY; without even the implied warranty of +** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +** General Public License for more details. +** \endlegal +*/ +/* ========================================================================= */ + +/* === H E A D E R S ======================================================= */ + +#ifdef USING_PCH +# include "pch.h" +#else +#ifdef HAVE_CONFIG_H +# include +#endif + +#include "valuenode_greyed.h" +#include "valuenode_const.h" + +#endif + +/* === U S I N G =========================================================== */ + +using namespace synfig; + +/* === M A C R O S ========================================================= */ + +/* === G L O B A L S ======================================================= */ + +/* === P R O C E D U R E S ================================================= */ + +/* === M E T H O D S ======================================================= */ + +ValueNode_Greyed::ValueNode_Greyed(const ValueBase::Type &x): + ValueNode_Reference(x) +{ +} + +ValueNode_Greyed::ValueNode_Greyed(const ValueNode::Handle &x): + ValueNode_Reference(x->get_type()) +{ + set_link("link",x); +} + +ValueNode_Greyed* +ValueNode_Greyed::create(const ValueBase &x) +{ + return new ValueNode_Greyed(ValueNode_Const::create(x)); +} + +LinkableValueNode* +ValueNode_Greyed::create_new()const +{ + return new ValueNode_Greyed(get_type()); +} + +String +ValueNode_Greyed::get_name()const +{ + return "greyed"; +} + +String +ValueNode_Greyed::get_local_name()const +{ + return _("Greyed"); +}