'quit -> "want to save?" -> yes -> cancel' should go back to working on the unsaved...
[synfig.git] / synfig-studio / trunk / src / gtkmm / state_bline.cpp
index c511366..0b61bb1 100644 (file)
@@ -163,7 +163,7 @@ public:
        Smach::event_result event_mouse_motion_handler(const Smach::event& x);
        Smach::event_result event_refresh_tool_options(const Smach::event& x);
 
-       Smach::event_result event_hijack(const Smach::event& x) { return Smach::RESULT_ACCEPT; }
+       Smach::event_result event_hijack(const Smach::event& /*x*/) { return Smach::RESULT_ACCEPT; }
 
        void refresh_tool_options();
 
@@ -186,10 +186,10 @@ public:
        bool run_();
        bool run();
 
-       bool no_egress_on_selection_change;
-       Smach::event_result event_layer_selection_changed_handler(const Smach::event& x)
+       bool egress_on_selection_change;
+       Smach::event_result event_layer_selection_changed_handler(const Smach::event& /*x*/)
        {
-               if(!no_egress_on_selection_change)
+               if(egress_on_selection_change)
                        throw Smach::egress_exception();
                return Smach::RESULT_OK;
        }
@@ -324,7 +324,7 @@ StateBLine_Context::StateBLine_Context(CanvasView* canvas_view):
        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(),
@@ -338,7 +338,7 @@ StateBLine_Context::StateBLine_Context(CanvasView* canvas_view):
        spin_feather(adj_feather,0.01,4)
 {
        depth=-1;
-       no_egress_on_selection_change=false;
+       egress_on_selection_change=true;
        load_settings();
 
        // Set up the tool options dialog
@@ -357,7 +357,7 @@ StateBLine_Context::StateBLine_Context(CanvasView* canvas_view):
        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();
@@ -409,7 +409,7 @@ StateBLine_Context::refresh_tool_options()
 }
 
 Smach::event_result
-StateBLine_Context::event_refresh_tool_options(const Smach::event& x)
+StateBLine_Context::event_refresh_tool_options(const Smach::event& /*x*/)
 {
        refresh_tool_options();
        return Smach::RESULT_ACCEPT;
@@ -425,7 +425,7 @@ StateBLine_Context::~StateBLine_Context()
        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);
@@ -442,7 +442,7 @@ StateBLine_Context::~StateBLine_Context()
 }
 
 Smach::event_result
-StateBLine_Context::event_stop_handler(const Smach::event& x)
+StateBLine_Context::event_stop_handler(const Smach::event& /*x*/)
 {
        synfig::info("STATE RotoBLine: Received Stop Event");
 //     run();
@@ -453,7 +453,7 @@ StateBLine_Context::event_stop_handler(const Smach::event& x)
 }
 
 Smach::event_result
-StateBLine_Context::event_refresh_handler(const Smach::event& x)
+StateBLine_Context::event_refresh_handler(const Smach::event& /*x*/)
 {
        synfig::info("STATE RotoBLine: Received Refresh Event");
        refresh_ducks();
@@ -695,10 +695,10 @@ StateBLine_Context::run_()
                        }*/
                }
 
-               no_egress_on_selection_change=true;
+               egress_on_selection_change=false;
                get_canvas_interface()->get_selection_manager()->clear_selected_layers();
                get_canvas_interface()->get_selection_manager()->set_selected_layers(layer_selection);
-               no_egress_on_selection_change=false;
+               egress_on_selection_change=true;
 
                //if(finish_bline_dialog.get_region_flag() || finish_bline_dialog.get_bline_flag())
                //      get_canvas_interface()->signal_dirty_preview()();
@@ -730,7 +730,7 @@ StateBLine_Context::event_mouse_motion_handler(const Smach::event& x)
 }
 
 Smach::event_result
-StateBLine_Context::event_mouse_release_handler(const Smach::event& x)
+StateBLine_Context::event_mouse_release_handler(const Smach::event& /*x*/)
 {
        if(curr_duck)
        {