X-Git-Url: https://git.pterodactylus.net/?a=blobdiff_plain;f=synfig-core%2Fsrc%2Fsynfig%2Fvaluenode_cos.cpp;h=f1ada07b050806b8d3e044f3c181b294207197d4;hb=HEAD;hp=f3e47930ea2b41cf5ce4f3495fde71cb9a1d4ded;hpb=a095981e18cc37a8ecc7cd237cc22b9c10329264;p=synfig.git diff --git a/synfig-core/src/synfig/valuenode_cos.cpp b/synfig-core/src/synfig/valuenode_cos.cpp index f3e4793..f1ada07 100644 --- a/synfig-core/src/synfig/valuenode_cos.cpp +++ b/synfig-core/src/synfig/valuenode_cos.cpp @@ -53,6 +53,8 @@ using namespace synfig; ValueNode_Cos::ValueNode_Cos(const ValueBase &value): LinkableValueNode(value.get_type()) { + Vocab ret(get_children_vocab()); + set_children_vocab(ret); switch(value.get_type()) { case ValueBase::TYPE_REAL: @@ -62,8 +64,6 @@ ValueNode_Cos::ValueNode_Cos(const ValueBase &value): default: throw Exception::BadType(ValueBase::type_local_name(value.get_type())); } - - DCAST_HACK_ENABLE(); } LinkableValueNode* @@ -142,45 +142,23 @@ ValueNode_Cos::get_link_vfunc(int i)const return 0; } -int -ValueNode_Cos::link_count()const +LinkableValueNode::Vocab +ValueNode_Cos::get_children_vocab_vfunc()const { - return 2; -} + if(children_vocab.size()) + return children_vocab; -String -ValueNode_Cos::link_name(int i)const -{ - assert(i>=0 && i=0 && i