Fix netsurf touchscreen behaviour.
PATCH 1/1 Fix netsurf touchscreen behaviour.
As per http://vlists.pepperfish.net/pipermail/netsurf-dev-netsurf-browser.org/2009-September/001588.html
---recipes/netsurf/netsurf-2.1/touchscreen.patch | 21 +++++++++++++++++++++
recipes/netsurf/netsurf_2.1.bb | 3 ++-
2 files changed, 23 insertions(+), 1 deletions(-)
create mode 100644 recipes/netsurf/netsurf-2.1/touchscreen.patch
recipes/netsurf/netsurf-2.1/touchscreen.patch new file +20 -0
@@ -0,0 +1,21 @@ +--- netsurf.orig/gtk/gtk_window.c ++++ netsurf/gtk/gtk_window.c +@@ -220,6 +220,7 @@ + GDK_BUTTON_PRESS_MASK | + GDK_BUTTON_RELEASE_MASK | + GDK_POINTER_MOTION_MASK | ++ GDK_POINTER_MOTION_HINT_MASK | + GDK_KEY_PRESS_MASK | + GDK_KEY_RELEASE_MASK); + GTK_WIDGET_SET_FLAGS(GTK_WIDGET(g->drawing_area), GTK_CAN_FOCUS); +@@ -344,6 +345,10 @@ + bool shift = event->state & GDK_SHIFT_MASK; + bool ctrl = event->state & GDK_CONTROL_MASK; + ++ if ((abs(event->x - g->last_x) < 5) && (abs(event->y - g->last_y) < 5)) ++ /* necessary for touch screens */ ++ return FALSE; ++ + if (g->mouse->state & BROWSER_MOUSE_PRESS_1){ + /* Start button 1 drag */ + browser_window_mouse_click(g->bw, BROWSER_MOUSE_DRAG_1,
recipes/netsurf/netsurf_2.1.bb +0 -0
@@ -7,11 +7,12 @@ LICENSE = "GPLv2"
SRC_URI = "http://www.netsurf-browser.org/downloads/releases/netsurf-${PV}-src.tar.gz \ file://fix_makefile.patch;patch=1 \ file://debugxml_fix.patch;patch=1 \ + file://touchscreen.patch;patch=1 \ file://netsurf.png \ file://netsurf.desktop \ file://Makefile.config"
-PR = "r1"
+PR = "r2"
# Workaround for 2.1 tarball (unpacks into netsurf/, not netsurf-2.1/ ) S = "${WORKDIR}/netsurf"
Signature · 1 line
1.6.0.3
Quoted 1 line · Graham Gower
As per http://vlists.pepperfish.net/pipermail/netsurf-dev-netsurf-browser.org/2009-September/001588.html
Is this damaging for non-touchscreen users? It wasn't completely obvious to me from the patch what effect it would have in that case.
p.
2009/9/9 Phil Blundell <[email protected]>:
Quoted 5 lines · Graham Gower
Quoted 1 line
As per http://vlists.pepperfish.net/pipermail/netsurf-dev-netsurf-browser.org/2009-September/001588.html
Is this damaging for non-touchscreen users? It wasn't completely obvious to me from the patch what effect it would have in that case.
As far as I can tell, it appears to function with a usb mouse attached.
-Graham