/*
 * xsmp.h
 *
 *  Created on: Oct 31, 2008
 *      Author: jos
 */

#ifndef XSMP_H_
#define XSMP_H_

#include <X11/SM/SMlib.h>
#include <X11/ICE/ICElib.h>

typedef enum {
    XSMP_STATE_IDLE,
    XSMP_STATE_SAVE_YOURSELF,
    XSMP_STATE_INTERACT_REQUEST,
    XSMP_STATE_INTERACT,
    XSMP_STATE_SAVE_YOURSELF_DONE,
    XSMP_STATE_SHUTDOWN_CANCELLED,
    XSMP_STATE_CONNECTION_CLOSED,
} SMClientXSMPState;

typedef struct {
    SmcConn connection;
    char *client_id;
    SMClientXSMPState state;
} XSMPConnection;


#endif /* XSMP_H_ */
