transaction: Allow no popup descriptor in popup list

Input method popups in the future will destroy the scene descriptor when
it isn't mapped and therefore shouldn't be tampered with here.

(cherry picked from commit 023f6b0a50)
This commit is contained in:
Alexander Orzechowski 2024-08-04 13:02:37 -04:00 committed by Simon Ser
parent af782c17bb
commit bb666f2ac9

View file

@ -612,9 +612,11 @@ void arrange_popups(struct wlr_scene_tree *popups) {
struct sway_popup_desc *popup = scene_descriptor_try_get(node, struct sway_popup_desc *popup = scene_descriptor_try_get(node,
SWAY_SCENE_DESC_POPUP); SWAY_SCENE_DESC_POPUP);
int lx, ly; if (popup) {
wlr_scene_node_coords(popup->relative, &lx, &ly); int lx, ly;
wlr_scene_node_set_position(node, lx, ly); wlr_scene_node_coords(popup->relative, &lx, &ly);
wlr_scene_node_set_position(node, lx, ly);
}
} }
} }