formatting, add an assert
This commit is contained in:
parent
51cc41e4db
commit
0dfff40a30
1 changed files with 6 additions and 3 deletions
|
@ -829,7 +829,7 @@ void client_update_transient_for(ObClient *self)
|
||||||
ObClient *target = NULL;
|
ObClient *target = NULL;
|
||||||
|
|
||||||
if (XGetTransientForHint(ob_display, self->window, &t)) {
|
if (XGetTransientForHint(ob_display, self->window, &t)) {
|
||||||
self->transient = TRUE;
|
self->transient = TRUE;
|
||||||
if (t != self->window) { /* cant be transient to itself! */
|
if (t != self->window) { /* cant be transient to itself! */
|
||||||
target = g_hash_table_lookup(window_map, &t);
|
target = g_hash_table_lookup(window_map, &t);
|
||||||
/* if this happens then we need to check for it*/
|
/* if this happens then we need to check for it*/
|
||||||
|
@ -845,14 +845,15 @@ void client_update_transient_for(ObClient *self)
|
||||||
group */
|
group */
|
||||||
if (t == self->group->leader ||
|
if (t == self->group->leader ||
|
||||||
t == None ||
|
t == None ||
|
||||||
t == RootWindow(ob_display, ob_screen)) {
|
t == RootWindow(ob_display, ob_screen))
|
||||||
|
{
|
||||||
/* window is a transient for its group! */
|
/* window is a transient for its group! */
|
||||||
target = OB_TRAN_GROUP;
|
target = OB_TRAN_GROUP;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else
|
} else
|
||||||
self->transient = FALSE;
|
self->transient = FALSE;
|
||||||
|
|
||||||
/* if anything has changed... */
|
/* if anything has changed... */
|
||||||
if (target != self->transient_for) {
|
if (target != self->transient_for) {
|
||||||
|
@ -2814,6 +2815,8 @@ ObClient *client_search_top_transient(ObClient *self)
|
||||||
} else {
|
} else {
|
||||||
GSList *it;
|
GSList *it;
|
||||||
|
|
||||||
|
g_assert(self->group);
|
||||||
|
|
||||||
for (it = self->group->members; it; it = it->next) {
|
for (it = self->group->members; it; it = it->next) {
|
||||||
ObClient *c = it->data;
|
ObClient *c = it->data;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue