← Back to team overview

ubuntu-phone team mailing list archive

Re: power-off app

 

On 04/25/2016 10:01 AM, Matthias Apitz wrote:
> 
> Hello,
> 
> Do we have some small app which does the same as a short press on the
> power-button, just to switch-off the desktop? If not, how this could be
> done from shell/dbus/... I'd write a small app in QML for this. The
> background is, that the case of my M10 makes it complicate to press the
> button due to some fixating of the case there.
> 
> Thanks
> 
> 	matthias

Hi Matthias,

The magic spell is:

$ dbus-send --type=method_call --dest=org.gnome.ScreenSaver
/org/gnome/ScreenSaver org.gnome.ScreenSaver.Lock

I have exactly the same problem with my case for Aquaris E5, and I am
about to write a small daemon that locks the screen upon an event from
proximity sensor. I will let you know once it is done & tested, if you
are interested.

Regards,
Orson


Attachment: signature.asc
Description: OpenPGP digital signature


Follow ups

References