tags 570256 patch
forwarded 570256 https://bugzilla.gnome.org/show_bug.cgi?id=598820
severity 570256 normal
thanks

Touchpad's TapButton2 and TapButton3 are inverted in GNOME in Debian
Squeeze.  It used to be that TapButton2=2 and TapButton3=3.  It also used
to be possible to configure them through xorg.conf.  Now they are inverted
because gnome-settings-daemon has them hardwired to 1/3/2, without any
configuration tool available.

This bug has also been reported to GNOME and Ubuntu, in the following
locations:

https://bugzilla.gnome.org/show_bug.cgi?id=598820
https://bugs.launchpad.net/ubuntu/+source/gnome-settings-daemon/+bug/563276

I took the patch prepared by Yuri Khan (which seems to be likely the one
that will be applied upstream) and modified it to make it apply the
current packages in squeeze.

I'm attaching the debdiff patch of the packages I created, in case it's
useful for anybody.  This bug is nasty (because it removes functionality
that was available before, without a clear override method) but not release
critical and thus will regretfully not make it into squeeze.  

I've built the gnome-settings-daemon package for squeeze and put it at: 
http://www.marga.com.ar/debian/packages/squeeze/

I've tested the package with a Synaptics touchpad, and it works fine.

I think a similar patch should be applied in Debian packages, until
upstream decides to apply it themselves.

-- 
Love,
Marga

diff -Nru gnome-settings-daemon-2.30.2/debian/changelog gnome-settings-daemon-2.30.2/debian/changelog
--- gnome-settings-daemon-2.30.2/debian/changelog	2010-10-19 23:29:28.000000000 +0000
+++ gnome-settings-daemon-2.30.2/debian/changelog	2011-01-02 20:03:28.000000000 +0000
@@ -1,3 +1,10 @@
+gnome-settings-daemon (2.30.2-2.1) unstable; urgency=low
+
+  * Non-maintainer upload.
+  * Adding patches to support TapButton re-ordering, by Yuri Khan. 
+
+ -- Margarita Manterola <ma...@debian.org>  Sun, 02 Jan 2011 20:03:10 +0000
+
 gnome-settings-daemon (2.30.2-2) unstable; urgency=low
 
   * 13_monitor_kfreebsd.patch: new patch. Don’t monitor fdescfs.
