2010-07-22 01:15:18 +02:00
|
|
|
#ifndef IPC_H_
|
|
|
|
#define IPC_H_
|
|
|
|
|
2010-07-23 04:43:43 +02:00
|
|
|
#include <stdint.h>
|
2010-07-22 01:15:18 +02:00
|
|
|
|
2010-08-07 02:10:05 +02:00
|
|
|
/*
|
|
|
|
* Initiate a connection to i3.
|
|
|
|
* socket-path must be a valid path to the ipc_socket of i3
|
|
|
|
*
|
|
|
|
*/
|
2010-07-23 04:43:43 +02:00
|
|
|
int init_connection(const char *socket_path);
|
2010-08-07 02:10:05 +02:00
|
|
|
|
|
|
|
/*
|
|
|
|
* Sends a Message to i3.
|
|
|
|
* type must be a valid I3_IPC_MESSAGE_TYPE (see i3/ipc.h for further information)
|
|
|
|
*
|
|
|
|
*/
|
2010-07-23 04:43:43 +02:00
|
|
|
int i3_send_msg(uint32_t type, const char* payload);
|
2010-08-07 02:10:05 +02:00
|
|
|
|
|
|
|
/*
|
|
|
|
* Subscribe to all the i3-events, we need
|
|
|
|
*
|
|
|
|
*/
|
2010-07-23 04:43:43 +02:00
|
|
|
void subscribe_events();
|
2010-07-22 01:15:18 +02:00
|
|
|
|
|
|
|
#endif
|