Use con_has_parent in con_fullscreen_permits_focusing
This commit is contained in:
parent
57ee66ad25
commit
df437aa87e
|
@ -2070,14 +2070,7 @@ bool con_fullscreen_permits_focusing(Con *con) {
|
||||||
|
|
||||||
/* Allow it only if the container to be focused is contained within the
|
/* Allow it only if the container to be focused is contained within the
|
||||||
* current fullscreen container. */
|
* current fullscreen container. */
|
||||||
do {
|
return con_has_parent(con, fs);
|
||||||
if (con->parent == fs)
|
|
||||||
return true;
|
|
||||||
con = con->parent;
|
|
||||||
} while (con);
|
|
||||||
|
|
||||||
/* Focusing con would hide it behind a fullscreen window, disallow it. */
|
|
||||||
return false;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
Loading…
Reference in New Issue