1
0
Fork 0
forked from wry/wry

tree: disallow moving focus to non-toplevel parent

This commit is contained in:
Julian Orth 2024-02-19 23:20:12 +01:00
parent 8555e9e5e5
commit 7f37e107af

View file

@ -582,7 +582,9 @@ impl WlSeatGlobal {
pub fn focus_parent(self: &Rc<Self>) {
if let Some(tl) = self.keyboard_node.get().node_toplevel() {
if let Some(parent) = tl.tl_data().parent.get() {
self.focus_node(parent.cnode_into_node());
if let Some(tl) = parent.node_toplevel() {
self.focus_node(tl.tl_into_node());
}
}
}
}