After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 741523 - Touchpad hotkey use leads to wrong config value when used with no other pointing device connected
Touchpad hotkey use leads to wrong config value when used with no other point...
Status: RESOLVED OBSOLETE
Product: gnome-settings-daemon
Classification: Core
Component: media-keys
3.15.x
Other Linux
: Normal normal
: ---
Assigned To: gnome-settings-daemon-maint
gnome-settings-daemon-maint
Depends on:
Blocks:
 
 
Reported: 2014-12-14 19:04 UTC by Mantas Mikulėnas (grawity)
Modified: 2015-08-31 16:15 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Mantas Mikulėnas (grawity) 2014-12-14 19:04:07 UTC
On my laptop, Fn+F9 is the toggle-touchpad key. Recently it has started working natively with g-s-d. However, the "toggle" seems a bit buggy.

When the touchpad is enabled, the first press of Fn+F9 will disable it and set "touchpad-enabled" in dconf to "false"... but immediately set it back to "true" while leaving the actual touchpad disabled.

The second press, then, sets "touchpad-enabled" to "false" again (and it remains that way), leaving the touchpad still disabled. The third press enables the touchpad and updates the setting normally.

I see this in `dconf watch /`:

[first press]

/org/gnome/settings-daemon/peripherals/touchpad/touchpad-enabled
  false

/org/gnome/settings-daemon/peripherals/touchpad/touchpad-enabled
  true

[second press]

/org/gnome/settings-daemon/peripherals/touchpad/touchpad-enabled
  false

[third press]

/org/gnome/settings-daemon/peripherals/touchpad/touchpad-enabled
  true

[end]

In fact, this is not limited to the key press. Whenever "touchpad-enabled" is set to false (keyboard, gsettings set, dconf write) it immediately gets reset to "true".

gnome-settings-daemon 3.14.2
Comment 1 Bastien Nocera 2015-02-04 17:52:53 UTC
What hardware is this?

Please try using "evtest" on the command-line to see if you don't get duplicated touchpad toggle events.

My guess is that the hardware is sending duplicated events.
Comment 2 Mantas Mikulėnas (grawity) 2015-02-04 18:20:54 UTC
It's an ASUS laptop, a K52JT.206, with an 'ETPS/2 Elantech Touchpad'.

AFAIK it doesn't do any magic – I tested with `xev` in a bare X session (just openbox), and Fn+F9 doesn't directly enable/disable the touchpad at all, it just sends a XF86TouchpadToggle press+release (used to be XF86Tools a few kernels ago) and relies on userspace to actually toggle the touchpad.

I even have XF86TouchpadToggle bound to a custom synclient toggle script via xbindkeys (still in the bare non-gnome session) and it also works fine there.

Similarly, evtest on a tty shows a single EV_KEY/KEY_F21 for each press. The log is below.

Either way, as I mentioned, this is triggered not only by the Fn+F9 but even by a direct write to gsettings...

<log>
Input driver version is 1.0.1
Input device ID: bus 0x19 vendor 0x0 product 0x0 version 0x0
Input device name: "Asus Laptop extra buttons" ¹
Supported events:
  Event type 0 (EV_SYN)
  Event type 1 (EV_KEY)
    Event code 113 (KEY_MUTE)
    Event code 114 (KEY_VOLUMEDOWN)
    Event code 115 (KEY_VOLUMEUP)
    Event code 140 (KEY_CALC)
    Event code 142 (KEY_SLEEP)
    Event code 148 (KEY_PROG1)
    Event code 149 (KEY_PROG2)
    Event code 150 (KEY_WWW)
    Event code 152 (KEY_SCREENLOCK)
    Event code 163 (KEY_NEXTSONG)
    Event code 164 (KEY_PLAYPAUSE)
    Event code 165 (KEY_PREVIOUSSONG)
    Event code 166 (KEY_STOPCD)
    Event code 169 (KEY_PHONE)
    Event code 183 (KEY_F13)
    Event code 191 (KEY_F21)
    Event code 212 (KEY_CAMERA)
    Event code 215 (KEY_EMAIL)
    Event code 224 (KEY_BRIGHTNESSDOWN)
    Event code 225 (KEY_BRIGHTNESSUP)
    Event code 226 (KEY_MEDIA)
    Event code 227 (KEY_SWITCHVIDEOMODE)
    Event code 229 (KEY_KBDILLUMDOWN)
    Event code 230 (KEY_KBDILLUMUP)
    Event code 236 (KEY_BATTERY)
    Event code 237 (KEY_BLUETOOTH)
    Event code 238 (KEY_WLAN)
    Event code 240 (KEY_UNKNOWN)
    Event code 245 (KEY_DISPLAY_OFF)
    Event code 247 (KEY_RFKILL)
    Event code 372 (KEY_ZOOM)
    Event code 431 (KEY_DISPLAYTOGGLE)
    Event code 531 (KEY_TOUCHPAD_ON)
  Event type 4 (EV_MSC)
    Event code 4 (MSC_SCAN)
