From: dooglus Date: Sun, 17 Feb 2008 20:42:53 +0000 (+0000) Subject: Add a few comments. X-Git-Url: https://git.pterodactylus.net/?a=commitdiff_plain;h=4bdf78b11b50c9b9465828c0a7fbc248472a9bf9;p=synfig.git Add a few comments. git-svn-id: http://svn.voria.com/code@1740 1f10aa63-cdf2-0310-b900-c93c546f37ac --- diff --git a/synfig-studio/trunk/src/synfigapp/canvasinterface.cpp b/synfig-studio/trunk/src/synfigapp/canvasinterface.cpp index ce817d8..0677669 100644 --- a/synfig-studio/trunk/src/synfigapp/canvasinterface.cpp +++ b/synfig-studio/trunk/src/synfigapp/canvasinterface.cpp @@ -228,15 +228,21 @@ CanvasInterface::add_layer_to(synfig::String name, synfig::Canvas::Handle canvas // Grab the layer's list of parameters Layer::ParamList paramlist=layer->get_param_list(); Layer::ParamList::iterator iter; + + // loop through the static parameters for(iter=paramlist.begin();iter!=paramlist.end();++iter) { ValueNode::Handle value_node; + // if we find any which are list values then make them into dynamic list valuenodes if(iter->second.get_type()==ValueBase::TYPE_LIST) value_node=LinkableValueNode::create("dynamic_list",iter->second); + // otherwise, if it's a type that can be converted to + // 'composite' (other than the types that can be radial + // composite) then do so else if(LinkableValueNode::check_type("composite",iter->second.get_type()) && - (iter->second.get_type()!=ValueBase::TYPE_COLOR && iter->second.get_type()!=ValueBase::TYPE_VECTOR) - ) + (iter->second.get_type()!=ValueBase::TYPE_COLOR && + iter->second.get_type()!=ValueBase::TYPE_VECTOR)) value_node=LinkableValueNode::create("composite",iter->second); if(value_node)