Bug 478032 - Focus doesn't follow mouse over window title bars under Wayland.
Summary: Focus doesn't follow mouse over window title bars under Wayland.
Status: CONFIRMED
Alias: None
Product: kwin
Classification: Plasma
Component: wayland-generic (show other bugs)
Version: 5.90.0
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords: wayland-only
Depends on:
Blocks:
 
Reported: 2023-12-04 07:32 UTC by 0x8BADF00DD00D
Modified: 2024-11-26 15:33 UTC (History)
4 users (show)

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


Attachments
Correct followed by incorrect behavior. (1.93 MB, video/mp4)
2023-12-04 07:32 UTC, 0x8BADF00DD00D
Details

Note You need to log in before you can comment on or make changes to this bug.
Description 0x8BADF00DD00D 2023-12-04 07:32:57 UTC
Created attachment 163844 [details]
Correct followed by incorrect behavior.

SUMMARY
There is a Wayland specific issue present in Arch Linux's regular repo as well as the kde-unstable beta repo. Normally in xorg when the window activation policy is set to have the focus follow the mouse, it would follow even over a window's title bar including its borders, where the mouse changes to its resizing icon. When switching to Wayland the focus doesn't follow over the border or the title bar. This bugs middle click actions set to active windows as middle clicking doesn't acquire focus.

STEPS TO REPRODUCE
1.  Change to Wayland session.
2.  In Window Behavior, Set window activation policy to any "focus follows mouse" option
3. Open two windows on your desktop, give focus to one, then carefully hover your mouse over the titlebar of the other without touching any other part of the window. (As show in the attached video.)

OBSERVED RESULT
The second window wont gain focus until you touch something other than the titlebar and its border.

EXPECTED RESULT
The second window should become focused when the mouse touches the borderline of the titlebar.

SOFTWARE/OS VERSIONS
Operating System: Arch Linux 
KDE Plasma Version: 5.90.0
KDE Frameworks Version: 5.246.0
Qt Version: 6.6.1
Kernel Version: 6.6.3-arch1-1 (64-bit)
Graphics Platform: Wayland
Processors: 12 × AMD Ryzen 5 5600G with Radeon Graphics
Memory: 11.5 GiB of RAM
Graphics Processor: AMD Radeon Graphics
Manufacturer: Gigabyte Technology Co., Ltd.
Product Name: B450M DS3H V2

ADDITIONAL INFORMATION
In the attached video I show working behavior followed by bugged. I've seen it for awhile in Debian's and Arch's regular repo aswell as Arch's kde-unstable alpha and beta. This is my first report and I'm happy to get more info if needed.
Comment 1 Nate Graham 2023-12-05 17:39:33 UTC
Can confirm.
Comment 2 Vaclav Fiala 2024-05-22 23:07:00 UTC
still present in 6.0.4.1
Comment 3 pablo 2024-11-26 15:33:13 UTC
The bug is still present in:

* Plasma version 6.2.3
* KDE Frameworks 6.8.0
* Qt Version 6.8.0

I am not certain whether the original version should track the latest version that the incident is found or whether it should track where the incident was originally found.