Bug 312728

Summary: "Show desktop layout indicators" option isn't applied properly/immediately
Product: kwin Reporter: Elias Probst <mail>
Component: scriptingAssignee: KWin default assignee <kwin-bugs-null>
Severity: normal Flags: mgraesslin: ReviewRequest+
Priority: NOR    
Version: 4.9.95 (RC 1)   
Target Milestone: 4.10.1   
Platform: Gentoo Packages   
OS: Linux   
URL: https://git.reviewboard.kde.org/r/108945/
Latest Commit: Version Fixed In: 4.10.1

Description Elias Probst 2013-01-06 02:23:11 UTC
Using KDE 4.10 RC2 (only RC1 was available for selection) and Qt 4.8.4.

When enabling/disabling the "Show desktop layout indicators" option in "kcmshell4 desktop" → "Switching" tab, the setting isn't immediately applied:

# Enabling:
Until either kwin is restarted or the parent option "Desktop Switch On-Screen Display" is disabled, applied, enabled, applied again, only the simple text mode of the desktop switch OSD is shown.

# Disabling:
When disabling the option, the 1st time a desktop switch happens, the OSD still has the old size, but only text content. The size should adjust immediately once the option is disabled.
Comment 1 Martin Flöser 2013-02-20 12:02:08 UTC
Git commit 1e3cf9e197cabf00e921a4769742942acc36d24c by Martin Gräßlin.
Committed on 13/02/2013 at 16:04.
Pushed by graesslin into branch 'KDE/4.10'.

Fix layout issues of Desktop Change OSD

* no more binding loops - yeah for anchoring
* properly update sizes when switching screens
* properly handle case layout indicator enabled/disabled
* connect to desktop changed and reset desktop model
* set a maximum width/height of 0.8 of screen

Most interesting change is the moving of
visible = true;
to the beginning of the block which updates the layout. Without that
all the changes are ignored resulting in the incorrect size on screen

The disadvantage of that is that the OSD is shown before the layout is
adjusted. But it's considerable minor given that it should be just one
Related: bug 312727, bug 305737
FIXED-IN: 4.10.1
REVIEW: 108945

M  +17   -17   kwin/scripts/desktopchangeosd/contents/ui/main.qml