Linux xxxx 4.4.0-31-generic #50-Ubuntu SMP Wed Jul 13 00:07:12 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux
HP x360 Spectre, core i7 Skylake. Ubuntu 16.04.1 LTS
Editing the file /etc/systemd/logind.conf works for me, adding the option HandleLidSwitchDocked=suspend the laptop suspend when is closed. Without this the screen go offline but the laptop remains operative.
Linux xxxx 4.4.0-31-generic #50-Ubuntu SMP Wed Jul 13 00:07:12 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux
HP x360 Spectre, core i7 Skylake. Ubuntu 16.04.1 LTS
Editing the file /etc/systemd/ logind. conf works for me, adding the option HandleLidSwitch Docked= suspend the laptop suspend when is closed. Without this the screen go offline but the laptop remains operative.