summaryrefslogtreecommitdiffstats
path: root/src/widgets/rect-toolbar.cpp
diff options
context:
space:
mode:
authorTavmjong Bah <tavmjong@free.fr>2018-02-04 19:14:50 +0000
committerTavmjong Bah <tavmjong@free.fr>2018-02-04 19:14:50 +0000
commit2b79799fff8ed89c649a934186c176cb2765823c (patch)
tree1e1da695a98ab4f0fbdb7f07fcd37d0e56730e8d /src/widgets/rect-toolbar.cpp
parentNew "Simple Blend" custom predefined filter effect (original idea by Ivan Lou... (diff)
downloadinkscape-2b79799fff8ed89c649a934186c176cb2765823c.tar.gz
inkscape-2b79799fff8ed89c649a934186c176cb2765823c.zip
Convert UnitTracker to use ink-select-one-action.
Additional code clean up.
Diffstat (limited to 'src/widgets/rect-toolbar.cpp')
-rw-r--r--src/widgets/rect-toolbar.cpp9
1 files changed, 3 insertions, 6 deletions
diff --git a/src/widgets/rect-toolbar.cpp b/src/widgets/rect-toolbar.cpp
index df6abf9da..afa090ba7 100644
--- a/src/widgets/rect-toolbar.cpp
+++ b/src/widgets/rect-toolbar.cpp
@@ -45,6 +45,7 @@
#include "ui/icon-names.h"
#include "ui/tools/rect-tool.h"
#include "ui/uxmanager.h"
+#include "ui/widget/ink-select-one-action.h"
#include "ui/widget/unit-tracker.h"
#include "widgets/ege-adjustment-action.h"
@@ -327,7 +328,6 @@ void sp_rect_toolbox_prep(SPDesktop *desktop, GtkActionGroup* mainActions, GObje
0, 1e6, SPIN_STEP, SPIN_PAGE_STEP,
labels, values, G_N_ELEMENTS(labels),
sp_rtb_width_value_changed, tracker);
- tracker->addAdjustment( ege_adjustment_action_get_adjustment(eact) );
g_object_set_data( holder, "width_action", eact );
gtk_action_set_sensitive( GTK_ACTION(eact), FALSE );
gtk_action_group_add_action( mainActions, GTK_ACTION(eact) );
@@ -344,7 +344,6 @@ void sp_rect_toolbox_prep(SPDesktop *desktop, GtkActionGroup* mainActions, GObje
0, 1e6, SPIN_STEP, SPIN_PAGE_STEP,
labels, values, G_N_ELEMENTS(labels),
sp_rtb_height_value_changed, tracker);
- tracker->addAdjustment( ege_adjustment_action_get_adjustment(eact) );
g_object_set_data( holder, "height_action", eact );
gtk_action_set_sensitive( GTK_ACTION(eact), FALSE );
gtk_action_group_add_action( mainActions, GTK_ACTION(eact) );
@@ -361,7 +360,6 @@ void sp_rect_toolbox_prep(SPDesktop *desktop, GtkActionGroup* mainActions, GObje
0, 1e6, SPIN_STEP, SPIN_PAGE_STEP,
labels, values, G_N_ELEMENTS(labels),
sp_rtb_rx_value_changed, tracker);
- tracker->addAdjustment( ege_adjustment_action_get_adjustment(eact) );
gtk_action_group_add_action( mainActions, GTK_ACTION(eact) );
}
@@ -376,14 +374,13 @@ void sp_rect_toolbox_prep(SPDesktop *desktop, GtkActionGroup* mainActions, GObje
0, 1e6, SPIN_STEP, SPIN_PAGE_STEP,
labels, values, G_N_ELEMENTS(labels),
sp_rtb_ry_value_changed, tracker);
- tracker->addAdjustment( ege_adjustment_action_get_adjustment(eact) );
gtk_action_group_add_action( mainActions, GTK_ACTION(eact) );
}
// add the units menu
{
- GtkAction* act = tracker->createAction( "RectUnitsAction", _("Units"), ("") );
- gtk_action_group_add_action( mainActions, act );
+ InkSelectOneAction* act = tracker->createAction( "RectUnitsAction", _("Units"), ("") );
+ gtk_action_group_add_action( mainActions, act->gobj() );
}
/* Reset */