SUMMARY Dragging items such as files, folders, etc. over windows will immediately focus those windows on Wayland. This is extremely annoying with large or fullscreen windows. Dragging items from one place to another is impossible if the destination is not next to the source and is also not next to its entry in the task manager bar. On X11, dragging over windows doesn't focus them, so this problem is avoided. This looks like the right category for this issue. My apologies if it isn't. STEPS TO REPRODUCE 1. Open a window (for example, Firefox) in fullscreen. 2. Open two Dolphin windows, and move them to the top left and top right corners of the screen, leaving a gap between them. 3. Attempt to drag a file or folder from one Dolphin window to the other. OBSERVED RESULT The moment the cursor is over the Firefox window, Firefox becomes focused, hiding the destination Dolphin window. EXPECTED RESULT The Firefox window should not become focused in this case, or should at least not become focused immediately. SOFTWARE/OS VERSIONS Linux/KDE Plasma: Fedora 34 (available in About System) KDE Plasma Version: 5.22.4 KDE Frameworks Version: 5.83.0 Qt Version: 5.15.2 ADDITIONAL INFORMATION Kernel Version: 5.13.6-200.fc34.x86_64 Graphics Processor: Mesa Intel UHD Graphics 630
For me it's not *immediate* but it does happen after just like half a second. Is that what you're seeing, or is it truly immediate for you?
It's truly immediate for me. I don't think the screen is rendered once before the focus switch happens. My monitor is running at 144hz, but I also tested at 60hz and experienced the same behavior.
Interesting, thanks for the data.
A possibly relevant merge request was started @ https://invent.kde.org/plasma/kwin/-/merge_requests/1334
Git commit 42b516b56777bb7b87fa97534a2e9d0b84cbdc18 by Xaver Hugl. Committed on 30/08/2021 at 14:31. Pushed by zamundaaa into branch 'master'. fix drag and drop raise with Xwayland windows They shouldn't be raised immediately. The same strategy as with Wayland native clients should be used. M +15 -9 src/input.cpp M +0 -1 src/xwl/drag_wl.cpp M +0 -6 src/xwl/drag_x.cpp https://invent.kde.org/plasma/kwin/commit/42b516b56777bb7b87fa97534a2e9d0b84cbdc18
Git commit 37c9d43b93b299fc20b57fb1717805aaa65a572e by Xaver Hugl. Committed on 30/08/2021 at 16:49. Pushed by zamundaaa into branch 'Plasma/5.22'. fix drag and drop raise with Xwayland windows They shouldn't be raised immediately. The same strategy as with Wayland native clients should be used. (cherry picked from commit 42b516b56777bb7b87fa97534a2e9d0b84cbdc18) M +15 -9 src/input.cpp M +0 -1 src/xwl/drag_wl.cpp M +0 -6 src/xwl/drag_x.cpp https://invent.kde.org/plasma/kwin/commit/37c9d43b93b299fc20b57fb1717805aaa65a572e
Created attachment 165263 [details] Demo of the window raising issue during drag-n-drop on Wayland > STEPS TO REPRODUCE > 1. Open a window (for example, Firefox) in fullscreen. > 2. Open two Dolphin windows, and move them to the top left and top right > corners of the screen, leaving a gap between them. > 3. Attempt to drag a file or folder from one Dolphin window to the other. I still have it on a Wayland session. With the steps above, it's easily reproducible on different KDE Plasma versions (6.0 RC1, 5.27 and even 5.24). Please see my video that shows difference in drag-and-drop behavior on X11 and Wayland sessions. It's available in attachment and also on https://youtu.be/jMoGk-C8L_Q
I can kind of reproduce the issue, as it's a little bit different from the original bug report now. I can see that windows immediately become *focused* when something is dragged over them, but they don't also become *raised* until the drag ends or the drag stops moving. When I stop moving, the raising is very fast though; ti feels like there needs to be a much higher delay. Can you submit a new bug report for this, since it's technically a new issue? Once you do, you can add its bug number to the "See also" field of this bug report. Thanks!