projects
/
synfig.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Use Color::is_straight(). Also, re-enable the optimization for straight blending...
[synfig.git]
/
synfig-studio
/
trunk
/
src
/
gtkmm
/
state_width.cpp
diff --git
a/synfig-studio/trunk/src/gtkmm/state_width.cpp
b/synfig-studio/trunk/src/gtkmm/state_width.cpp
index
bbe802d
..
6f63fe3
100644
(file)
--- a/
synfig-studio/trunk/src/gtkmm/state_width.cpp
+++ b/
synfig-studio/trunk/src/gtkmm/state_width.cpp
@@
-2,7
+2,7
@@
/*! \file state_width.cpp
** \brief Template File
**
/*! \file state_width.cpp
** \brief Template File
**
-** $Id
: state_width.cpp,v 1.1.1.1 2005/01/07 03:34:37 darco Exp
$
+** $Id$
**
** \legal
** Copyright (c) 2002-2005 Robert B. Quattlebaum Jr., Adrian Bentley
**
** \legal
** Copyright (c) 2002-2005 Robert B. Quattlebaum Jr., Adrian Bentley
@@
-55,6
+55,8
@@
#include <ETL/clock>
#include <ETL/clock>
+#include "general.h"
+
#endif
/* === U S I N G =========================================================== */
#endif
/* === U S I N G =========================================================== */
@@
-208,8
+210,8
@@
StateWidth_Context::reset()
StateWidth_Context::StateWidth_Context(CanvasView* canvas_view):
canvas_view_(canvas_view),
is_working(*canvas_view),
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()),
old_duckmask(get_work_area()->get_type_mask()),
settings(synfigapp::Main::get_selected_input_device()->settings()),
@@
-243,7
+245,7
@@
StateWidth_Context::StateWidth_Context(CanvasView* canvas_view):
App::dialog_tool_options->present();
// Turn off layer clicking
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();
// clear out the ducks
//get_work_area()->clear_ducks();
@@
-278,7
+280,7
@@
StateWidth_Context::StateWidth_Context(CanvasView* canvas_view):
}
//Disable duck clicking for the maximum coolness :)
}
//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
get_work_area()->set_type_mask((Duck::Type)((int)Duck::TYPE_WIDTH + (int)Duck::TYPE_RADIUS));
// Turn the mouse pointer to crosshairs
@@
-288,8
+290,8
@@
StateWidth_Context::StateWidth_Context(CanvasView* canvas_view):
//prev_table_status=get_canvas_view()->tables_are_visible();
//if(prev_table_status)get_canvas_view()->hide_tables();
//prev_table_status=get_canvas_view()->tables_are_visible();
//if(prev_table_status)get_canvas_view()->hide_tables();
- //
Hid
e the time bar
- //get_canvas_view()->
hide_timebar(
);
+ //
Disabl
e the time bar
+ //get_canvas_view()->
set_sensitive_timebar(false
);
// Connect a signal
//get_work_area()->signal_user_click().connect(sigc::mem_fun(*this,&studio::StateWidth_Context::on_user_click));
// Connect a signal
//get_work_area()->signal_user_click().connect(sigc::mem_fun(*this,&studio::StateWidth_Context::on_user_click));
@@
-307,7
+309,7
@@
StateWidth_Context::refresh_tool_options()
}
Smach::event_result
}
Smach::event_result
-StateWidth_Context::event_refresh_tool_options(const Smach::event&
x
)
+StateWidth_Context::event_refresh_tool_options(const Smach::event&
/*x*/
)
{
refresh_tool_options();
return Smach::RESULT_ACCEPT;
{
refresh_tool_options();
return Smach::RESULT_ACCEPT;
@@
-327,10
+329,10
@@
StateWidth_Context::~StateWidth_Context()
}
// Restore Duck clicking
}
// 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
// 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();
// Restore the mouse pointer
get_work_area()->reset_cursor();
@@
-341,9
+343,8
@@
StateWidth_Context::~StateWidth_Context()
// Tool options be rid of ye!!
App::dialog_tool_options->clear();
// Tool options be rid of ye!!
App::dialog_tool_options->clear();
- // Show the time bar
- if(get_canvas_view()->get_canvas()->rend_desc().get_time_start()!=get_canvas_view()->get_canvas()->rend_desc().get_time_end())
- get_canvas_view()->show_timebar();
+ // Enable the time bar
+ //get_canvas_view()->set_sensitive_timebar(true);
// Bring back the tables if they were out before
//if(prev_table_status)get_canvas_view()->show_tables();
// Bring back the tables if they were out before
//if(prev_table_status)get_canvas_view()->show_tables();
@@
-355,13
+356,13
@@
StateWidth_Context::~StateWidth_Context()
}
Smach::event_result
}
Smach::event_result
-StateWidth_Context::event_stop_handler(const Smach::event&
x
)
+StateWidth_Context::event_stop_handler(const Smach::event&
/*x*/
)
{
throw Smach::egress_exception();
}
Smach::event_result
{
throw Smach::egress_exception();
}
Smach::event_result
-StateWidth_Context::event_refresh_handler(const Smach::event&
x
)
+StateWidth_Context::event_refresh_handler(const Smach::event&
/*x*/
)
{
refresh_ducks();
return Smach::RESULT_ACCEPT;
{
refresh_ducks();
return Smach::RESULT_ACCEPT;
@@
-462,7
+463,7
@@
StateWidth_Context::event_mouse_handler(const Smach::event& x)
{
const EventMouse& event(*reinterpret_cast<const EventMouse*>(&x));
{
const EventMouse& event(*reinterpret_cast<const EventMouse*>(&x));
- //handle
z
e click
+ //handle
th
e click
if( (event.key == EVENT_WORKAREA_MOUSE_BUTTON_DOWN || event.key == EVENT_WORKAREA_MOUSE_BUTTON_DRAG)
&& event.button == BUTTON_LEFT )
{
if( (event.key == EVENT_WORKAREA_MOUSE_BUTTON_DOWN || event.key == EVENT_WORKAREA_MOUSE_BUTTON_DRAG)
&& event.button == BUTTON_LEFT )
{