1
/* $Id: xfsm-manager.h 4715 2004-11-03 21:09:16Z benny $ */
3
* Copyright (c) 2003-2004 Benedikt Meurer <benny@xfce.org>
6
* This program is free software; you can redistribute it and/or modify
7
* it under the terms of the GNU General Public License as published by
8
* the Free Software Foundation; either version 2, or (at your option)
11
* This program is distributed in the hope that it will be useful,
12
* but WITHOUT ANY WARRANTY; without even the implied warranty of
13
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
* GNU General Public License for more details.
16
* You should have received a copy of the GNU General Public License
17
* along with this program; if not, write to the Free Software
18
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
22
#ifndef __XFSM_MANAGER_H__
23
#define __XFSM_MANAGER_H__
25
#include <libxfce4util/libxfce4util.h>
27
#include <xfce4-session/xfsm-client.h>
30
#define DIE_TIMEOUT ( 7 * 1000)
31
#define SAVE_TIMEOUT (60 * 1000)
32
#define STARTUP_TIMEOUT ( 8 * 1000)
38
XFSM_MANAGER_CHECKPOINT,
39
XFSM_MANAGER_SHUTDOWN,
40
XFSM_MANAGER_SHUTDOWNPHASE2,
44
void xfsm_manager_init (XfceRc *rc);
46
gboolean xfsm_manager_restart (void);
48
gchar* xfsm_manager_generate_client_id (SmsConn sms_conn) G_GNUC_PURE;
50
XfsmClient* xfsm_manager_new_client (SmsConn sms_conn,
52
gboolean xfsm_manager_register_client (XfsmClient *client,
53
const gchar *previous_id);
54
void xfsm_manager_start_interact (XfsmClient *client);
55
void xfsm_manager_interact (XfsmClient *client,
57
void xfsm_manager_interact_done (XfsmClient *client,
58
gboolean cancel_shutdown);
59
void xfsm_manager_save_yourself (XfsmClient *client,
65
void xfsm_manager_save_yourself_phase2 (XfsmClient *client);
66
void xfsm_manager_save_yourself_done (XfsmClient *client,
68
void xfsm_manager_close_connection (XfsmClient *client,
70
void xfsm_manager_close_connection_by_ice_conn (IceConn ice_conn);
72
gboolean xfsm_manager_check_clients_saving (void);
73
gboolean xfsm_manager_maybe_enter_phase2 (void);
74
gboolean xfsm_manager_save_timeout (gpointer client_data);
75
void xfsm_manager_perform_shutdown (void);
76
gboolean xfsm_manager_run_command (const XfsmProperties *properties,
77
const gchar *command);
78
void xfsm_manager_store_session (void);
79
void xfsm_manager_complete_saveyourself (void);
81
#endif /* !__XFSM_MANAGER_H__ */