Action::ValueDescConvert::ValueDescConvert()
{
+ time=(Time::begin()-1);
}
Action::ParamVocab
.set_desc(_("The type of ValueNode that you want to be converted to"))
);
+ ret.push_back(ParamDesc("time",Param::TYPE_TIME)
+ .set_local_name(_("Time"))
+ );
+
return ret;
}
return true;
}
+ if(name=="time" && param.get_type()==Param::TYPE_TIME)
+ {
+ time=param.get_time();
+
+ return true;
+ }
+
return Action::CanvasSpecific::set_param(name,param);
}
{
if(!value_desc || type.empty())
return false;
+ if(time==(Time::begin()-1))
+ {
+ synfig::error("Missing time");
+ return false;
+ }
return Action::CanvasSpecific::is_ready();
}
if(value_desc.is_const())
value=value_desc.get_value();
else if(value_desc.is_value_node())
- value=(*value_desc.get_value_node())(0);
+ value=(*value_desc.get_value_node())(time);
else
throw Error(_("Unable to decipher ValueDesc (Bug?)"));
action->set_param("canvas_interface",etl::loose_handle<CanvasInterface>(this));
action->set_param("value_desc",value_desc);
action->set_param("type",type);
+ action->set_param("time",get_time());
if(!action->is_ready())
{