Fix container_parent_layout for scratchpad windows

This commit is contained in:
emersion 2019-03-06 10:47:50 +01:00 committed by Drew DeVault
parent 7a44b542b8
commit 8dfdb3fa11
1 changed files with 4 additions and 1 deletions

View File

@ -1163,7 +1163,10 @@ enum sway_container_layout container_parent_layout(struct sway_container *con) {
if (con->parent) {
return con->parent->layout;
}
return con->workspace->layout;
if (con->workspace) {
return con->workspace->layout;
}
return L_NONE;
}
enum sway_container_layout container_current_parent_layout(