SESSION_TTY,
SESSION_X11,
SESSION_WAYLAND,
+ SESSION_MIR,
+ SESSION_WEB,
_SESSION_TYPE_MAX,
_SESSION_TYPE_INVALID = -1
} SessionType;
+#define SESSION_TYPE_IS_GRAPHICAL(type) IN_SET(type, SESSION_X11, SESSION_WAYLAND, SESSION_MIR)
+
enum KillWho {
KILL_LEADER,
KILL_ALL,
struct Session {
Manager *manager;
- char *id;
+ const char *id;
unsigned int pos;
SessionType type;
SessionClass class;
Seat *seat;
unsigned int vtnr;
int vtfd;
- sd_event_source *vt_source;
pid_t leader;
uint32_t audit_id;
void session_set_idle_hint(Session *s, bool b);
int session_create_fifo(Session *s);
int session_start(Session *s);
-int session_stop(Session *s);
+int session_stop(Session *s, bool force);
int session_finalize(Session *s);
void session_release(Session *s);
int session_save(Session *s);
const char *kill_who_to_string(KillWho k) _const_;
KillWho kill_who_from_string(const char *s) _pure_;
-void session_mute_vt(Session *s);
+int session_prepare_vt(Session *s);
void session_restore_vt(Session *s);
bool session_is_controller(Session *s, const char *sender);