Properties:
Testing ... (interrupt to exit)
<press – nothing shows up on press>
<release – both 'value 1' and 'value 0' show up on release>
Event: time 1423073698.505950, type 4 (EV_MSC), code 4 (MSC_SCAN), value 6b
Event: time 1423073698.505950, type 1 (EV_KEY), code 191 (KEY_F21), value 1
Event: time 1423073698.505950, -------------- EV_SYN ------------
Event: time 1423073698.505963, type 1 (EV_KEY), code 191 (KEY_F21), value 0
Event: time 1423073698.505963, -------------- EV_SYN ------------
<press>
<release>
Event: time 1423073701.876423, type 4 (EV_MSC), code 4 (MSC_SCAN), value 6b
Event: time 1423073701.876423, type 1 (EV_KEY), code 191 (KEY_F21), value 1
Event: time 1423073701.876423, -------------- EV_SYN ------------
Event: time 1423073701.876435, type 1 (EV_KEY), code 191 (KEY_F21), value 0
Event: time 1423073701.876435, -------------- EV_SYN ------------
<press>
<release>
Event: time 1423073706.178714, type 4 (EV_MSC), code 4 (MSC_SCAN), value 6b
Event: time 1423073706.178714, type 1 (EV_KEY), code 191 (KEY_F21), value 1
Event: time 1423073706.178714, -------------- EV_SYN ------------
Event: time 1423073706.178727, type 1 (EV_KEY), code 191 (KEY_F21), value 0
Event: time 1423073706.178727, -------------- EV_SYN ------------
<press>
<release>
Event: time 1423073711.018785, type 4 (EV_MSC), code 4 (MSC_SCAN), value 6b
Event: time 1423073711.018785, type 1 (EV_KEY), code 191 (KEY_F21), value 1
Event: time 1423073711.018785, -------------- EV_SYN ------------
Event: time 1423073711.018797, type 1 (EV_KEY), code 191 (KEY_F21), value 0
Event: time 1423073711.018797, -------------- EV_SYN ------------
</log>

[¹] If I run evtest on the device corresponding to the actual touchpad, Fn+F9 results in nothing at all. So I guess that really means it's just a regular keypress.
Comment 3 Franz Hsieh 2015-06-11 02:31:36 UTC
Hi there,

I have some problem on ASUS PU451JF, the touchpad is also 'ETPS/2 Elantech Touchpad'.

Currently, the issue can be reproduced on 3.17.1 (latest sources from git).
The issue is resulted from the 'ensure_touchpad_active()' in the gsd-mouse-manager.c. AFAIK, this function was added to fix the issue: https://bugzilla.gnome.org/show_bug.cgi?id=685941.

However if this function works correctly, the touchpad should not be disabled. But the truth is it changes the gsetting key value but devices is not set to disabled. That is why g-s-d makes mistake, and user has to toggle twice to re-enable the touchped.

The issue is not happened if there is an external mouse is plugged.

By the way, I don't know why g-s-d disallows to disable the touchpad if it is the only one pointer devices on the platform. For user's view, I should be able to disable touchpad if it is hotkey on my platform.
Comment 4 Mantas Mikulėnas (grawity) 2015-08-12 07:03:03 UTC
Hmm, cannot reproduce this anymore with 3.16.3 and xf86-input-libinput.
Comment 5 Bastien Nocera 2015-08-31 16:15:03 UTC
(In reply to Mantas Mikulėnas from comment #4)
> Hmm, cannot reproduce this anymore with 3.16.3 and xf86-input-libinput.

Ok, let's consider this fixed then.