1
0
Fork 0
forked from wry/wry

tree: don't allow fullscreening the root container in a workspace

This commit is contained in:
Julian Orth 2024-02-21 13:32:48 +01:00
parent 0ab9ec3b75
commit 8430278264

View file

@ -346,6 +346,10 @@ impl ToplevelData {
}
Some(p) => p,
};
if parent.node_is_workspace() {
log::warn!("Cannot fullscreen root container in a workspace");
return;
}
let placeholder = Rc::new(PlaceholderNode::new_for(state, node.clone()));
parent.cnode_replace_child(node.tl_as_node(), placeholder.clone());
let mut kb_foci = Default::default();