diff options
| author | Dana Jansens <danakj@orodu.net> | 2007-05-28 02:21:10 +0000 |
|---|---|---|
| committer | Dana Jansens <danakj@orodu.net> | 2007-05-28 02:21:10 +0000 |
| commit | 2050e99a5f374ec5cc160eca7b8ebeb57e0c00a5 (patch) | |
| tree | 7e2dcbc541f7f9e2850669f31cf8b2fb058cef3a /openbox | |
| parent | a5aa1af32c3114dfecad8c82e378ff153b2d5f30 (diff) | |
dont count non-normal windows as parents, in the group too
Diffstat (limited to 'openbox')
| -rw-r--r-- | openbox/client.c | 19 |
1 files changed, 15 insertions, 4 deletions
diff --git a/openbox/client.c b/openbox/client.c index 0bc4ff90..fa677c5c 100644 --- a/openbox/client.c +++ b/openbox/client.c @@ -2376,10 +2376,21 @@ ObClient *client_search_focus_tree_full(ObClient *self) gboolean client_has_parent(ObClient *self) { - return (self->transient_for && - ((self->transient_for != OB_TRAN_GROUP && - client_normal(self->transient_for)) || - (self->group && self->group->members->next))); + if (self->transient_for) { + if (self->transient_for != OB_TRAN_GROUP) { + if (client_normal(self->transient_for)) + return TRUE; + } + else if (self->group) { + GSList *it; + + for (it = self->group->members; it; it = g_slist_next(it)) { + if (it->data != self && client_normal(it->data)) + return TRUE; + } + } + } + return FALSE; } static ObStackingLayer calc_layer(ObClient *self) |
