X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?p=elogind.git;a=blobdiff_plain;f=src%2Flogin%2Flogind-button.h;h=80d93c7e6bdf691d4ffafbe803524ee7cd9d6479;hp=83bf1fc70cb3503b18ab55ed5bb599b6c289c94b;hb=77435fa5410006a32e176f128871cc402754e4e0;hpb=cc3773810855956bad92337cee8fa193584ab62e diff --git a/src/login/logind-button.h b/src/login/logind-button.h index 83bf1fc70..80d93c7e6 100644 --- a/src/login/logind-button.h +++ b/src/login/logind-button.h @@ -1,7 +1,6 @@ /*-*- Mode: C; c-basic-offset: 8; indent-tabs-mode: nil -*-*/ -#ifndef foologindbuttonhfoo -#define foologindbuttonhfoo +#pragma once /*** This file is part of systemd. @@ -24,26 +23,24 @@ typedef struct Button Button; -#include "list.h" -#include "util.h" #include "logind.h" struct Button { Manager *manager; - sd_event_source *event_source; + sd_event_source *io_event_source; + sd_event_source *check_event_source; char *name; char *seat; int fd; - bool lid_close_queued; + bool lid_closed; + bool docked; }; Button* button_new(Manager *m, const char *name); void button_free(Button*b); int button_open(Button *b); -int button_recheck(Button *b); int button_set_seat(Button *b, const char *sn); - -#endif +int button_check_switches(Button *b);