refresh_tool_options();
App::dialog_tool_options->present();
- get_work_area()->allow_layer_clicks=true;
+ get_work_area()->set_allow_layer_clicks(true);
get_work_area()->set_duck_dragger(duck_dragger_);
// get_canvas_view()->work_area->set_cursor(Gdk::CROSSHAIR);
canvas_view_(canvas_view),
is_working(*canvas_view),
loop_(false),
- prev_workarea_layer_status_(get_work_area()->allow_layer_clicks),
+ prev_workarea_layer_status_(get_work_area()->get_allow_layer_clicks()),
duckmatic_push(get_work_area()),
settings(synfigapp::Main::get_selected_input_device()->settings()),
entry_id(),
App::dialog_tool_options->present();
// Turn off layer clicking
- get_work_area()->allow_layer_clicks=false;
+ get_work_area()->set_allow_layer_clicks(false);
// clear out the ducks
get_work_area()->clear_ducks();
get_canvas_view()->work_area->reset_cursor();
// Restore layer clicking
- get_work_area()->allow_layer_clicks=prev_workarea_layer_status_;
+ get_work_area()->set_allow_layer_clicks(prev_workarea_layer_status_);
// Enable the time bar
get_canvas_view()->set_sensitive_timebar(true);
canvas_view_(canvas_view),
is_working(*canvas_view),
duckmatic_push(get_work_area()),
- prev_workarea_layer_status_(get_work_area()->allow_layer_clicks),
+ prev_workarea_layer_status_(get_work_area()->get_allow_layer_clicks()),
settings(synfigapp::Main::get_selected_input_device()->settings()),
entry_id(),
adj_feather(0,0,1,0.01,0.1),
App::dialog_tool_options->present();
// Turn off layer clicking
- get_work_area()->allow_layer_clicks=false;
+ get_work_area()->set_allow_layer_clicks(false);
// clear out the ducks
get_work_area()->clear_ducks();
save_settings();
// Restore layer clicking
- get_work_area()->allow_layer_clicks=prev_workarea_layer_status_;
+ get_work_area()->set_allow_layer_clicks(prev_workarea_layer_status_);
get_canvas_view()->work_area->reset_cursor();
App::dialog_tool_options->clear();
canvas_view_(canvas_view),
is_working(*canvas_view),
loop_(false),
- prev_workarea_layer_status_(get_work_area()->allow_layer_clicks),
+ prev_workarea_layer_status_(get_work_area()->get_allow_layer_clicks()),
settings(synfigapp::Main::get_selected_input_device()->settings()),
entry_id(),
checkbutton_pressure_width(_("Pressure Width")),
get_work_area()->set_type_mask(Duck::TYPE_ALL-Duck::TYPE_TANGENT-Duck::TYPE_WIDTH);
// Turn off layer clicking
- get_work_area()->allow_layer_clicks=false;
+ get_work_area()->set_allow_layer_clicks(false);
// Turn off duck clicking
- get_work_area()->allow_duck_clicks=false;
+ get_work_area()->set_allow_duck_clicks(false);
// clear out the ducks
//get_work_area()->clear_ducks();
get_canvas_view()->work_area->reset_cursor();
// Restore layer clicking
- get_work_area()->allow_layer_clicks=prev_workarea_layer_status_;
+ get_work_area()->set_allow_layer_clicks(prev_workarea_layer_status_);
// Restore duck clicking
- get_work_area()->allow_duck_clicks=true;
+ get_work_area()->set_allow_duck_clicks(true);
// Enable the time bar
get_canvas_view()->set_sensitive_timebar(true);
is_working(*canvas_view),
duckmatic_push(get_work_area()),
settings(synfigapp::Main::get_selected_input_device()->settings()),
- prev_workarea_layer_status_(get_work_area()->allow_layer_clicks),
+ prev_workarea_layer_status_(get_work_area()->get_allow_layer_clicks()),
entry_id()
{
no_egress_on_selection_change=false;
// Turn off layer clicking
- get_work_area()->allow_layer_clicks=false;
+ get_work_area()->set_allow_layer_clicks(false);
get_canvas_view()->work_area->set_cursor(Gdk::CROSSHAIR);
save_settings();
// Restore layer clicking
-// get_work_area()->allow_layer_clicks=prev_workarea_layer_status_;
- get_work_area()->allow_layer_clicks=true;
+// get_work_area()->set_allow_layer_clicks(prev_workarea_layer_status_);
+ get_work_area()->set_allow_layer_clicks(true);
get_canvas_view()->work_area->reset_cursor();
App::dialog_tool_options->clear();
StatePolygon_Context::StatePolygon_Context(CanvasView* canvas_view):
canvas_view_(canvas_view),
is_working(*canvas_view),
- prev_workarea_layer_status_(get_work_area()->allow_layer_clicks),
+ prev_workarea_layer_status_(get_work_area()->get_allow_layer_clicks()),
duckmatic_push(get_work_area()),
settings(synfigapp::Main::get_selected_input_device()->settings()),
entry_id(),
// Turn off layer clicking
- get_work_area()->allow_layer_clicks=false;
+ get_work_area()->set_allow_layer_clicks(false);
// clear out the ducks
get_work_area()->clear_ducks();
save_settings();
// Restore layer clicking
- get_work_area()->allow_layer_clicks=prev_workarea_layer_status_;
+ get_work_area()->set_allow_layer_clicks(prev_workarea_layer_status_);
App::dialog_tool_options->clear();
canvas_view_(canvas_view),
is_working(*canvas_view),
duckmatic_push(get_work_area()),
- prev_workarea_layer_status_(get_work_area()->allow_layer_clicks),
+ prev_workarea_layer_status_(get_work_area()->get_allow_layer_clicks()),
settings(synfigapp::Main::get_selected_input_device()->settings()),
entry_id(),
adj_expand(0,0,1,0.01,0.1),
App::dialog_tool_options->present();
// Turn off layer clicking
- get_work_area()->allow_layer_clicks=false;
+ get_work_area()->set_allow_layer_clicks(false);
// clear out the ducks
get_work_area()->clear_ducks();
save_settings();
// Restore layer clicking
- get_work_area()->allow_layer_clicks = prev_workarea_layer_status_;
+ get_work_area()->set_allow_layer_clicks(prev_workarea_layer_status_);
get_canvas_view()->work_area->reset_cursor();
//App::dialog_tool_options->set_widget(options_table);
App::dialog_tool_options->present();
- get_work_area()->allow_layer_clicks=true;
+ get_work_area()->set_allow_layer_clicks(true);
get_work_area()->set_duck_dragger(duck_dragger_);
// get_canvas_view()->work_area->set_cursor(Gdk::CROSSHAIR);
refresh_tool_options();
App::dialog_tool_options->present();
- get_work_area()->allow_layer_clicks=true;
+ get_work_area()->set_allow_layer_clicks(true);
get_work_area()->set_duck_dragger(duck_dragger_);
// get_canvas_view()->work_area->set_cursor(Gdk::CROSSHAIR);
action_group(Gtk::ActionGroup::create()),
canvas_view_(canvas_view),
is_working(*canvas_view),
- prev_workarea_layer_status_(get_work_area()->allow_layer_clicks),
+ prev_workarea_layer_status_(get_work_area()->get_allow_layer_clicks()),
button_clear_sketch(_("Clear Sketch")),
button_undo_stroke(_("Undo Stroke")),
button_save_sketch(_("Save Sketch")),
App::dialog_tool_options->present();
// Turn off layer clicking
- get_work_area()->allow_layer_clicks=false;
+ get_work_area()->set_allow_layer_clicks(false);
get_canvas_view()->work_area->set_cursor(Gdk::PENCIL);
// Turn off duck clicking
- get_work_area()->allow_duck_clicks=false;
+ get_work_area()->set_allow_duck_clicks(false);
// clear out the ducks
//get_work_area()->clear_ducks();
App::dialog_tool_options->clear();
// Restore layer clicking
- get_work_area()->allow_layer_clicks=prev_workarea_layer_status_;
+ get_work_area()->set_allow_layer_clicks(prev_workarea_layer_status_);
// Restore duck clicking
- get_work_area()->allow_duck_clicks=true;
+ get_work_area()->set_allow_duck_clicks(true);
// Enable the time bar
//get_canvas_view()->set_sensitive_timebar(true);
//App::dialog_tool_options->set_widget(options_table);
App::dialog_tool_options->present();
- get_work_area()->allow_layer_clicks=true;
+ get_work_area()->set_allow_layer_clicks(true);
get_work_area()->set_duck_dragger(duck_dragger_);
App::toolbox->refresh();
StateWidth_Context::StateWidth_Context(CanvasView* canvas_view):
canvas_view_(canvas_view),
is_working(*canvas_view),
- prev_workarea_layer_clicking(get_work_area()->allow_layer_clicks),
- prev_workarea_duck_clicking(get_work_area()->allow_duck_clicks),
+ prev_workarea_layer_clicking(get_work_area()->get_allow_layer_clicks()),
+ prev_workarea_duck_clicking(get_work_area()->get_allow_duck_clicks()),
old_duckmask(get_work_area()->get_type_mask()),
settings(synfigapp::Main::get_selected_input_device()->settings()),
App::dialog_tool_options->present();
// Turn off layer clicking
- get_work_area()->allow_layer_clicks=false;
+ get_work_area()->set_allow_layer_clicks(false);
// clear out the ducks
//get_work_area()->clear_ducks();
}
//Disable duck clicking for the maximum coolness :)
- get_work_area()->allow_duck_clicks = false;
+ get_work_area()->set_allow_duck_clicks(false);
get_work_area()->set_type_mask((Duck::Type)((int)Duck::TYPE_WIDTH + (int)Duck::TYPE_RADIUS));
// Turn the mouse pointer to crosshairs
}
// Restore Duck clicking
- get_work_area()->allow_duck_clicks = prev_workarea_duck_clicking;
+ get_work_area()->set_allow_duck_clicks(prev_workarea_duck_clicking);
// Restore layer clicking
- get_work_area()->allow_layer_clicks = prev_workarea_layer_clicking;
+ get_work_area()->set_allow_layer_clicks(prev_workarea_layer_clicking);
// Restore the mouse pointer
get_work_area()->reset_cursor();
StateZoom_Context::StateZoom_Context(CanvasView* canvas_view):
canvas_view_(canvas_view),
is_working(*canvas_view),
- prev_workarea_layer_status_(get_work_area()->allow_layer_clicks),
+ prev_workarea_layer_status_(get_work_area()->get_allow_layer_clicks()),
settings(synfigapp::Main::get_selected_input_device()->settings())
{
// Set up the tool options dialog
App::dialog_tool_options->present();
// Turn off layer clicking
- get_work_area()->allow_layer_clicks=false;
+ get_work_area()->set_allow_layer_clicks(false);
// clear out the ducks
get_work_area()->clear_ducks(); //???
save_settings();
// Restore layer clicking
- get_work_area()->allow_layer_clicks=prev_workarea_layer_status_;
+ get_work_area()->set_allow_layer_clicks(prev_workarea_layer_status_);
get_canvas_view()->work_area->reset_cursor();
App::dialog_tool_options->clear();
}
+namespace studio
+{
class WorkAreaProgress : public synfig::ProgressCallback
{
WorkArea *work_area;
return cb->amount_complete(current,total);
}
};
+}
bool
studio::WorkArea::async_update_preview()
{
//synfig::info("queue_render_preview(): (re)queuing...");
//render_idle_func_id=g_idle_add_full(G_PRIORITY_DEFAULT,__render_preview,this,NULL);
- render_idle_func_id=g_timeout_add_full(G_PRIORITY_DEFAULT,queue_time,__render_preview,this,NULL);
+ render_idle_func_id=g_timeout_add_full(
+ G_PRIORITY_DEFAULT, // priority -
+ queue_time, // interval - the time between calls to the function, in milliseconds (1/1000ths of a second)
+ __render_preview, // function - function to call
+ this, // data - data to pass to function
+ NULL); // notify - function to call when the idle is removed, or NULL
queued=true;
}
/* else if(rendering)
friend class WorkAreaTarget_Full;
friend class DirtyTrap;
friend class WorkAreaRenderer;
+ friend class WorkAreaProgress;
/*
-- ** -- P U B L I C T Y P E S ---------------------------------------------
etl::loose_handle<synfig::ValueNode> selected_value_node_;
- bool queued;
- bool rendering;
+ bool allow_duck_clicks;
+ bool allow_layer_clicks;
bool cancel;
-
bool curr_guide_is_x;
+ bool dirty;
+ bool queued;
+ bool rendering;
/*
-- ** -- P U B L I C D A T A -----------------------------------------------
int get_tile_w()const { return tile_w; }
int get_tile_h()const { return tile_h; }
+ bool get_allow_layer_clicks() { return allow_layer_clicks; }
+ void set_allow_layer_clicks(bool value) { allow_layer_clicks=value; }
+
+ bool get_allow_duck_clicks() { return allow_duck_clicks; }
+ void set_allow_duck_clicks(bool value) { allow_duck_clicks=value; }
+
// used in renderer_ducks.cpp
bool solid_lines;
- // used in workarea.cpp
- bool dirty;
- // used in mod_mirror/state_mirror.cpp
- bool allow_layer_clicks;
- // used in state_draw.cpp
- bool allow_duck_clicks;
// used in renderer_guides.cpp
GuideList::iterator curr_guide;