projects
/
synfig.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Use 0 for the index if the closest point is on the segment which closes the loop...
[synfig.git]
/
synfig-studio
/
trunk
/
src
/
gtkmm
/
state_rectangle.cpp
diff --git
a/synfig-studio/trunk/src/gtkmm/state_rectangle.cpp
b/synfig-studio/trunk/src/gtkmm/state_rectangle.cpp
index
5511ad0
..
e672d6c
100644
(file)
--- a/
synfig-studio/trunk/src/gtkmm/state_rectangle.cpp
+++ b/
synfig-studio/trunk/src/gtkmm/state_rectangle.cpp
@@
-49,6
+49,8
@@
#include "duck.h"
#include <synfigapp/main.h>
#include "duck.h"
#include <synfigapp/main.h>
+#include "general.h"
+
#endif
/* === U S I N G =========================================================== */
#endif
/* === U S I N G =========================================================== */
@@
-128,10
+130,10
@@
public:
void save_settings();
void reset();
void increment_id();
void save_settings();
void reset();
void increment_id();
- bool
no_
egress_on_selection_change;
+ bool egress_on_selection_change;
Smach::event_result event_layer_selection_changed_handler(const Smach::event& /*x*/)
{
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;
}
throw Smach::egress_exception();
return Smach::RESULT_OK;
}
@@
-211,7
+213,10
@@
StateRectangle_Context::increment_id()
if(id[id.size()-1]<='9' && id[id.size()-1]>='0')
{
// figure out how many digits it is
if(id[id.size()-1]<='9' && id[id.size()-1]>='0')
{
// figure out how many digits it is
- for(digits=0;(int)id.size()-1>=digits && id[id.size()-1-digits]<='9' && id[id.size()-1-digits]>='0';digits++)while(false);
+ for (digits = 0;
+ (int)id.size()-1 >= digits && id[id.size()-1-digits] <= '9' && id[id.size()-1-digits] >= '0';
+ digits++)
+ ;
String str_number;
str_number=String(id,id.size()-digits,id.size());
String str_number;
str_number=String(id,id.size()-digits,id.size());
@@
-248,7
+253,7
@@
StateRectangle_Context::StateRectangle_Context(CanvasView* canvas_view):
spin_expand(adj_expand,0.1,3),
check_invert(_("Invert"))
{
spin_expand(adj_expand,0.1,3),
check_invert(_("Invert"))
{
-
no_egress_on_selection_change=fals
e;
+
egress_on_selection_change=tru
e;
load_settings();
// Set up the tool options dialog
load_settings();
// Set up the tool options dialog
@@
-386,10
+391,10
@@
StateRectangle_Context::make_rectangle(const Point& _p1, const Point& _p2)
layer->set_description(get_id());
get_canvas_interface()->signal_layer_new_description()(layer,layer->get_description());
layer->set_description(get_id());
get_canvas_interface()->signal_layer_new_description()(layer,layer->get_description());
-
no_egress_on_selection_change=tru
e;
+
egress_on_selection_change=fals
e;
get_canvas_interface()->get_selection_manager()->clear_selected_layers();
get_canvas_interface()->get_selection_manager()->set_selected_layer(layer);
get_canvas_interface()->get_selection_manager()->clear_selected_layers();
get_canvas_interface()->get_selection_manager()->set_selected_layer(layer);
-
no_egress_on_selection_change=fals
e;
+
egress_on_selection_change=tru
e;
//post clean up stuff...
reset();
//post clean up stuff...
reset();