logind-button.h | logind-button.h | |||
---|---|---|---|---|
skipping to change at line 28 | skipping to change at line 28 | |||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | |||
Lesser General Public License for more details. | Lesser General Public License for more details. | |||
You should have received a copy of the GNU Lesser General Public License | You should have received a copy of the GNU Lesser General Public License | |||
along with systemd; If not, see <http://www.gnu.org/licenses/>. | along with systemd; If not, see <http://www.gnu.org/licenses/>. | |||
***/ | ***/ | |||
typedef struct Button Button; | typedef struct Button Button; | |||
typedef enum HandleButton { | typedef enum HandleButton { | |||
HANDLE_OFF, | HANDLE_IGNORE, | |||
HANDLE_NO_SESSION, /* Only handle key when nobody is logged in; h | HANDLE_POWEROFF, | |||
onour inhibitors */ | HANDLE_REBOOT, | |||
HANDLE_TTY_SESSION, /* Only handle key when nobody is logged in, o | HANDLE_HALT, | |||
r the fg session is the only one and non-graphical; honour inhibitors */ | HANDLE_KEXEC, | |||
HANDLE_ANY_SESSION, /* Only handle key when nobody is logged in, o | HANDLE_SUSPEND, | |||
r the fg session is the only one; honour inhibtors */ | HANDLE_HIBERNATE, | |||
HANDLE_ALWAYS, /* Always handle, ignore sessions; ignore inhi | ||||
bitors */ | ||||
_HANDLE_BUTTON_MAX, | _HANDLE_BUTTON_MAX, | |||
_HANDLE_BUTTON_INVALID = -1 | _HANDLE_BUTTON_INVALID = -1 | |||
} HandleButton; | } HandleButton; | |||
#include "list.h" | #include "list.h" | |||
#include "util.h" | #include "util.h" | |||
#include "logind.h" | #include "logind.h" | |||
struct Button { | struct Button { | |||
Manager *manager; | Manager *manager; | |||
char *name; | char *name; | |||
char *seat; | char *seat; | |||
int fd; | int fd; | |||
bool lid_close_queued; | ||||
}; | }; | |||
Button* button_new(Manager *m, const char *name); | Button* button_new(Manager *m, const char *name); | |||
void button_free(Button*b); | void button_free(Button*b); | |||
int button_open(Button *b); | int button_open(Button *b); | |||
int button_process(Button *b); | int button_process(Button *b); | |||
int button_recheck(Button *b); | ||||
int button_set_seat(Button *b, const char *sn); | int button_set_seat(Button *b, const char *sn); | |||
const char* handle_button_to_string(HandleButton h); | const char* handle_button_to_string(HandleButton h); | |||
HandleButton handle_button_from_string(const char *s); | HandleButton handle_button_from_string(const char *s); | |||
int config_parse_handle_button(const char *filename, unsigned line, const c har *section, const char *lvalue, int ltype, const char *rvalue, void *data , void *userdata); | int config_parse_handle_button(const char *filename, unsigned line, const c har *section, const char *lvalue, int ltype, const char *rvalue, void *data , void *userdata); | |||
#endif | #endif | |||
End of changes. 3 change blocks. | ||||
9 lines changed or deleted | 10 lines changed or added | |||
This html diff was produced by rfcdiff 1.41. The latest version is available from http://tools.ietf.org/tools/rfcdiff/ |