Bug 268660 - Shaded windows are not considered in ::checkWorkspacePosition
Summary: Shaded windows are not considered in ::checkWorkspacePosition
Status: RESOLVED FIXED
Alias: None
Product: kwin
Classification: Plasma
Component: core (show other bugs)
Version: unspecified
Platform: Ubuntu Linux
: NOR normal
Target Milestone: 4.11
Assignee: KWin default assignee
URL: https://git.reviewboard.kde.org/r/109...
Keywords:
Depends on:
Blocks:
 
Reported: 2011-03-16 16:11 UTC by Massimiliano della Rovere
Modified: 2013-03-28 19:31 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In: 4.11
thomas.luebking: ReviewRequest+


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Massimiliano della Rovere 2011-03-16 16:11:59 UTC
Version:           unspecified (using KDE 4.5.1) 
OS:                Linux

I use 2 different monitors: the LVDS of the notebook and an external one.

Minimized windows are not moved to an existing display after they home display is disabled in KRandRTray.

This bug does not affect open windows. They are moved correctly to another existing and connected monitor.

Reproducible: Always

Steps to Reproduce:
1) I open KrandRTray
2) I activate the external monitor extending the desktop (not in clone mode)
3) I open a window and place it in the "external" display
4) I minimize the window
5) Using KrandRTray I disable the external monitor
6) I click on the minimized window and it is restored in the (now absent) external monitor.


Actual Results:  
the minimized window is restored in the (now absent) external monitor.

Expected Results:  
the minimized window should be restored in an active display.

I suppose that in the code of KRandRTray the function called when a monitor is disabled should cycle over all windows, including the minimized ones, and move them in the same way non-minimized ones are.
Comment 1 Christoph Feck 2011-03-16 21:57:30 UTC
> should cycle over all windows, including the minimized ones

If I understand it correctly, we do not really use minimized windows, but the underlying X11 window is actually removed when it is minimized. I have no idea how/if that can be fixed, so I am asking KWin and Plasma maintainers.
Comment 2 Martin Flöser 2011-03-16 22:03:51 UTC
Yes that is correct - there is no such thing as a minimized window. We could probably do some weird hack in KWin (that's why I reassign to kwin), but it's probably one of those "fixed with Wayland" issues.
Comment 3 Thomas Lübking 2011-03-16 22:26:29 UTC
Am 16.03.2011, 22:03 Uhr, schrieb Martin Gräßlin  <mgraesslin@kde.org>:
> Yes that is correct - there is no such thing as a minimized window.

Doch* - naja, nein - kommt drauf an ;-)
Das Fenster ist (auch als X drawable außerhalb der WM Logik) immer noch da  
und kann auch gefunden und angesteuert werden.
Wer verschiebt denn das Fenster beim Screenverlust, KWIn oder krandrtray  
(oder irgend ein anderer daemon)?
(Ich sollte vllt. mal einen 2. Monitor anschließen...)

Als Problem stelle ich mir vor das KWin von ge-unmappten Fenstern keine  
events liest/configure requests entgegen nimmt weswegen wir beim  
unminimieren vermutlich die Geometrievorstellungen o.Ä. explizit auslesen  
und aktualisieren müßten.

*Beweis:
1) xterm &
2) xwininfo -int | grep -i "Window id"
3) xterm clicken
4) xterm minimieren (macht natürlich nur Sinn wenn wirklich minimiert wird  
und nicht nur im compositor)
5) xwininfo -children -tree -root -int | grep <xterm WId>
5) xwininfo -id <xterm WId> -> "Map State: IsUnMapped"
tada =)


Gruß,
Thomas
Comment 4 Thomas Lübking 2011-03-16 22:27:34 UTC
f***- if you're not martin, just ignore the above post. sorry :-)
Comment 5 Thomas Lübking 2013-03-22 22:36:27 UTC
Bug description is wrong - minimized is no problem, but shaded is.
It's also marked "todo"
Comment 6 Thomas Lübking 2013-03-28 19:31:34 UTC
Git commit 6d4efc728dc182632c53ab3e3abf7cfde8feddb4 by Thomas Lübking.
Committed on 23/03/2013 at 00:42.
Pushed by luebking into branch 'master'.

consider shaded windows in checkWorkspaceGeometry

they act pretty much the same as unshaded windows, so i don't know
what prevented their inclusion
FIXED-IN: 4.11
REVIEW: 109679

M  +130  -132  kwin/geometry.cpp

http://commits.kde.org/kde-workspace/6d4efc728dc182632c53ab3e3abf7cfde8feddb4