GNOME Bugzilla – Bug 615805
[PATCH] randr plugin's auto-config results in laptop's display getting turned off
Last modified: 2011-03-02 17:20:09 UTC
If I plug in an external monitor to my laptop and run `xrandr`, it is auto-configured by g-s-d. If I then unplug it and run `xrandr` again, the external display recognized as off by g-s-d, *but* it also turns off my laptop's screen. This seems to happen because the laptop's "output" isn't set as "primary" in g-s-d. If I set it as such in the auto_configure_outputs method (just setting all the "remained on" ones to primary, for now) it solves this issue. Do you think that's the right approach? Or should we get the laptop output in g-s-d's auto-configure with get_laptop_output_info and set primary = TRUE just for that? One thing to note is when I call `xrandr`, the output name for the internal monitor is "PANEL" not LCD or LVDS; eg PANEL connected 1920x1200+0+0 (normal left inverted right x axis y axis) 287mm x 215mm 1920x1200Scaled 60.4* But just changing g-s-d (in 2.28.2)'s is_laptop method to include PANEL in its string checks doesn't fix the problem. I doubt fixing it in 2.30's gnome_rr_output_is_laptop would help either, based on examining from where that method is called.
There's actually nothing in the xrandr plugin in gnome-settings-daemon that uses the "primary" value. It doesn't set it, or unset it. Seeing as you're not using the control-center preferences, I'm not sure you're actually testing gnome-settings-daemon's xrandr plugin. Can you reproduce that after disabling the xrandr plugin (in GConf for GNOME 2.32, GSettings for GNOME 3)? If you're using GNOME 2.32 or GNOME 3, you can get debug information by creating: touch ~/gsd-debug-randr The log will be in ~/gsd-debug-randr.log
Created attachment 174342 [details] [review] Patch adding primary = TRUE This patch fixes the bug for me. gnome-desktop's *rr* code reads this value, IIRC.
I was definitely testing w/ gnome-control-center's display plugin which talks to gsd's xrandr plugin.
I believe your problem was fixed in another bug. Let us know if not. commit 89c21494aec0a2feda705d4e4cca36ab4ebff9f8 Author: William Jon McCann <jmccann@redhat.com> Date: Mon Nov 22 21:40:11 2010 -0500 xrandr: ensure a primary display is set https://bugzilla.gnome.org/show_bug.cgi?id=635455
Assuming this to be fixed as per last comment. Please reopen if this is not the case. Thanks.