}catch(int) { }
#endif
Layer::Handle new_layer(Layer::create("PasteCanvas"));
- dynamic_cast<Layer_PasteCanvas*>(new_layer.get())->set_do_not_muck_with_time(true);
+ dynamic_cast<Layer_PasteCanvas*>(new_layer.get())->set_muck_with_time(false);
Layer::ParamList param_list(paste_canvas->get_param_list());
//param_list.erase("canvas");
new_layer->set_param_list(param_list);
dynamic_cast<Layer_PasteCanvas*>(new_layer.get())->set_sub_canvas(sub_canvas);
- dynamic_cast<Layer_PasteCanvas*>(new_layer.get())->set_do_not_muck_with_time(false);
+ dynamic_cast<Layer_PasteCanvas*>(new_layer.get())->set_muck_with_time(true);
layer=new_layer;
}
time_offset(0)
{
children_lock=false;
- do_not_muck_with_time_=false;
+ muck_with_time_=true;
curr_time=Time::begin();
}
void
Layer_PasteCanvas::set_sub_canvas(etl::handle<synfig::Canvas> x)
{
- if(canvas && !do_not_muck_with_time_)
+ if(canvas && muck_with_time_)
remove_child(canvas.get());
if(canvas && (canvas->is_inline() || !get_canvas() || get_canvas()->get_root()!=canvas->get_root()))
if(canvas)
bounds=(canvas->get_context().get_full_bounding_rect()-canvas->rend_desc().get_focus())*exp(zoom)+origin+canvas->rend_desc().get_focus();
- if(canvas && !do_not_muck_with_time_)
+ if(canvas && muck_with_time_)
add_child(canvas.get());
if(canvas && (canvas->is_inline() || !get_canvas() || get_canvas()->get_root()!=canvas->get_root()))
if(!canvas || !get_amount())
return context.accelerated_render(surface,quality,renddesc,cb);
- if(!do_not_muck_with_time_ && curr_time!=Time::begin() && canvas->get_time()!=curr_time+time_offset)
+ if(muck_with_time_ && curr_time!=Time::begin() && canvas->get_time()!=curr_time+time_offset)
{
canvas->set_time(curr_time+time_offset);
}
bool optimize_layers(synfig::Context context,synfig::CanvasBase&)const;
- bool do_not_muck_with_time_;
+ bool muck_with_time_;
bool children_lock;
virtual void on_canvas_set();
- void set_do_not_muck_with_time(bool x=true) { do_not_muck_with_time_=true; }
+ void set_muck_with_time(bool x=false) { muck_with_time_=false; }
etl::handle<synfig::Canvas> get_sub_canvas()const { return canvas; }
void set_sub_canvas(etl::handle<synfig::Canvas> x);