summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRoss Burton <ross@openedhand.com>2007-07-27 14:39:15 +0000
committerRoss Burton <ross@openedhand.com>2007-07-27 14:39:15 +0000
commit75cac966f467d8bd8c7ecddfd6ced39f0349eaac (patch)
tree402505f4c81fa0b1bcc1ffbb33466dcee338cc36
parent6d714add9dae0cb453768e4e75732992074a2824 (diff)
downloadpoky-75cac966f467d8bd8c7ecddfd6ced39f0349eaac.tar.gz
Potentially better scrollbar patch
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@2241 311d38ba-8fff-0310-9ca6-ca027cbcb966
-rw-r--r--meta/packages/gtk+/gtk+-2.10.12/range-no-redraw.patch50
-rw-r--r--meta/packages/gtk+/gtk+_2.6.10.bb2
2 files changed, 38 insertions, 14 deletions
diff --git a/meta/packages/gtk+/gtk+-2.10.12/range-no-redraw.patch b/meta/packages/gtk+/gtk+-2.10.12/range-no-redraw.patch
index 384d71b4fe..e3603d7700 100644
--- a/meta/packages/gtk+/gtk+-2.10.12/range-no-redraw.patch
+++ b/meta/packages/gtk+/gtk+-2.10.12/range-no-redraw.patch
@@ -2,16 +2,40 @@ Index: gtk/gtkrange.c
2=================================================================== 2===================================================================
3--- gtk/gtkrange.c (revision 18523) 3--- gtk/gtkrange.c (revision 18523)
4+++ gtk/gtkrange.c (working copy) 4+++ gtk/gtkrange.c (working copy)
5@@ -1979,8 +1979,12 @@ 5@@ -99,6 +99,8 @@
6 gtk_widget_queue_draw (GTK_WIDGET (range)); 6
7 7 GtkSensitivityType lower_sensitivity;
8 /* This is so we don't lag the widget being scrolled. */ 8 GtkSensitivityType upper_sensitivity;
9+#if 0 9+
10+ /* Disable this, the scroll bar lags a bit but the end result is that 10+ guint motion_idle;
11+ scrolling treeviews is *a lot* smoother. See GNOME #460534. */ 11 };
12 if (GTK_WIDGET_REALIZED (range)) 12
13 gdk_window_process_updates (GTK_WIDGET (range)->window, FALSE); 13
14+#endif 14@@ -1721,6 +1723,16 @@
15 } 15 &handled);
16 16 }
17 /* Note that we don't round off to range->round_digits here. 17
18+static gboolean
19+update_slider_position_idle (GtkRange *range)
20+{
21+ update_slider_position (range, range->layout->mouse_x,range->layout->mouse_y);
22+
23+ range->layout->motion_idle = 0;
24+
25+ return FALSE;
26+}
27+
28 static void
29 stop_scrolling (GtkRange *range)
30 {
31@@ -1860,8 +1872,8 @@
32 if (gtk_range_update_mouse_location (range))
33 gtk_widget_queue_draw (widget);
34
35- if (range->layout->grab_location == MOUSE_SLIDER)
36- update_slider_position (range, x, y);
37+ if (range->layout->grab_location == MOUSE_SLIDER && !range->layout->motion_idle)
38+ range->layout->motion_idle = g_idle_add ((GSourceFunc)update_slider_position_idle, range);
39
40 /* We handled the event if the mouse was in the range_rect */
41 return range->layout->mouse_location != MOUSE_OUTSIDE;
diff --git a/meta/packages/gtk+/gtk+_2.6.10.bb b/meta/packages/gtk+/gtk+_2.6.10.bb
index d7199ef1dd..de22bbae75 100644
--- a/meta/packages/gtk+/gtk+_2.6.10.bb
+++ b/meta/packages/gtk+/gtk+_2.6.10.bb
@@ -1,6 +1,6 @@
1require gtk+.inc 1require gtk+.inc
2 2
3PR = "r12" 3PR = "r13"
4 4
5SRC_URI = "ftp://ftp.gtk.org/pub/gtk/v2.6/gtk+-${PV}.tar.bz2 \ 5SRC_URI = "ftp://ftp.gtk.org/pub/gtk/v2.6/gtk+-${PV}.tar.bz2 \
6 file://no-demos.patch;patch=1 \ 6 file://no-demos.patch;patch=1 \