X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=blobdiff_plain;ds=sidebyside;f=src%2Flogin%2Flogind.h;h=90c972df6c32f9201dbf296544d824fae0d7246c;hb=caa7531f137aeb260fbda53e89a22f516836e89b;hp=7df3556eb108f990dcf88d522f708d6bca659942;hpb=fb9ec2d4fc198bcb47352cfce7d436901308eed8;p=elogind.git diff --git a/src/login/logind.h b/src/login/logind.h index 7df3556eb..90c972df6 100644 --- a/src/login/logind.h +++ b/src/login/logind.h @@ -80,13 +80,9 @@ struct Manager { InhibitWhat action_what; /* If a shutdown/suspend was delayed due to a inhibitor this - contains the unit name we are supposed to start after the + contains the action we are supposed to perform after the delay is over */ - const char *action_unit; - - /* If a shutdown/suspend is currently executed, then this is - * the job of it */ - char *action_job; + HandleAction pending_action; usec_t action_timestamp; sd_event_source *idle_action_event_source; @@ -107,6 +103,10 @@ struct Manager { bool remove_ipc; + char **suspend_state, **suspend_mode; + char **hibernate_state, **hibernate_mode; + char **hybrid_sleep_state, **hybrid_sleep_mode; + Hashmap *polkit_registry; usec_t holdoff_timeout_usec; @@ -148,7 +148,8 @@ bool manager_is_docked_or_multiple_displays(Manager *m); extern const sd_bus_vtable manager_vtable[]; -int bus_manager_shutdown_or_sleep_now_or_later(Manager *m, const char *unit_name, InhibitWhat w, sd_bus_error *error); +int bus_manager_shutdown_or_sleep_now_or_later(Manager *m, HandleAction action, InhibitWhat w, sd_bus_error *error); +int shutdown_or_sleep(Manager *m, HandleAction action); int manager_send_changed(Manager *manager, const char *property, ...) _sentinel_;