X-Git-Url: https://git.pterodactylus.net/?a=blobdiff_plain;f=synfig-studio%2Ftrunk%2Fsrc%2Fsynfigapp%2Factions%2Fkeyframeset.cpp;h=bfbee21d1620a03f0eb6f44a429bf952273c6540;hb=74d03302d1e6f05f1f90d4c2a3b38a03aa51dc86;hp=62c78597837a58780bbb20a8f06deed62d2f3c28;hpb=02252941b29de64037116f4d37991a38d9ff0d94;p=synfig.git diff --git a/synfig-studio/trunk/src/synfigapp/actions/keyframeset.cpp b/synfig-studio/trunk/src/synfigapp/actions/keyframeset.cpp index 62c7859..bfbee21 100644 --- a/synfig-studio/trunk/src/synfigapp/actions/keyframeset.cpp +++ b/synfig-studio/trunk/src/synfigapp/actions/keyframeset.cpp @@ -5,16 +5,17 @@ ** $Id: keyframeset.cpp,v 1.1.1.1 2005/01/07 03:34:37 darco Exp $ ** ** \legal -** Copyright (c) 2002 Robert B. Quattlebaum Jr. +** Copyright (c) 2002-2005 Robert B. Quattlebaum Jr., Adrian Bentley ** -** This software and associated documentation -** are CONFIDENTIAL and PROPRIETARY property of -** the above-mentioned copyright holder. +** 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. ** -** You may not copy, print, publish, or in any -** other way distribute this software without -** a prior written agreement with -** the copyright holder. +** 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 */ /* ========================================================================= */ @@ -274,11 +275,11 @@ Action::KeyframeSet::process_value_desc(const synfigapp::ValueDesc& value_desc) // If we are a dynamic list, then we need to update the ActivePoints if(ValueNode_DynamicList::Handle::cast_dynamic(value_node)) { - ValueNode_DynamicList::Handle value_node(ValueNode_DynamicList::Handle::cast_dynamic(value_node)); + ValueNode_DynamicList::Handle value_node_dynamic(ValueNode_DynamicList::Handle::cast_dynamic(value_node)); int i; - for(i=0;ilink_count();i++) + for(i=0;ilink_count();i++) { - synfigapp::ValueDesc value_desc(value_node,i); + synfigapp::ValueDesc value_desc(value_node_dynamic,i); if(new_time>keyframe_prev && new_timelist[i].find(old_time); + activepoint=*value_node_dynamic->list[i].find(old_time); activepoint.set_time(new_time); } catch(...) { activepoint.set_time(new_time); - activepoint.set_state(value_node->list[i].status_at_time(old_time)); + activepoint.set_state(value_node_dynamic->list[i].status_at_time(old_time)); activepoint.set_priority(0); } action->set_param("activepoint",activepoint); @@ -329,24 +330,24 @@ Action::KeyframeSet::process_value_desc(const synfigapp::ValueDesc& value_desc) } //else { - ValueNode_Animated::Handle value_node(ValueNode_Animated::Handle::cast_dynamic(value_node)); + ValueNode_Animated::Handle value_node_animated(ValueNode_Animated::Handle::cast_dynamic(value_node)); Action::Handle action(WaypointSetSmart::create()); action->set_param("canvas",get_canvas()); action->set_param("canvas_interface",get_canvas_interface()); - action->set_param("value_node",ValueNode::Handle(value_node)); + action->set_param("value_node",ValueNode::Handle(value_node_animated)); Waypoint waypoint; try { - waypoint=*value_node->find(old_time); + waypoint=*value_node_animated->find(old_time); waypoint.set_time(new_time); } catch(...) { waypoint.set_time(new_time); - waypoint.set_value((*value_node)(old_time)); + waypoint.set_value((*value_node_animated)(old_time)); } action->set_param("waypoint",waypoint);