diff -Nru gnome-settings-daemon-2.30.2/debian/patches/06_add_tap-to-click_button_settings.patch gnome-settings-daemon-2.30.2/debian/patches/06_add_tap-to-click_button_settings.patch
--- gnome-settings-daemon-2.30.2/debian/patches/06_add_tap-to-click_button_settings.patch	1970-01-01 00:00:00.000000000 +0000
+++ gnome-settings-daemon-2.30.2/debian/patches/06_add_tap-to-click_button_settings.patch	2011-01-02 20:17:39.000000000 +0000
@@ -0,0 +1,279 @@
+Index: gnome-settings-daemon-2.30.0/data/desktop_gnome_peripherals_touchpad.schemas.in
+===================================================================
+--- gnome-settings-daemon-2.30.0.orig/data/desktop_gnome_peripherals_touchpad.schemas.in	2010-03-10 17:58:29.000000000 +0600
++++ gnome-settings-daemon-2.30.0/data/desktop_gnome_peripherals_touchpad.schemas.in	2010-03-31 12:31:25.000000000 +0700
+@@ -27,6 +27,42 @@
+     </schema>
+ 
+     <schema>
++      <key>/schemas/desktop/gnome/peripherals/touchpad/tap_button_1</key>
++      <applyto>/desktop/gnome/peripherals/touchpad/tap_button_1</applyto>
++      <owner>gnome</owner>
++      <type>int</type>
++      <default>1</default>
++      <locale name="C">
++        <short>Button assigned to one-finger tap</short>
++        <long>Set this to the button number that you want to click by tapping one finger.</long>
++      </locale>
++    </schema>
++
++    <schema>
++      <key>/schemas/desktop/gnome/peripherals/touchpad/tap_button_2</key>
++      <applyto>/desktop/gnome/peripherals/touchpad/tap_button_2</applyto>
++      <owner>gnome</owner>
++      <type>int</type>
++      <default>3</default>
++      <locale name="C">
++        <short>Button assigned to two-finger tap</short>
++        <long>Set this to the button number that you want to click by tapping two fingers.</long>
++      </locale>
++    </schema>
++
++    <schema>
++      <key>/schemas/desktop/gnome/peripherals/touchpad/tap_button_3</key>
++      <applyto>/desktop/gnome/peripherals/touchpad/tap_button_3</applyto>
++      <owner>gnome</owner>
++      <type>int</type>
++      <default>2</default>
++      <locale name="C">
++        <short>Button assigned to three-finger tap</short>
++        <long>Set this to the button number that you want to click by tapping three fingers.</long>
++      </locale>
++    </schema>
++
++    <schema>
+       <key>/schemas/desktop/gnome/peripherals/touchpad/scroll_method</key>
+       <applyto>/desktop/gnome/peripherals/touchpad/scroll_method</applyto>
+       <owner>gnome</owner>
+Index: gnome-settings-daemon-2.30.0/plugins/mouse/gsd-mouse-manager.c
+===================================================================
+--- gnome-settings-daemon-2.30.0.orig/plugins/mouse/gsd-mouse-manager.c	2010-03-31 12:27:47.000000000 +0700
++++ gnome-settings-daemon-2.30.0/plugins/mouse/gsd-mouse-manager.c	2010-03-31 12:36:52.000000000 +0700
+@@ -65,6 +65,9 @@
+ #define KEY_TOUCHPAD_DISABLE_W_TYPING    GCONF_TOUCHPAD_DIR "/disable_while_typing"
+ #ifdef HAVE_X11_EXTENSIONS_XINPUT_H
+ #define KEY_TAP_TO_CLICK        GCONF_TOUCHPAD_DIR "/tap_to_click"
++#define KEY_TAP_BUTTON_1        GCONF_TOUCHPAD_DIR "/tap_button_1"
++#define KEY_TAP_BUTTON_2        GCONF_TOUCHPAD_DIR "/tap_button_2"
++#define KEY_TAP_BUTTON_3        GCONF_TOUCHPAD_DIR "/tap_button_3"
+ #define KEY_SCROLL_METHOD       GCONF_TOUCHPAD_DIR "/scroll_method"
+ #define KEY_PAD_HORIZ_SCROLL    GCONF_TOUCHPAD_DIR "/horiz_scroll_enabled"
+ #define KEY_TOUCHPAD_ENABLED    GCONF_TOUCHPAD_DIR "/touchpad_enabled"
+@@ -88,8 +91,10 @@
+ static void     gsd_mouse_manager_finalize    (GObject             *object);
+ static void     set_mouse_settings            (GsdMouseManager      *manager);
+ #ifdef HAVE_X11_EXTENSIONS_XINPUT_H
+-static int      set_tap_to_click              (gboolean state, gboolean left_handed);
++static int      set_tap_to_click              (gboolean state, guint tap_button_1, guint tap_button_2, guint tap_button_3);
++static int      update_tap_to_click           (void);
+ static XDevice* device_is_touchpad            (XDeviceInfo deviceinfo);
++static gint     get_device_button_mapping     (XDevice *device, guchar **buttons, gsize *buttons_capacity);
+ #endif
+ 
+ G_DEFINE_TYPE (GsdMouseManager, gsd_mouse_manager, G_TYPE_OBJECT)
+@@ -295,6 +300,25 @@
+         return is_single_button;
+ }
+ 
++static gint
++get_device_button_mapping (XDevice *device, guchar **buttons, gsize *buttons_capacity)
++{
++        gint n_buttons = XGetDeviceButtonMapping (GDK_DISPLAY (), device,
++                                                  *buttons,
++                                                  *buttons_capacity);
++
++        while (n_buttons > *buttons_capacity) {
++                *buttons_capacity = n_buttons;
++                *buttons = (guchar *) g_realloc (*buttons,
++                                                 *buttons_capacity * sizeof (guchar));
++
++                n_buttons = XGetDeviceButtonMapping (GDK_DISPLAY (), device,
++                                                     *buttons,
++                                                     *buttons_capacity);
++        }
++
++        return n_buttons;
++}
+ 
+ static void
+ set_xinput_devices_left_handed (gboolean left_handed)
+@@ -326,11 +350,8 @@
+                 device = device_is_touchpad (device_info[i]);
+                 if (device != NULL) {
+                         GConfClient *client = gconf_client_get_default ();
+-                        gboolean tap = gconf_client_get_bool (client, KEY_TAP_TO_CLICK, NULL);
+                         gboolean single_button = touchpad_has_single_button (device);
+ 
+-                        if (tap && !single_button)
+-                                set_tap_to_click (tap, left_handed);
+                         XCloseDevice (GDK_DISPLAY (), device);
+                         g_object_unref (client);
+ 
+@@ -346,19 +367,7 @@
+                     (device == NULL))
+                         continue;
+ 
+-                n_buttons = XGetDeviceButtonMapping (GDK_DISPLAY (), device,
+-                                                     buttons,
+-                                                     buttons_capacity);
+-
+-                while (n_buttons > buttons_capacity) {
+-                        buttons_capacity = n_buttons;
+-                        buttons = (guchar *) g_realloc (buttons,
+-                                                        buttons_capacity * sizeof (guchar));
+-
+-                        n_buttons = XGetDeviceButtonMapping (GDK_DISPLAY (), device,
+-                                                             buttons,
+-                                                             buttons_capacity);
+-                }
++                n_buttons = get_device_button_mapping (device, &buttons, &buttons_capacity);
+ 
+                 configure_button_layout (buttons, n_buttons, left_handed);
+ 
+@@ -369,6 +378,8 @@
+ 
+         if (device_info != NULL)
+                 XFreeDeviceList (device_info);
++
++        update_tap_to_click ();
+ }
+ 
+ static GdkFilterReturn
+@@ -588,14 +599,20 @@
+ 
+ #ifdef HAVE_X11_EXTENSIONS_XINPUT_H
+ static int
+-set_tap_to_click (gboolean state, gboolean left_handed)
++set_tap_to_click (gboolean state, guint tap_button_1, guint tap_button_2, guint tap_button_3)
+ {
+-        int numdevices, i, format, rc;
++        int numdevices, i, j, format, rc;
+         unsigned long nitems, bytes_after;
+         XDeviceInfo *devicelist = XListInputDevices (GDK_DISPLAY (), &numdevices);
+         XDevice * device;
+         unsigned char* data;
+         Atom prop, type;
++        guchar *buttons;
++        gsize buttons_capacity = 16;
++        gint n_buttons;
++        gint tap_physical_1 = tap_button_1,
++             tap_physical_2 = tap_button_2,
++             tap_physical_3 = tap_button_3;
+ 
+         if (devicelist == NULL)
+                 return 0;
+@@ -605,9 +622,26 @@
+         if (!prop)
+                 return 0;
+ 
++        buttons = g_new (guchar, buttons_capacity);
++
+         for (i = 0; i < numdevices; i++) {
+                 if ((device = device_is_touchpad (devicelist[i]))) {
+                         gdk_error_trap_push ();
++
++                        n_buttons = get_device_button_mapping (device, &buttons, &buttons_capacity);
++
++                        /* Synaptics maps taps to physical buttons. X then
++                         * maps physical buttons to logical buttons. Since we
++                         * want to let the user specify logical buttons
++                         * directly for taps, we need to reverse the X mapping.
++                         */
++                        for (j = 0; j < n_buttons; j++)
++                        {
++                                if (buttons[j] == tap_button_1) tap_physical_1 = j + 1;
++                                if (buttons[j] == tap_button_2) tap_physical_2 = j + 1;
++                                if (buttons[j] == tap_button_3) tap_physical_3 = j + 1;
++                        }
++
+                         rc = XGetDeviceProperty (GDK_DISPLAY (), device, prop, 0, 2,
+                                                 False, XA_INTEGER, &type, &format, &nitems,
+                                                 &bytes_after, &data);
+@@ -617,10 +651,10 @@
+
+                         if (rc == Success && type == XA_INTEGER && format == 8 && nitems >= 7)
+                         {
+-                                /* Set RLM mapping for 1/2/3 fingers*/
+-                                data[4] = (state) ? ((left_handed) ? 3 : 1) : 0;
+-                                data[5] = (state) ? ((left_handed) ? 1 : 3) : 0;
+-                                data[6] = (state) ? 2 : 0;
++
++                                data[4] = (state) ? tap_physical_1 : 0;
++                                data[5] = (state) ? tap_physical_2 : 0;
++                                data[6] = (state) ? tap_physical_3 : 0;
+                                 XChangeDeviceProperty (GDK_DISPLAY (), device, prop, XA_INTEGER, 8,
+                                                         PropModeReplace, data, nitems);
+                         }
+@@ -635,11 +669,28 @@
+                 }
+         }
+ 
++        g_free (buttons);
++
+         XFreeDeviceList (devicelist);
+         return 0;
+ }
+ 
+ static int
++update_tap_to_click ()
++{
++        GConfClient *client = gconf_client_get_default ();
++
++        int result = set_tap_to_click (gconf_client_get_bool (client, KEY_TAP_TO_CLICK, NULL),
++                                       gconf_client_get_int  (client, KEY_TAP_BUTTON_1, NULL),
++                                       gconf_client_get_int  (client, KEY_TAP_BUTTON_2, NULL),
++                                       gconf_client_get_int  (client, KEY_TAP_BUTTON_3, NULL));
++
++        g_object_unref (client);
++
++        return result;
++}
++
++static int
+ set_horiz_scroll (gboolean state)
+ {
+         int numdevices, i, rc;
+@@ -902,15 +953,13 @@
+ set_mouse_settings (GsdMouseManager *manager)
+ {
+         GConfClient *client = gconf_client_get_default ();
+-        gboolean left_handed = gconf_client_get_bool (client, KEY_LEFT_HANDED, NULL);
+ 
+-        set_left_handed (manager, left_handed);
++        set_left_handed (manager, gconf_client_get_bool (client, KEY_LEFT_HANDED, NULL));
+         set_motion_acceleration (manager, gconf_client_get_float (client, KEY_MOTION_ACCELERATION , NULL));
+         set_motion_threshold (manager, gconf_client_get_int (client, KEY_MOTION_THRESHOLD, NULL));
+ 
+         set_disable_w_typing (manager, gconf_client_get_bool (client, KEY_TOUCHPAD_DISABLE_W_TYPING, NULL));
+ #ifdef HAVE_X11_EXTENSIONS_XINPUT_H
+-        set_tap_to_click (gconf_client_get_bool (client, KEY_TAP_TO_CLICK, NULL), left_handed);
+         set_edge_scroll (gconf_client_get_int (client, KEY_SCROLL_METHOD, NULL));
+         set_horiz_scroll (gconf_client_get_bool (client, KEY_PAD_HORIZ_SCROLL, NULL));
+         set_touchpad_enabled (gconf_client_get_bool (client, KEY_TOUCHPAD_ENABLED, NULL));
+@@ -941,11 +990,11 @@
+                 if (entry->value->type == GCONF_VALUE_BOOL)
+                         set_disable_w_typing (manager, gconf_value_get_bool (entry->value));
+ #ifdef HAVE_X11_EXTENSIONS_XINPUT_H
+-        } else if (! strcmp (entry->key, KEY_TAP_TO_CLICK)) {
+-                if (entry->value->type == GCONF_VALUE_BOOL) {
+-                        set_tap_to_click (gconf_value_get_bool (entry->value),
+-                                          gconf_client_get_bool (client, KEY_LEFT_HANDED, NULL));
+-                }
++        } else if ((! strcmp (entry->key, KEY_TAP_TO_CLICK) && entry->value->type == GCONF_VALUE_BOOL)
++               ||  (! strcmp (entry->key, KEY_TAP_BUTTON_1) && entry->value->type == GCONF_VALUE_INT)
++               ||  (! strcmp (entry->key, KEY_TAP_BUTTON_2) && entry->value->type == GCONF_VALUE_INT)
++               ||  (! strcmp (entry->key, KEY_TAP_BUTTON_3) && entry->value->type == GCONF_VALUE_INT)) {
++                        update_tap_to_click ();
+         } else if (! strcmp (entry->key, KEY_SCROLL_METHOD)) {
+                 if (entry->value->type == GCONF_VALUE_INT) {
+                         set_edge_scroll (gconf_value_get_int (entry->value));
+@@ -1033,8 +1082,7 @@
+ 
+         set_disable_w_typing (manager, gconf_client_get_bool (client, KEY_TOUCHPAD_DISABLE_W_TYPING, NULL));
+ #ifdef HAVE_X11_EXTENSIONS_XINPUT_H
+-        set_tap_to_click (gconf_client_get_bool (client, KEY_TAP_TO_CLICK, NULL),
+-                          gconf_client_get_bool (client, KEY_LEFT_HANDED, NULL));
++        update_tap_to_click ();
+         set_edge_scroll (gconf_client_get_int (client, KEY_SCROLL_METHOD, NULL));
+         set_horiz_scroll (gconf_client_get_bool (client, KEY_PAD_HORIZ_SCROLL, NULL));
+         set_touchpad_enabled (gconf_client_get_bool (client, KEY_TOUCHPAD_ENABLED, NULL));
diff -Nru gnome-settings-daemon-2.30.2/debian/patches/07_add_corner_tapping_button_settings.patch gnome-settings-daemon-2.30.2/debian/patches/07_add_corner_tapping_button_settings.patch
--- gnome-settings-daemon-2.30.2/debian/patches/07_add_corner_tapping_button_settings.patch	1970-01-01 00:00:00.000000000 +0000
+++ gnome-settings-daemon-2.30.2/debian/patches/07_add_corner_tapping_button_settings.patch	2011-01-02 20:21:47.000000000 +0000
@@ -0,0 +1,156 @@
+Index: gnome-settings-daemon-2.30.0/data/desktop_gnome_peripherals_touchpad.schemas.in
+===================================================================
+--- gnome-settings-daemon-2.30.0.orig/data/desktop_gnome_peripherals_touchpad.schemas.in	2010-03-31 12:31:25.000000000 +0700
++++ gnome-settings-daemon-2.30.0/data/desktop_gnome_peripherals_touchpad.schemas.in	2010-03-31 12:37:18.000000000 +0700
+@@ -27,6 +27,54 @@
+     </schema>
+ 
+     <schema>
++      <key>/schemas/desktop/gnome/peripherals/touchpad/tap_button_rt</key>
++      <applyto>/desktop/gnome/peripherals/touchpad/tap_button_rt</applyto>
++      <owner>gnome</owner>
++      <type>int</type>
++      <default>2</default>
++      <locale name="C">
++        <short>Button assigned to right top corner</short>
++        <long>Set this to the button number that you want to click by tapping on the right top corner.</long>
++      </locale>
++    </schema>
++
++    <schema>
++      <key>/schemas/desktop/gnome/peripherals/touchpad/tap_button_rb</key>
++      <applyto>/desktop/gnome/peripherals/touchpad/tap_button_rb</applyto>
++      <owner>gnome</owner>
++      <type>int</type>
++      <default>3</default>
++      <locale name="C">
++        <short>Button assigned to right bottom corner</short>
++        <long>Set this to the button number that you want to click by tapping on the right bottom corner.</long>
++      </locale>
++    </schema>
++
++    <schema>
++      <key>/schemas/desktop/gnome/peripherals/touchpad/tap_button_lt</key>
++      <applyto>/desktop/gnome/peripherals/touchpad/tap_button_lt</applyto>
++      <owner>gnome</owner>
++      <type>int</type>
++      <default>0</default>
++      <locale name="C">
++        <short>Button assigned to right top corner</short>
++        <long>Set this to the button number that you want to click by tapping on the left top corner.</long>
++      </locale>
++    </schema>
++
++    <schema>
++      <key>/schemas/desktop/gnome/peripherals/touchpad/tap_button_lb</key>
++      <applyto>/desktop/gnome/peripherals/touchpad/tap_button_lb</applyto>
++      <owner>gnome</owner>
++      <type>int</type>
++      <default>0</default>
++      <locale name="C">
++        <short>Button assigned to left bottom corner</short>
++        <long>Set this to the button number that you want to click by tapping on the left bottom corner.</long>
++      </locale>
++    </schema>
++
++    <schema>
+       <key>/schemas/desktop/gnome/peripherals/touchpad/tap_to_click</key>
+       <applyto>/desktop/gnome/peripherals/touchpad/tap_to_click</applyto>
+       <owner>gnome</owner>
+Index: gnome-settings-daemon-2.30.0/plugins/mouse/gsd-mouse-manager.c
+===================================================================
+--- gnome-settings-daemon-2.30.0.orig/plugins/mouse/gsd-mouse-manager.c	2010-03-31 12:36:52.000000000 +0700
++++ gnome-settings-daemon-2.30.0/plugins/mouse/gsd-mouse-manager.c	2010-03-31 12:37:56.000000000 +0700
+@@ -65,6 +65,10 @@
+ #define KEY_TOUCHPAD_DISABLE_W_TYPING    GCONF_TOUCHPAD_DIR "/disable_while_typing"
+ #ifdef HAVE_X11_EXTENSIONS_XINPUT_H
+ #define KEY_TAP_TO_CLICK        GCONF_TOUCHPAD_DIR "/tap_to_click"
++#define KEY_TAP_BUTTON_RT       GCONF_TOUCHPAD_DIR "/tap_button_rt"
++#define KEY_TAP_BUTTON_RB       GCONF_TOUCHPAD_DIR "/tap_button_rb"
++#define KEY_TAP_BUTTON_LT       GCONF_TOUCHPAD_DIR "/tap_button_lt"
++#define KEY_TAP_BUTTON_LB       GCONF_TOUCHPAD_DIR "/tap_button_lb"
+ #define KEY_TAP_BUTTON_1        GCONF_TOUCHPAD_DIR "/tap_button_1"
+ #define KEY_TAP_BUTTON_2        GCONF_TOUCHPAD_DIR "/tap_button_2"
+ #define KEY_TAP_BUTTON_3        GCONF_TOUCHPAD_DIR "/tap_button_3"
+@@ -91,7 +95,10 @@
+ static void     gsd_mouse_manager_finalize    (GObject             *object);
+ static void     set_mouse_settings            (GsdMouseManager      *manager);
+ #ifdef HAVE_X11_EXTENSIONS_XINPUT_H
+-static int      set_tap_to_click              (gboolean state, guint tap_button_1, guint tap_button_2, guint tap_button_3);
++static int      set_tap_to_click              (gboolean state,
++                                               guint tap_button_rt, guint tap_button_rb,
++                                               guint tap_button_lt, guint tap_button_lb,
++                                               guint tap_button_1, guint tap_button_2, guint tap_button_3);
+ static int      update_tap_to_click           (void);
+ static XDevice* device_is_touchpad            (XDeviceInfo deviceinfo);
+ static gint     get_device_button_mapping     (XDevice *device, guchar **buttons, gsize *buttons_capacity);
+@@ -599,7 +606,10 @@
+ 
+ #ifdef HAVE_X11_EXTENSIONS_XINPUT_H
+ static int
+-set_tap_to_click (gboolean state, guint tap_button_1, guint tap_button_2, guint tap_button_3)
++set_tap_to_click (gboolean state,
++                  guint tap_button_rt, guint tap_button_rb,
++                  guint tap_button_lt, guint tap_button_lb,
++                  guint tap_button_1, guint tap_button_2, guint tap_button_3)
+ {
+         int numdevices, i, j, format, rc;
+         unsigned long nitems, bytes_after;
+@@ -610,7 +620,11 @@
+         guchar *buttons;
+         gsize buttons_capacity = 16;
+         gint n_buttons;
+-        gint tap_physical_1 = tap_button_1,
++        gint tap_physical_rt = tap_button_rt,
++             tap_physical_rb = tap_button_rb,
++             tap_physical_lt = tap_button_lt,
++             tap_physical_lb = tap_button_lb,
++             tap_physical_1 = tap_button_1,
+              tap_physical_2 = tap_button_2,
+              tap_physical_3 = tap_button_3;
+ 
+@@ -637,6 +651,10 @@
+                          */
+                         for (j = 0; j < n_buttons; j++)
+                         {
++                                if (buttons[j] == tap_button_rt) tap_physical_rt = j + 1;
++                                if (buttons[j] == tap_button_rb) tap_physical_rb = j + 1;
++                                if (buttons[j] == tap_button_lt) tap_physical_lt = j + 1;
++                                if (buttons[j] == tap_button_lb) tap_physical_lb = j + 1;
+                                 if (buttons[j] == tap_button_1) tap_physical_1 = j + 1;
+                                 if (buttons[j] == tap_button_2) tap_physical_2 = j + 1;
+                                 if (buttons[j] == tap_button_3) tap_physical_3 = j + 1;
+@@ -648,7 +666,10 @@
+ 
+                         if (rc == Success && type == XA_INTEGER && format == 8 && nitems >= 7)
+                         {
+-
++                                data[0] = (state) ? tap_physical_rt : 0;
++                                data[1] = (state) ? tap_physical_rb : 0;
++                                data[2] = (state) ? tap_physical_lt : 0;
++                                data[3] = (state) ? tap_physical_lb : 0;
+                                 data[4] = (state) ? tap_physical_1 : 0;
+                                 data[5] = (state) ? tap_physical_2 : 0;
+                                 data[6] = (state) ? tap_physical_3 : 0;
+@@ -681,6 +699,10 @@
+         GConfClient *client = gconf_client_get_default ();
+ 
+         int result = set_tap_to_click (gconf_client_get_bool (client, KEY_TAP_TO_CLICK, NULL),
++                                       gconf_client_get_int  (client, KEY_TAP_BUTTON_RT, NULL),
++                                       gconf_client_get_int  (client, KEY_TAP_BUTTON_RB, NULL),
++                                       gconf_client_get_int  (client, KEY_TAP_BUTTON_LT, NULL),
++                                       gconf_client_get_int  (client, KEY_TAP_BUTTON_LB, NULL),
+                                        gconf_client_get_int  (client, KEY_TAP_BUTTON_1, NULL),
+                                        gconf_client_get_int  (client, KEY_TAP_BUTTON_2, NULL),
+                                        gconf_client_get_int  (client, KEY_TAP_BUTTON_3, NULL));
+@@ -991,6 +1013,10 @@
+                         set_disable_w_typing (manager, gconf_value_get_bool (entry->value));
+ #ifdef HAVE_X11_EXTENSIONS_XINPUT_H
+         } else if ((! strcmp (entry->key, KEY_TAP_TO_CLICK) && entry->value->type == GCONF_VALUE_BOOL)
++               ||  (! strcmp (entry->key, KEY_TAP_BUTTON_RT) && entry->value->type == GCONF_VALUE_INT)
++               ||  (! strcmp (entry->key, KEY_TAP_BUTTON_RB) && entry->value->type == GCONF_VALUE_INT)
++               ||  (! strcmp (entry->key, KEY_TAP_BUTTON_LT) && entry->value->type == GCONF_VALUE_INT)
++               ||  (! strcmp (entry->key, KEY_TAP_BUTTON_LB) && entry->value->type == GCONF_VALUE_INT)
+                ||  (! strcmp (entry->key, KEY_TAP_BUTTON_1) && entry->value->type == GCONF_VALUE_INT)
+                ||  (! strcmp (entry->key, KEY_TAP_BUTTON_2) && entry->value->type == GCONF_VALUE_INT)
+                ||  (! strcmp (entry->key, KEY_TAP_BUTTON_3) && entry->value->type == GCONF_VALUE_INT)) {
diff -Nru gnome-settings-daemon-2.30.2/debian/patches/series gnome-settings-daemon-2.30.2/debian/patches/series
--- gnome-settings-daemon-2.30.2/debian/patches/series	2010-10-19 23:24:46.000000000 +0000
+++ gnome-settings-daemon-2.30.2/debian/patches/series	2011-01-02 20:18:09.000000000 +0000
@@ -1,6 +1,8 @@
 01_xrdb.patch
 02_missing_libs.patch
 03_maintainer_mode.patch
+06_add_tap-to-click_button_settings.patch
+07_add_corner_tapping_button_settings.patch
 10_clipboard_crash.patch
 12_monitor_network_fs.patch
 13_monitor_kfreebsd.patch

Reply via email to