mirror of
https://git.savannah.gnu.org/git/emacs.git
synced 2024-12-15 09:47:20 +00:00
Make jump scroll work with Gtk+
* xterm.c (xg_scroll_callback): Remove position, for jump set portion to min(value, whole).
This commit is contained in:
parent
082c97e81f
commit
a3d0b7d19d
@ -1,3 +1,8 @@
|
||||
2014-06-01 Jan Djärv <jan.h.d@swipnet.se>
|
||||
|
||||
* xterm.c (xg_scroll_callback): Remove position, for jump set portion
|
||||
to min(value, whole).
|
||||
|
||||
2014-06-01 Paul Eggert <eggert@cs.ucla.edu>
|
||||
|
||||
Bring back the changes to GDB-visible symbols, but only on AIX.
|
||||
|
@ -4441,14 +4441,11 @@ xg_scroll_callback (GtkRange *range,
|
||||
gpointer user_data)
|
||||
{
|
||||
struct scroll_bar *bar = user_data;
|
||||
gdouble position;
|
||||
int part = -1, whole = 0, portion = 0;
|
||||
GtkAdjustment *adj = GTK_ADJUSTMENT (gtk_range_get_adjustment (range));
|
||||
struct frame *f = g_object_get_data (G_OBJECT (range), XG_FRAME_DATA);
|
||||
|
||||
if (xg_ignore_gtk_scrollbar) return FALSE;
|
||||
position = gtk_adjustment_get_value (adj);
|
||||
|
||||
|
||||
switch (scroll)
|
||||
{
|
||||
@ -4460,7 +4457,7 @@ xg_scroll_callback (GtkRange *range,
|
||||
part = scroll_bar_handle;
|
||||
whole = gtk_adjustment_get_upper (adj) -
|
||||
gtk_adjustment_get_page_size (adj);
|
||||
portion = min ((int)position, whole);
|
||||
portion = min ((int)value, whole);
|
||||
bar->dragging = portion;
|
||||
}
|
||||
break;
|
||||
|
Loading…
Reference in New Issue
Block a user