Bug 388310 - Full screen application with another windows masks windows of other applications
Summary: Full screen application with another windows masks windows of other applications
Status: RESOLVED FIXED
Alias: None
Product: kwin
Classification: Plasma
Component: core (show other bugs)
Version: 5.11.4
Platform: Neon Linux
: NOR normal
Target Milestone: ---
Assignee: KWin default assignee
URL: https://phabricator.kde.org/D9699
Keywords:
Depends on:
Blocks:
 
Reported: 2017-12-28 21:58 UTC by Shitikanth
Modified: 2018-01-10 16:44 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In: 5.12.0
Sentry Crash Report:
mgraesslin: ReviewRequest+


Attachments
demonstration (webm) (3.77 MB, application/gzip)
2017-12-28 22:09 UTC, Shitikanth
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Shitikanth 2017-12-28 21:58:31 UTC
Steps to reproduce:

1. Open a fresh KDE session.

2. Open Okular as a standard window (not fullscreen).

3. Open Kwrite.

4. Make Kwrite window full-screen.

5. Open a new window in Kwrite (not fullscreen).

6. From the second (not fullscreen) window, try to switch to Okular.

Expected behaviour:

Okular window should come to foreground.

What happens:

Okular window stays invisible behind the open windows of Kwrite.
Comment 1 Shitikanth 2017-12-28 22:09:10 UTC
Created attachment 109564 [details]
demonstration (webm)
Comment 2 Martin Flöser 2017-12-29 16:43:15 UTC
Is this on X11 or Wayland?
Comment 3 Shitikanth 2017-12-29 20:32:43 UTC
X11
Comment 4 Martin Flöser 2017-12-30 11:41:46 UTC
Very well. We have a general issue on Wayland to activate a window if an X11 window is fullscreen. So I hope that is the same root issue.
Comment 5 Martin Flöser 2018-01-01 17:42:10 UTC
I investigated the issue and found a potential issue. In the case you created the two kwrite windows are belonging to the same group. Due to that the non fullscreen window is put into the active fullscreen layer. Normally when a fullscreen window loses activation it goes back to the normal layer. From what it looks like the problem here is that a non-fullscreen window is in the active fullscreen layer. So any check for fullscreen just bails out.
Comment 6 Martin Flöser 2018-01-06 09:49:02 UTC
Git commit 87ebfd15179d7c136d840ebdc9f8ebfc3ab83687 by Martin Flöser.
Committed on 06/01/2018 at 09:45.
Pushed by graesslin into branch 'master'.

[autotests] Add test case for fullscreen window with groups

When an X11 window is raised to fullscreen it gets set to active layer.
When another window gets activated then it goes back to normal layer.
But when a window of the same group gets activated the fullscreen window
stays in the active layer. Due to that it is not possible to raise other
windows above the fullscreen window.

This just adds a test case exposing the problematic area.

M  +74   -0    autotests/integration/x11_client_test.cpp

https://commits.kde.org/kwin/87ebfd15179d7c136d840ebdc9f8ebfc3ab83687
Comment 7 Martin Flöser 2018-01-06 10:31:35 UTC
Possible patch at https://phabricator.kde.org/D9699
Comment 8 Martin Flöser 2018-01-10 16:44:27 UTC
Git commit b7ad4bcf881cdc184375a0c5b64e2dd625e30344 by Martin Flöser.
Committed on 10/01/2018 at 16:44.
Pushed by graesslin into branch 'master'.

Keep fullscreen windows in active layer based on transients not the group

Summary:
So far a not-active fullscreen X11 window was kept in the active layer if
the newly activated window is in the same group (that is same client
leader). For example a fullscreen X11 kwrite window is in the active layer
if another kwrite window is active. The two kwrite windows obviously
don't have anything to do with each other, but are in the same group.

This creates problems as it's not possible to raise other windows above
the active not-fullscreen kwrite window. E.g. the panel is stacked below.

The idea behind the check makes sense: if a fullscreen window opens
another window (e.g. a configuration dialog) it should not be put back
to normal layer. Thus the check is adjusted whether the new active
window is a transient to the fullscreen window. Thus the intention is
still the same, but does not cause the problems.

As the code now does not need to differentiate between X11 and Wayland
windows (group only on X11) the Client specific implementation is
removed and the method unvirtual'ed.
FIXED-IN: 5.12.0

Test Plan: Test passes

Reviewers: #kwin, #plasma

Subscribers: plasma-devel, kwin

Tags: #plasma

Differential Revision: https://phabricator.kde.org/D9699

M  +1    -1    abstract_client.cpp
M  +1    -1    abstract_client.h
M  +4    -1    autotests/integration/x11_client_test.cpp
M  +0    -1    client.h
M  +0    -15   layers.cpp

https://commits.kde.org/kwin/b7ad4bcf881cdc184375a0c5b64e2dd625e30344