[mutter] wayland: Use meta_window_move to position xdg_popup windows



commit e2b7b26f28fee143ce5e362276562fe7712be0a4
Author: Jasper St. Pierre <jstpierre mecheye net>
Date:   Wed May 14 12:00:30 2014 -0400

    wayland: Use meta_window_move to position xdg_popup windows
    
    This makes sure we set the user rect as well, which is necessary to
    have things not "snap back" to weird locations.

 src/wayland/meta-wayland-surface.c |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)
---
diff --git a/src/wayland/meta-wayland-surface.c b/src/wayland/meta-wayland-surface.c
index 16287cc..ff56f92 100644
--- a/src/wayland/meta-wayland-surface.c
+++ b/src/wayland/meta-wayland-surface.c
@@ -1004,8 +1004,9 @@ xdg_shell_get_xdg_popup (struct wl_client *client,
     }
 
   window = meta_window_wayland_new (meta_get_display (), surface);
-  window->rect.x = parent_surf->window->rect.x + x;
-  window->rect.y = parent_surf->window->rect.y + y;
+  meta_window_move (window, FALSE,
+                    parent_surf->window->rect.x + x,
+                    parent_surf->window->rect.y + y);
   window->showing_for_first_time = FALSE;
   window->placed = TRUE;
   meta_window_set_transient_for (window, parent_surf->window);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]