client: allow special non-transient windows to be !above

Signed-off-by: Julien Danjou <julien@danjou.info>
This commit is contained in:
Maarten Maathuis 2009-03-26 22:13:43 +01:00 committed by Julien Danjou
parent 68970a3f56
commit cf16379778
3 changed files with 6 additions and 7 deletions

View File

@ -414,15 +414,8 @@ client_layer_translator(client_t *c)
/* then deal with windows type */ /* then deal with windows type */
switch(c->type) switch(c->type)
{ {
case WINDOW_TYPE_DOCK:
return LAYER_ABOVE;
case WINDOW_TYPE_DESKTOP: case WINDOW_TYPE_DESKTOP:
return LAYER_DESKTOP; return LAYER_DESKTOP;
case WINDOW_TYPE_DIALOG:
case WINDOW_TYPE_MENU:
case WINDOW_TYPE_TOOLBAR:
case WINDOW_TYPE_UTILITY:
return LAYER_ABOVE;
default: default:
break; break;
} }

5
ewmh.c
View File

@ -581,6 +581,11 @@ ewmh_client_check_hints(client_t *c)
c->type = MAX(c->type, WINDOW_TYPE_TOOLBAR); c->type = MAX(c->type, WINDOW_TYPE_TOOLBAR);
else if(state[i] == _NET_WM_WINDOW_TYPE_UTILITY) else if(state[i] == _NET_WM_WINDOW_TYPE_UTILITY)
c->type = MAX(c->type, WINDOW_TYPE_UTILITY); c->type = MAX(c->type, WINDOW_TYPE_UTILITY);
if(c->type != WINDOW_TYPE_NORMAL
&& c->type != WINDOW_TYPE_DESKTOP
&& !c->transient_for)
client_setabove(c, true);
} }
p_delete(&reply); p_delete(&reply);

View File

@ -51,6 +51,7 @@ property_update_wm_transient_for(client_t *c, xcb_get_property_reply_t *reply)
c->type = WINDOW_TYPE_DIALOG; c->type = WINDOW_TYPE_DIALOG;
c->transient_for = client_getbywin(trans); c->transient_for = client_getbywin(trans);
client_setabove(c, false);
} }
static int static int