[Bug 187907] Restore resolution after application crash

Thomas Lübking thomas.luebking at web.de
Sat Oct 31 21:22:05 GMT 2009


https://bugs.kde.org/show_bug.cgi?id=187907





--- Comment #6 from Thomas Lübking <thomas luebking web de>  2009-10-31 22:22:04 ---
a) Martin is right. You request KWin to determine external intentions.
b) Trying to be smart on this will most likely introduce unwanted side effects
(i.e. reverting wanted resolutions) because of a)
c) work around buggy apps like this

-- snip ---
#!/bin/bash

# store resolution id
mode=$(($(xrandr -q | grep -n '*' | cut -d':' -f1) - 3))

# store composite state
composite=$(qdbus org.kde.kwin /KWin compositingActive)

#turn off composite
$composite && qdbus org.kde.kwin /KWin toggleCompositing

#run game etc., must not go to bg
wine broken_app

#restore resolution /before/ starting composition
xrandr -s $mode

# restart composite in case, but don't stop it
$composite && ! $(qdbus org.kde.kwin /KWin compositingActive) &&  qdbus
org.kde.kwin /KWin toggleCompositing

-- end snip --

-- 
Configure bugmail: https://bugs.kde.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


More information about the Unassigned-bugs mailing list