]> git.eshelyaron.com Git - emacs.git/commitdiff
* gtkutil.c (xg_set_toolkit_horizontal_scroll_bar_thumb):
authorDmitry Antipov <dmantipov@yandex.ru>
Wed, 1 Oct 2014 13:21:08 +0000 (17:21 +0400)
committerDmitry Antipov <dmantipov@yandex.ru>
Wed, 1 Oct 2014 13:21:08 +0000 (17:21 +0400)
Resurrect old code and fix compilation with GTK < 2.13.6.

src/ChangeLog
src/gtkutil.c

index afaca432250c7531fc2801690b69b7ebcf6fb665..667ac3ce45f93205cdf89d5c03bdb046880ab268 100644 (file)
@@ -1,3 +1,8 @@
+2014-10-01  Dmitry Antipov  <dmantipov@yandex.ru>
+
+       * gtkutil.c (xg_set_toolkit_horizontal_scroll_bar_thumb):
+       Resurrect old code and fix compilation with GTK < 2.13.6.
+
 2014-10-01  Paul Eggert  <eggert@cs.ucla.edu>
 
        Use AUTO_CONS instead of SCOPED_CONS, etc.
index 1f3e1958ede810aaf1898695e8939afcde2db875..595e6e0bb6ac00acd130f4cd20a08f19dcde3aaa 100644 (file)
@@ -3993,17 +3993,18 @@ xg_set_toolkit_horizontal_scroll_bar_thumb (struct scroll_bar *bar,
 
       block_input ();
       adj = gtk_range_get_adjustment (GTK_RANGE (wscroll));
-
-      /*      gtk_adjustment_set_lower (adj, (gdouble) lower);
+#if GTK_CHECK_VERSION (2, 3, 16)
+      gtk_adjustment_configure (adj, (gdouble) value, (gdouble) lower,
+                               (gdouble) upper, (gdouble) step_increment,
+                               (gdouble) page_increment, (gdouble) pagesize);
+#else
+      gtk_adjustment_set_lower (adj, (gdouble) lower);
       gtk_adjustment_set_upper (adj, (gdouble) upper);
       gtk_adjustment_set_page_size (adj, (gdouble) pagesize);
       gtk_adjustment_set_value (adj, (gdouble) value);
       gtk_adjustment_set_page_increment (adj, (gdouble) page_increment);
-      gtk_adjustment_set_step_increment (adj, (gdouble)
-      step_increment); */
-      gtk_adjustment_configure (adj, (gdouble) value, (gdouble) lower,
-                               (gdouble) upper, (gdouble) step_increment,
-                               (gdouble) page_increment, (gdouble) pagesize);
+      gtk_adjustment_set_step_increment (adj, (gdouble) step_increment);
+#endif
       gtk_adjustment_changed (adj);
       unblock_input ();
     }