summaryrefslogtreecommitdiffstats
path: root/src/widgets/toolbox.cpp
diff options
context:
space:
mode:
authorAlexander Valavanis <valavanisalex@gmail.com>2019-05-28 10:02:19 +0000
committerAlexander Valavanis <valavanisalex@gmail.com>2019-05-28 10:02:19 +0000
commit895e079e5d6b2a3ec52d91f3929eab96eabdf407 (patch)
treec2cc78f8c90b85234239c9bc9a5f18a8f857be43 /src/widgets/toolbox.cpp
parentHackfest2019: TextToolbar: Start GtkAction migration (diff)
downloadinkscape-895e079e5d6b2a3ec52d91f3929eab96eabdf407.tar.gz
inkscape-895e079e5d6b2a3ec52d91f3929eab96eabdf407.zip
Hackfest2019: Drop unused EgeAdjustmentAction
Diffstat (limited to 'src/widgets/toolbox.cpp')
-rw-r--r--src/widgets/toolbox.cpp50
1 files changed, 0 insertions, 50 deletions
diff --git a/src/widgets/toolbox.cpp b/src/widgets/toolbox.cpp
index 605ae8956..ae76a245b 100644
--- a/src/widgets/toolbox.cpp
+++ b/src/widgets/toolbox.cpp
@@ -60,7 +60,6 @@
#include "ui/widget/style-swatch.h"
#include "ui/widget/unit-tracker.h"
-#include "widgets/ege-adjustment-action.h"
#include "widgets/spinbutton-events.h"
#include "widgets/spw-utilities.h"
#include "widgets/widget-sizes.h"
@@ -464,55 +463,6 @@ static GtkWidget* createCustomSlider( GtkAdjustment *adjustment, gdouble climbRa
return widget;
}
-EgeAdjustmentAction * create_adjustment_action( gchar const *name,
- gchar const *label, gchar const *shortLabel, gchar const *tooltip,
- Glib::ustring const &path, gdouble def,
- gboolean altx, gchar const *altx_mark,
- gdouble lower, gdouble upper, gdouble step, gdouble page,
- gchar const** descrLabels, gdouble const* descrValues, guint descrCount,
- Inkscape::UI::Widget::UnitTracker *unit_tracker,
- gdouble climb/* = 0.1*/, guint digits/* = 3*/, double factor/* = 1.0*/ )
-{
- static bool init = false;
- if ( !init ) {
- init = true;
- ege_adjustment_action_set_compact_tool_factory( createCustomSlider );
- }
-
- Inkscape::Preferences *prefs = Inkscape::Preferences::get();
- GtkAdjustment* adj = GTK_ADJUSTMENT( gtk_adjustment_new( prefs->getDouble(path, def) * factor,
- lower, upper, step, page, 0 ) );
-
- EgeAdjustmentAction* act = ege_adjustment_action_new( adj, name, label, tooltip, nullptr, climb, digits, unit_tracker );
- if ( shortLabel ) {
- g_object_set( act, "short_label", shortLabel, NULL );
- }
-
- if ( (descrCount > 0) && descrLabels && descrValues ) {
- ege_adjustment_action_set_descriptions( act, descrLabels, descrValues, descrCount );
- }
-
- // The EgeAdjustmentAction class uses this to create a data member
- // with the specified name, that simply points to the object itself.
- // It appears to only be used by the DesktopWidget to find the named
- // object
- //
- // TODO: Get rid of this and look up widgets by name instead.
- if ( altx && altx_mark ) {
- g_object_set( G_OBJECT(act), "self-id", altx_mark, NULL );
- }
-
- if (unit_tracker) {
- unit_tracker->addAdjustment(adj);
- }
-
- // Using a cast just to make sure we pass in the right kind of function pointer
- g_object_set( G_OBJECT(act), "tool-post", static_cast<EgeWidgetFixup>(sp_set_font_size_smaller), NULL );
-
- return act;
-}
-
-
void ToolboxFactory::setToolboxDesktop(GtkWidget *toolbox, SPDesktop *desktop)
{
sigc::connection *conn = static_cast<sigc::connection*>(g_object_get_data(G_OBJECT(toolbox),