all repos — openbox @ 9b514b3b6165c80cfe7152c2088a97765f6c82f4

openbox fork - make it a bit more like ryudo

add the client_kill function, and the kill action, and bind it to the middle mouse button on the close button.
Dana Jansens danakj@orodu.net
commit

9b514b3b6165c80cfe7152c2088a97765f6c82f4

parent

d59db115520d7175b181c53d179c3ddb97c3139f

5 files changed, 18 insertions(+), 1 deletions(-)

jump to
M openbox/action.copenbox/action.c

@@ -73,6 +73,11 @@ {

client_close(data->client.c); } +void action_kill(union ActionData *data) +{ + client_kill(data->client.c); +} + void action_shade(union ActionData *data) { client_shade(data->client.c, TRUE);
M openbox/action.hopenbox/action.h

@@ -104,6 +104,8 @@ void action_focusraise(union ActionData *data);

/* ClientAction */ void action_close(union ActionData *data); /* ClientAction */ +void action_kill(union ActionData *data); +/* ClientAction */ void action_shade(union ActionData *data); /* ClientAction */ void action_unshade(union ActionData *data);
M openbox/client.copenbox/client.c

@@ -1652,6 +1652,11 @@ ce.xclient.data.l[4] = 0l;

XSendEvent(ob_display, self->window, FALSE, NoEventMask, &ce); } +void client_kill(Client *self) +{ + XKillClient(ob_display, self->window); +} + void client_set_desktop(Client *self, guint target) { guint old, i;
M openbox/client.hopenbox/client.h

@@ -380,8 +380,11 @@ unshaded.

*/ void client_shade(Client *self, gboolean shade); -/*! Request the client to close its window. */ +/*! Request the client to close its window */ void client_close(Client *self); + +/*! Kill the client off violently */ +void client_kill(Client *self); /*! Sends the window to the specified desktop */ void client_set_desktop(Client *self, guint target);
M plugins/mouse/mouse.cplugins/mouse/mouse.c

@@ -407,6 +407,8 @@ a = action_new(action_close);

mbind("1", "icon", MouseAction_DClick, a); a = action_new(action_close); mbind("1", "close", MouseAction_Click, a); + a = action_new(action_kill); + mbind("2", "close", MouseAction_Click, a); a = action_new(action_toggle_omnipresent); mbind("1", "alldesktops", MouseAction_Click, a);