NAME
App::XScreenSaver::DBus::InhibitSleep - implements the logind "inhibitor locks" protocol
VERSION
version 1.0.2
SYNOPSIS
use Net::DBus::Reactor;
use App::XScreenSaver::DBus::InhibitSleep;
my $is = App::XScreenSaver::DBus::InhibitSleep->new;
$is->start;
Net::DBus::Reactor->new->run;
ATTRIBUTES
bus
the DBus system bus
logind_srv
the (e)logind DBus service
logind_obj
the (e)logind DBus object
inhibit_fd
the file descriptor that logind gives us when we ask for a lock; we close it to release the lock
log
a logger
METHODS
start
starts listening to the PrepareForSleep
signal from (e)logind, and takes the lock
AUTHOR
Gianni Ceccarelli <dakkar@thenautilus.net>
COPYRIGHT AND LICENSE
This software is Copyright (c) 2021 by Gianni Ceccarelli <dakkar@thenautilus.net>.
This is free software, licensed under:
The GNU Affero General Public License, Version 3, November 2007