client: Expose group windows.

Signed-off-by: Maarten Maathuis <madman2003@gmail.com>
Signed-off-by: Julien Danjou <julien@danjou.info>
This commit is contained in:
Maarten Maathuis 2008-12-01 19:06:35 +01:00 committed by Julien Danjou
parent 8b88541f0a
commit 40c208a422
4 changed files with 13 additions and 0 deletions

View File

@ -1477,6 +1477,7 @@ luaA_client_newindex(lua_State *L)
* \lfield maximized_horizontal The client is maximized horizontally or not.
* \lfield maximized_vertical The client is maximized vertically or not.
* \lfield transient_for Return the client the window is transient for.
* \lfield group_id Identification unique to a group of windows.
* \lfield size_hints A table with size hints of the client: user_position,
* user_size, program_position and program_size.
*/
@ -1600,6 +1601,12 @@ luaA_client_index(lua_State *L)
case A_TK_FULLSCREEN:
lua_pushboolean(L, (*c)->isfullscreen);
break;
case A_TK_GROUP_ID:
if((*c)->group_win)
lua_pushnumber(L, (*c)->group_win);
else
return 0;
break;
case A_TK_MAXIMIZED_HORIZONTAL:
lua_pushboolean(L, (*c)->ismaxhoriz);
break;

View File

@ -28,6 +28,7 @@ font
fullscreen
gap
geometry
group_id
grow
height
hide

View File

@ -192,6 +192,9 @@ property_update_wm_hints(client_t *c, xcb_get_property_reply_t *reply)
if(wmh.flags & XCB_WM_HINT_INPUT)
c->nofocus = !wmh.input;
if(wmh.flags & XCB_WM_HINT_WINDOW_GROUP)
c->group_win = wmh.window_group;
}
static int

View File

@ -203,6 +203,8 @@ struct client_t
window_type_t type;
/** Window of the client */
xcb_window_t win;
/** Window of the group leader */
xcb_window_t group_win;
/** Client logical screen */
int screen;
/** Client physical screen */