Bug 257642

Summary: KRandrTray blanks internal laptop monitor if external monitor not connected
Product: [Unmaintained] krandr Reporter: Ricardo Graça <ricardo>
Component: krandrtrayAssignee: Gustavo Pichorim Boiko <gustavo.boiko>
Status: RESOLVED FIXED    
Severity: normal CC: benni, myriam
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Arch Linux   
OS: Linux   
Latest Commit: Version Fixed In: 4.7.0
Sentry Crash Report:

Description Ricardo Graça 2010-11-22 20:54:39 UTC
Version:           unspecified (using KDE 4.5.3) 
OS:                Linux

If, in a session, I connect an external monitor to my laptop and disable the internal monitor, on the next session if I don't have the external monitor connected during the boot process, when KRandrTray starts up it blanks (disables?) the internal monitor. I don't know exactly how it does it, but not even my laptop's function key to cycle through screens works after this (I think this key invokes xrandr). The only way to get a display back is to connect an external monitor (which strangely is also blank after connecting) and then use the laptop's function key again and eventually one of the displays comes up.

Reproducible: Always

Steps to Reproduce:
1. Connect external monitor to the computer
2. Open KRandr to change the display settings and disable the internal monitor
3. Make sure KRandrTray is set to autostart during boot
4. Reboot
5. Disconnect the external monitor as soon as possible

Actual Results:  
KRandrTray blanks the internal monitor when it starts

Expected Results:  
Somehow known that the external monitor is not connected and so it shouldn't try to restore the previous session's settings (if that is indeed what is going on)

I'm using the acpi-eeepc-generic scripts
Comment 1 Ricardo Graça 2011-01-23 14:33:20 UTC
This still happens in version 4.5.5.
Comment 2 Benni Hill 2011-02-12 01:44:49 UTC
Could you or someone else please test my patch in Bug #265955?

(In reply to comment #0)
> I don't know exactly how it does it, but not
> even my laptop's function key to cycle through screens works after this (I
> think this key invokes xrandr).
kded_randrmonitor was ignoring the function key when only one monitor was connected.
Comment 3 Ricardo Graça 2011-02-18 23:52:06 UTC
@alter
Your patch works and fixes this bug. This can be marked as solved as far as I'm concerned.
Comment 4 Lamarque V. Souza 2011-07-11 15:54:47 UTC
Git commit 505c9e0cdc5a6daddd300bd756278b8a9c0fa5cf by Lamarque V. Souza.
Committed on 11/07/2011 at 17:52.
Pushed by lvsouza into branch 'master'.

Fix can't switch back to laptop display when external display gets
disconnected.

REVIEW: 6513
BUG: 257642
BUG: 265955
FIXED-IN: 4.7.0

M  +75   -14   kcontrol/randr/module/randrmonitor.cpp     
M  +10   -0    kcontrol/randr/module/randrmonitor.h     

http://commits.kde.org/kde-workspace/505c9e0cdc5a6daddd300bd756278b8a9c0fa5cf
Comment 5 Lamarque V. Souza 2011-07-11 15:59:23 UTC
Git commit aba27511815aacec5c9769cd7a3a1fc1fa2cf80e by Lamarque V. Souza.
Committed on 11/07/2011 at 17:52.
Pushed by lvsouza into branch 'KDE/4.7'.

Fix can't switch back to laptop display when external display gets
disconnected.

REVIEW: 6513
BUG: 257642
BUG: 265955
FIXED-IN: 4.7.0
(cherry picked from commit 505c9e0cdc5a6daddd300bd756278b8a9c0fa5cf)

M  +75   -14   kcontrol/randr/module/randrmonitor.cpp     
M  +10   -0    kcontrol/randr/module/randrmonitor.h     

http://commits.kde.org/kde-workspace/aba27511815aacec5c9769cd7a3a1fc1fa2cf80e