libweston-desktop: Unset use_geometry when unsetting relative_to
In other parts of the code, use_geometry implies a parent is present. So let's clear it when we clear relative placement. Signed-off-by: Derek Foreman <derek.foreman@collabora.com>
This commit is contained in:
parent
123e921871
commit
eebbe26d7b
@ -89,6 +89,8 @@ weston_desktop_surface_update_view_position(struct weston_desktop_surface *surfa
|
||||
if (!parent) {
|
||||
struct weston_coord_global pos;
|
||||
|
||||
assert(!surface->use_geometry);
|
||||
|
||||
pos.c = weston_coord(x, y);
|
||||
wl_list_for_each(view, &surface->view_list, link)
|
||||
weston_view_set_position(view->view, pos);
|
||||
@ -843,6 +845,7 @@ weston_desktop_surface_unset_relative_to(struct weston_desktop_surface *surface)
|
||||
return;
|
||||
|
||||
surface->parent = NULL;
|
||||
surface->use_geometry = false;
|
||||
wl_list_remove(&surface->children_link);
|
||||
wl_list_init(&surface->children_link);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user