You are not logged in.
I'm using gnome3, without any special (acpi or similar) configuration.
When closing the lid of my laptop, it usually suspends. However, when an external monitor is attached, closing the lid only makes the laptop-screen blank, and leaves it running.
Does anyone know how to change this behaviour, so that it always suspends when I close the lid?
What program does actually do the suspending? Is it the gnome-power-manager?
Cheers
Jan
Offline
The easiest way is to install gnome-tweak-tool, click shell and change the close laptop lid action in there.
Offline
gnome-tweak-tool is totally useless in this case...
Offline
@jaco I had a very similar problem to rggjan's and so gnome-tweak-tool would probably be very useful.
Offline
For my own, on my two laptops (a HP Probook and a Thinkpad), lid closing is configured with "suspend" in Gnome-Tweak-Tool and, yes, lid closing suspends the laptop.... unless there's a external monitor attached (which is the problem of the OP).
Offline
If I have my laptop connected to my tv via hdmi and I close the lid, my computer suspends and I set this up with gnome-tweak-tool.
Offline
Doesn't work for me, either. "Laptop lid close action on battery" and "Laptop lid close action on AC" are both set to "suspend" in the gnome-tweak-tool, but it still does not suspend when I close the lid with an external (vga) monitor attached.
@quasifilmie: Did you set any other settings in the gnome-tweak-tool?
Offline
No I didn't but this may help you. https://wiki.archlinux.org/index.php/Laptop_Mode_Tools
Offline
You could put an "xrandr --output VGA1 --off" in /etc/acpi/handler.sh "button/lid" "close" event (VGA1, or whatever your external monitor). So for example I force my laptop to lock and suspend thus:
button/lid)
case "$3" in
close)
#echo "LID closed!">/dev/tty5
DISPLAY=:0.0 su paul -c "/usr/bin/slock&"
sleep 4
pm-suspend
;;
open)
#echo "LID opened!">/dev/tty5
;;
Offline
You could put an "xrandr --output VGA1 --off" in /etc/acpi/handler.sh "button/lid" "close" event (VGA1, or whatever your external monitor). So for example I force my laptop to lock and suspend thus:
Hmm... doesn't that interfere with the gnome power management somehow?
Offline