Bug 466839 - In split screen with Firefox I can't close the non-focused app
Summary: In split screen with Firefox I can't close the non-focused app
Status: RESOLVED DOWNSTREAM
Alias: None
Product: kwin
Classification: Plasma
Component: general (show other bugs)
Version: 5.27.2
Platform: Debian unstable Linux
: NOR normal
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-03-04 17:03 UTC by Enrico
Modified: 2023-03-08 21:46 UTC (History)
2 users (show)

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


Attachments
clicking the X doesn't work (66.34 KB, image/png)
2023-03-04 17:03 UTC, Enrico
Details
video of the bug (2.96 MB, video/mp4)
2023-03-07 17:45 UTC, Enrico
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Enrico 2023-03-04 17:03:44 UTC
Created attachment 156993 [details]
clicking the X doesn't work

Hello,
I noticed this little bug with Firefox and the tiled screen. I don't mean the new tiling feature, but the normal "split screen" you can get by pushing the windows on the screen edges. Feel free to change the title with the correct term if needed.

When Firefox and another app (e.g. Dolphin or Konsole) are opened and Firefox has the focus, you can't close the other app by pressing X because it doesn't get the focus. You need to click on the other app to make it have the focus and then press the X.
This seems to be related to Firefox because everything works fine if you do the same with 2 native apps like Dolphin and Konsole.


STEPS TO REPRODUCE
1. Open Firefox
2. Open Dolphin
3. Push Firefox on the right edge of the screen
4. Push Dolphin on the left edge of the screen
5. You should now have the screen splitted 50% Firefox 50% Dolphin
6. Click on Firefox to get the focus on that app
7. Try to close Dolphin by pressing directly the "X"

OBSERVED RESULT
You cannot close Dolphin as it never gets the focus. You can click hundred of times, but the window doesn't get the focus.
If you click on another point of the Dolphin window, it gets the focus and then you can press the X

EXPECTED RESULT
Dolphin should get the focus and close

Operating System: Debian GNU/Linux 12 (Sid)
KDE Plasma Version: 5.27.2
KDE Frameworks Version: 5.103.0
Qt Version: 5.15.8
Kernel Version: 6.1.0-5-amd64 (64-bit)
Graphics Platform: Wayland
Comment 1 Nate Graham 2023-03-06 23:16:13 UTC
If you click in another part of the Dolphin window, does it get focus?

Can you close the unfocused app from the "Close" menu item in its Task Manager context menu?

Does this issue happen with all combinations of apps, or just Dolphin?
Comment 2 Enrico 2023-03-07 05:05:07 UTC
Everything works fine except for the X button. Also the Minimize/Maximize buttons can be pressed and they work.
The problem is only with the X button. I'll post a quick video if needed

This happens also with other apps, like Konsole
Comment 3 Nate Graham 2023-03-07 17:00:01 UTC
If you manage to first focus the other app and bring it to the front, does clicking on the close button start working?
Comment 4 Enrico 2023-03-07 17:45:53 UTC
Created attachment 157089 [details]
video of the bug

Yes, everything works fine if I first focus the other application.
The problem occurs only when I have both the windows in split-screen, with Firefox with focus and I try to press the X button.

Please find attached a short video where you can see the problem
Comment 5 Nate Graham 2023-03-08 15:41:35 UTC
That's quite odd. It looks like the minimize button is also not highlighting on hover; does it work when you click it despite lack of a highlight?

Other question: does the same issue happen if you turn on Firefox's titlebar and take it out of CSD mode? I'm beginning to suspect that the issue is caused by Firefox in CSD mode having giant invisible window resize areas that are blocking click events to other content underneath them.
Comment 6 Enrico 2023-03-08 17:46:03 UTC
(In reply to Nate Graham from comment #5)
> That's quite odd. It looks like the minimize button is also not highlighting
> on hover; does it work when you click it despite lack of a highlight?

It sometimes work. It's not always highlighted but sometimes it is.

> Other question: does the same issue happen if you turn on Firefox's titlebar
> and take it out of CSD mode? I'm beginning to suspect that the issue is
> caused by Firefox in CSD mode having giant invisible window resize areas
> that are blocking click events to other content underneath them.

Nice catch! Enabling the Title Bar in Firefox everything works fine. So it seems to be some kind of Firefox bug instead of Plasma bug
Comment 7 Nate Graham 2023-03-08 21:46:35 UTC
Sounds like this is an issue in either Firefox or GTK with respect to how large their window resize areas are.