parent
b7c40c5e93
commit
f8266f2a18
|
@ -242,6 +242,7 @@ typedef struct _Ecore_X_Event_Xdnd_Finished Ecore_X_Event_Xdnd_Finish
|
|||
typedef struct _Ecore_X_Event_Window_Move_Resize_Request Ecore_X_Event_Window_Move_Resize_Request;
|
||||
typedef struct _Ecore_X_Event_Window_State_Request Ecore_X_Event_Window_State_Request;
|
||||
typedef struct _Ecore_X_Event_Frame_Extents_Request Ecore_X_Event_Frame_Extents_Request;
|
||||
typedef struct _Ecore_X_Event_Ping Ecore_X_Event_Ping;
|
||||
typedef struct _Ecore_X_Event_Desktop_Change Ecore_X_Event_Desktop_Change;
|
||||
typedef struct _Ecore_X_Event_Client_Message Ecore_X_Event_Client_Message;
|
||||
typedef struct _Ecore_X_Event_Window_Shape Ecore_X_Event_Window_Shape;
|
||||
|
@ -623,6 +624,13 @@ struct _Ecore_X_Event_Frame_Extents_Request
|
|||
Ecore_X_Window win;
|
||||
};
|
||||
|
||||
struct _Ecore_X_Event_Ping
|
||||
{
|
||||
Ecore_X_Window win;
|
||||
Ecore_X_Window event_win;
|
||||
Ecore_X_Time time;
|
||||
};
|
||||
|
||||
struct _Ecore_X_Event_Desktop_Change
|
||||
{
|
||||
Ecore_X_Window win;
|
||||
|
@ -746,6 +754,7 @@ extern EAPI int ECORE_X_EVENT_SELECTION_NOTIFY;
|
|||
extern EAPI int ECORE_X_EVENT_WINDOW_MOVE_RESIZE_REQUEST;
|
||||
extern EAPI int ECORE_X_EVENT_WINDOW_STATE_REQUEST;
|
||||
extern EAPI int ECORE_X_EVENT_FRAME_EXTENTS_REQUEST;
|
||||
extern EAPI int ECORE_X_EVENT_PING;
|
||||
extern EAPI int ECORE_X_EVENT_DESKTOP_CHANGE;
|
||||
extern EAPI int ECORE_X_EVENT_CLIENT_MESSAGE;
|
||||
extern EAPI int ECORE_X_EVENT_WINDOW_SHAPE;
|
||||
|
|
|
@ -116,6 +116,7 @@ int ECORE_X_EVENT_SELECTION_NOTIFY = 0;
|
|||
int ECORE_X_EVENT_WINDOW_MOVE_RESIZE_REQUEST = 0;
|
||||
int ECORE_X_EVENT_WINDOW_STATE_REQUEST = 0;
|
||||
int ECORE_X_EVENT_FRAME_EXTENTS_REQUEST = 0;
|
||||
int ECORE_X_EVENT_PING = 0;
|
||||
int ECORE_X_EVENT_DESKTOP_CHANGE = 0;
|
||||
int ECORE_X_EVENT_CLIENT_MESSAGE = 0;
|
||||
int ECORE_X_EVENT_WINDOW_SHAPE = 0;
|
||||
|
@ -261,6 +262,7 @@ ecore_x_init(const char *name)
|
|||
ECORE_X_EVENT_WINDOW_MOVE_RESIZE_REQUEST = ecore_event_type_new();
|
||||
ECORE_X_EVENT_WINDOW_STATE_REQUEST = ecore_event_type_new();
|
||||
ECORE_X_EVENT_FRAME_EXTENTS_REQUEST = ecore_event_type_new();
|
||||
ECORE_X_EVENT_PING = ecore_event_type_new();
|
||||
ECORE_X_EVENT_DESKTOP_CHANGE = ecore_event_type_new();
|
||||
ECORE_X_EVENT_CLIENT_MESSAGE = ecore_event_type_new();
|
||||
ECORE_X_EVENT_WINDOW_SHAPE = ecore_event_type_new();
|
||||
|
|
|
@ -1466,6 +1466,20 @@ _ecore_x_event_handle_client_message(XEvent *xevent)
|
|||
|
||||
ecore_event_add(ECORE_X_EVENT_FRAME_EXTENTS_REQUEST, e, NULL, NULL);
|
||||
}
|
||||
else if ((xevent->xclient.message_type == ECORE_X_ATOM_WM_PROTOCOLS)
|
||||
&& (xevent->xclient.data.l[0] == ECORE_X_ATOM_NET_WM_PING)
|
||||
&& (xevent->xclient.format == 32))
|
||||
{
|
||||
Ecore_X_Event_Ping *e;
|
||||
|
||||
e = calloc(1, sizeof(Ecore_X_Event_Ping));
|
||||
if (!e) return;
|
||||
e->win = xevent->xclient.window;
|
||||
e->time = xevent->xclient.data.l[1];
|
||||
e->event_win = xevent->xclient.data.l[2];
|
||||
|
||||
ecore_event_add(ECORE_X_EVENT_PING, e, NULL, NULL);
|
||||
}
|
||||
else
|
||||
{
|
||||
Ecore_X_Event_Client_Message *e;
|
||||
|
|
Loading…
Reference in New Issue