Bug 449907 - Adding/removing a virtual desktop requires two clicks on the relevant button
Summary: Adding/removing a virtual desktop requires two clicks on the relevant button
Status: RESOLVED FIXED
Alias: None
Product: kwin
Classification: Plasma
Component: effects-overview (show other bugs)
Version: 5.24.0
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-02-10 02:37 UTC by tgnff242
Modified: 2022-06-24 18:26 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In: 5.25.2
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description tgnff242 2022-02-10 02:37:40 UTC
SUMMARY
This affects the desktop grid effect, as well. Essentially, a double click is required to add, or remove, one virtual desktop.


STEPS TO REPRODUCE
1. Enter the overview/desktop-grid effect.
2. Click on the button to add more virtual desktops four times.

OBSERVED RESULT
Two virtual desktops have been added.

EXPECTED RESULT
Four desktops should have been added.

SOFTWARE/OS VERSIONS
KDE Plasma Version: 5.24.0
KDE Frameworks Version: 5.90.0
Qt Version: 5.15.2 + KDE patches
Comment 1 Nate Graham 2022-02-11 17:56:39 UTC
Cannot reproduce on Wayland. Are you on X11?
Comment 2 tgnff242 2022-02-11 19:06:18 UTC
Yes, I am on X11.

Even on Wayland, though, not every click is registered if you click on it fast enough . You can't do that using the Overview effect because the button changes location, but you can using the Desktop Grid effect. See also Bug 441951.
Comment 3 Nate Graham 2022-02-14 16:43:20 UTC
The button is big enough that you can position your cursor on the far right so that the next click will hit the button again even after it moves. Cannot reproduce on Wayland.
Comment 4 Nathan 2022-06-16 21:25:45 UTC
I am also experiencing this bug. The first click on any button (close window button, add desktop button, remove desktop button) after enabling overview mode works as expected. Any subsequent clicks requires two clicks for the button to work.
I hope this helps.

SOFTWARE/OS VERSIONS
Operating System: Arch Linux
KDE Plasma Version: 5.25.0
KDE Frameworks Version: 5.95.0
Qt Version: 5.15.4
Kernel Version: 5.18.3-arch1-1 (64-bit)
Graphics Platform: X11
Comment 5 Bug Janitor Service 2022-06-24 15:04:42 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/kwin/-/merge_requests/2576
Comment 6 Nate Graham 2022-06-24 17:55:01 UTC
Git commit 66a54d38d4dfe231980dfa1e4393d62f3c559df1 by Nate Graham, on behalf of Marco Martin.
Committed on 24/06/2022 at 17:54.
Pushed by ngraham into branch 'master'.

effects: Set timestamp for input events

Set the time for mouse and touch events. This is especially important
for the mouse is as the timestamp will be used to discriminate between
single and double click. Previously this was always sending the double
click event, making buttons work only every other click.
Related: bug 454275

M  +3    -0    src/backends/x11/standalone/effects_mouse_interception_x11_filter.cpp
M  +1    -2    src/libkwineffects/kwinoffscreenquickview.cpp

https://invent.kde.org/plasma/kwin/commit/66a54d38d4dfe231980dfa1e4393d62f3c559df1
Comment 7 Nate Graham 2022-06-24 17:55:29 UTC
Git commit e6ae8fb6755398d3512863c7de6493360962118e by Nate Graham, on behalf of Marco Martin.
Committed on 24/06/2022 at 17:55.
Pushed by ngraham into branch 'Plasma/5.25'.

effects: Set timestamp for input events

Set the time for mouse and touch events. This is especially important
for the mouse is as the timestamp will be used to discriminate between
single and double click. Previously this was always sending the double
click event, making buttons work only every other click.
Related: bug 454275


(cherry picked from commit 66a54d38d4dfe231980dfa1e4393d62f3c559df1)

M  +3    -0    src/backends/x11/standalone/effects_mouse_interception_x11_filter.cpp
M  +1    -2    src/libkwineffects/kwinoffscreenquickview.cpp

https://invent.kde.org/plasma/kwin/commit/e6ae8fb6755398d3512863c7de6493360962118e