forked from enlightenment/efl
added ecore_x_window_delete_request_send
SVN revision: 11324
This commit is contained in:
parent
4a2f0a12a7
commit
95dcbdf55d
|
@ -739,6 +739,7 @@ Ecore_X_Window ecore_x_window_new(Ecore_X_Window parent, int x, int y, int w,
|
||||||
Ecore_X_Window ecore_x_window_override_new(Ecore_X_Window parent, int x, int y, int w, int h);
|
Ecore_X_Window ecore_x_window_override_new(Ecore_X_Window parent, int x, int y, int w, int h);
|
||||||
Ecore_X_Window ecore_x_window_input_new(Ecore_X_Window parent, int x, int y, int w, int h);
|
Ecore_X_Window ecore_x_window_input_new(Ecore_X_Window parent, int x, int y, int w, int h);
|
||||||
void ecore_x_window_del(Ecore_X_Window win);
|
void ecore_x_window_del(Ecore_X_Window win);
|
||||||
|
void ecore_x_window_delete_request_send(Ecore_X_Window win);
|
||||||
void ecore_x_window_show(Ecore_X_Window win);
|
void ecore_x_window_show(Ecore_X_Window win);
|
||||||
void ecore_x_window_hide(Ecore_X_Window win);
|
void ecore_x_window_hide(Ecore_X_Window win);
|
||||||
void ecore_x_window_move(Ecore_X_Window win, int x, int y);
|
void ecore_x_window_move(Ecore_X_Window win, int x, int y);
|
||||||
|
|
|
@ -239,9 +239,38 @@ ecore_x_window_defaults_set(Ecore_X_Window win)
|
||||||
void
|
void
|
||||||
ecore_x_window_del(Ecore_X_Window win)
|
ecore_x_window_del(Ecore_X_Window win)
|
||||||
{
|
{
|
||||||
|
/* sorry sir, deleting the root window doesn't sound like
|
||||||
|
* a smart idea.
|
||||||
|
*/
|
||||||
|
if (win)
|
||||||
XDestroyWindow(_ecore_x_disp, win);
|
XDestroyWindow(_ecore_x_disp, win);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Sends a delete request to the given window.
|
||||||
|
* @param win The given window.
|
||||||
|
* @ingroup Evas_X_Window_Destroy_Group
|
||||||
|
*/
|
||||||
|
void
|
||||||
|
ecore_x_window_delete_request_send(Ecore_X_Window win)
|
||||||
|
{
|
||||||
|
/* sorry sir, deleting the root window doesn't sound like
|
||||||
|
* a smart idea.
|
||||||
|
*/
|
||||||
|
if (!win)
|
||||||
|
return;
|
||||||
|
|
||||||
|
xev.xclient.type = ClientMessage;
|
||||||
|
xev.xclient.display = _ecore_x_disp;
|
||||||
|
xev.xclient.window = win;
|
||||||
|
xev.xclient.message_type = _ecore_x_atom_wm_protocols;
|
||||||
|
xev.xclient.format = 32;
|
||||||
|
xev.xclient.data.l[0] = _ecore_x_atom_wm_delete_window;
|
||||||
|
xev.xclient.data.l[1] = CurrentTime;
|
||||||
|
|
||||||
|
XSendEvent(_ecore_x_disp, win, False, NoEventMask, &xev);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @defgroup Evas_X_Window_Visibility_Group X Window Visibility Functions
|
* @defgroup Evas_X_Window_Visibility_Group X Window Visibility Functions
|
||||||
*
|
*
|
||||||
|
|
Loading…
Reference in New Issue