diff options
author | raveit65 <[email protected]> | 2016-06-27 13:09:46 +0200 |
---|---|---|
committer | raveit65 <[email protected]> | 2016-07-06 17:47:42 +0200 |
commit | f02d495258535739320e340f809f1e8392aca7af (patch) | |
tree | 882d20b99b4ed47f645bb7e053758dda2927b229 /eel | |
parent | 1f7ab5dcbca155f331735a8483d768ea0c349c18 (diff) | |
download | caja-f02d495258535739320e340f809f1e8392aca7af.tar.bz2 caja-f02d495258535739320e340f809f1e8392aca7af.tar.xz |
eel-gtk-extensions: remove eel_gtk_adjustment* functions
taken from:
https://git.gnome.org/browse/nautilus/commit/?id=2b99456
Diffstat (limited to 'eel')
-rw-r--r-- | eel/eel-gtk-extensions.c | 32 | ||||
-rw-r--r-- | eel/eel-gtk-extensions.h | 4 |
2 files changed, 0 insertions, 36 deletions
diff --git a/eel/eel-gtk-extensions.c b/eel/eel-gtk-extensions.c index 1c762728..e451bdbf 100644 --- a/eel/eel-gtk-extensions.c +++ b/eel/eel-gtk-extensions.c @@ -353,38 +353,6 @@ eel_gtk_menu_tool_button_get_button (GtkMenuToolButton *tool_button) return button; } -/* The standard gtk_adjustment_set_value ignores page size, which - * disagrees with the logic used by scroll bars, for example. - */ -void -eel_gtk_adjustment_set_value (GtkAdjustment *adjustment, - float value) -{ - float upper_page_start, clamped_value; - - g_return_if_fail (GTK_IS_ADJUSTMENT (adjustment)); - - upper_page_start = MAX (gtk_adjustment_get_upper (adjustment) - - gtk_adjustment_get_page_size (adjustment), - gtk_adjustment_get_lower (adjustment)); - clamped_value = CLAMP (value, gtk_adjustment_get_lower (adjustment), upper_page_start); - if (clamped_value != gtk_adjustment_get_value (adjustment)) - { - gtk_adjustment_set_value (adjustment, clamped_value); - gtk_adjustment_value_changed (adjustment); - } -} - -/* Clamp a value if the minimum or maximum has changed. */ -void -eel_gtk_adjustment_clamp_value (GtkAdjustment *adjustment) -{ - g_return_if_fail (GTK_IS_ADJUSTMENT (adjustment)); - - eel_gtk_adjustment_set_value (adjustment, - gtk_adjustment_get_value (adjustment)); -} - /** * eel_gtk_label_make_bold. * diff --git a/eel/eel-gtk-extensions.h b/eel/eel-gtk-extensions.h index a5d8e60a..ba4beb1d 100644 --- a/eel/eel-gtk-extensions.h +++ b/eel/eel-gtk-extensions.h @@ -65,10 +65,6 @@ GtkWidget * eel_gtk_menu_tool_button_get_button (GtkMenuTo /* GtkLabel */ void eel_gtk_label_make_bold (GtkLabel *label); -/* GtkAdjustment */ -void eel_gtk_adjustment_set_value (GtkAdjustment *adjustment, - float value); -void eel_gtk_adjustment_clamp_value (GtkAdjustment *adjustment); /* GtkTreeView */ void eel_gtk_tree_view_set_activate_on_single_click (GtkTreeView *tree_view, |