New member ValueNode_DynamicList::set_member_canvas() for setting the canvas in each...
authordooglus <dooglus@1f10aa63-cdf2-0310-b900-c93c546f37ac>
Tue, 19 Feb 2008 18:51:09 +0000 (18:51 +0000)
committerdooglus <dooglus@1f10aa63-cdf2-0310-b900-c93c546f37ac>
Tue, 19 Feb 2008 18:51:09 +0000 (18:51 +0000)
git-svn-id: http://svn.voria.com/code@1761 1f10aa63-cdf2-0310-b900-c93c546f37ac

synfig-core/trunk/src/synfig/valuenode_dynamiclist.cpp
synfig-core/trunk/src/synfig/valuenode_dynamiclist.h

index 7cdbd1f..1f75ab9 100644 (file)
@@ -713,6 +713,13 @@ ValueNode_DynamicList::check_type(ValueBase::Type type)
        return type==ValueBase::TYPE_LIST;
 }
 
+void
+ValueNode_DynamicList::set_member_canvas(etl::loose_handle<Canvas> canvas)
+{
+       for (vector<ListEntry>::iterator iter = list.begin(); iter != list.end(); iter++)
+               iter->value_node->set_parent_canvas(canvas);
+}
+
 ValueBase::Type
 ValueNode_DynamicList::get_contained_type()const
 {
index 990240b..e73afd9 100644 (file)
@@ -41,6 +41,7 @@
 
 namespace synfig {
 class ValueNode_BLine;
+class Canvas;
 
 /*! \class ValueNode_DynamicList
 **     \brief Animated List ValueNode
@@ -197,6 +198,8 @@ public:
        bool get_loop()const { return loop_; }
        void set_loop(bool x) { loop_=x; }
 
+       void set_member_canvas(etl::loose_handle<Canvas>);
+
        ValueBase::Type get_contained_type()const;