diff options
| author | Dana Jansens <danakj@orodu.net> | 2007-05-13 17:15:15 +0000 |
|---|---|---|
| committer | Dana Jansens <danakj@orodu.net> | 2007-05-13 17:15:15 +0000 |
| commit | 11df262d7eb56ae6af98af86cbfee8226107114d (patch) | |
| tree | d01a30b3025aca83878b672d8df9c65d1e67ba5d /openbox/client.c | |
| parent | 0ee1581824f4693884a6f0abde62d20642df82ed (diff) | |
add support for _NET_WM_ACTION_ABOVE and _NET_WM_ACTION_BELOW which aren't in the NETWM spec yet, but will be shortly.
Diffstat (limited to 'openbox/client.c')
| -rw-r--r-- | openbox/client.c | 17 |
1 files changed, 14 insertions, 3 deletions
diff --git a/openbox/client.c b/openbox/client.c index 47f807d8..379342f4 100644 --- a/openbox/client.c +++ b/openbox/client.c @@ -1594,7 +1594,9 @@ void client_setup_decor_and_functions(ObClient *self) OB_CLIENT_FUNC_ICONIFY | OB_CLIENT_FUNC_MAXIMIZE | OB_CLIENT_FUNC_SHADE | - OB_CLIENT_FUNC_CLOSE); + OB_CLIENT_FUNC_CLOSE | + OB_CLIENT_FUNC_BELOW | + OB_CLIENT_FUNC_ABOVE); if (!(self->min_size.width < self->max_size.width || self->min_size.height < self->max_size.height)) @@ -1626,10 +1628,15 @@ void client_setup_decor_and_functions(ObClient *self) self->functions = OB_CLIENT_FUNC_MOVE; case OB_CLIENT_TYPE_DESKTOP: - case OB_CLIENT_TYPE_DOCK: /* these windows are not manipulated by the window manager */ self->decorations = 0; self->functions = 0; + + case OB_CLIENT_TYPE_DOCK: + /* these windows are not manipulated by the window manager, but they + can set below layer which has a special meaning */ + self->decorations = 0; + self->functions = OB_CLIENT_FUNC_BELOW; break; } @@ -1719,7 +1726,7 @@ void client_setup_decor_and_functions(ObClient *self) static void client_change_allowed_actions(ObClient *self) { - gulong actions[9]; + gulong actions[11]; gint num = 0; /* desktop windows are kept on all desktops */ @@ -1742,6 +1749,10 @@ static void client_change_allowed_actions(ObClient *self) actions[num++] = prop_atoms.net_wm_action_maximize_horz; actions[num++] = prop_atoms.net_wm_action_maximize_vert; } + if (self->functions & OB_CLIENT_FUNC_ABOVE) + actions[num++] = prop_atoms.net_wm_action_above; + if (self->functions & OB_CLIENT_FUNC_BELOW) + actions[num++] = prop_atoms.net_wm_action_below; PROP_SETA32(self->window, net_wm_allowed_actions, atom, actions, num); |
