From ba84e7e1669b94d202dc20bdf4a7a88377790b66 Mon Sep 17 00:00:00 2001 From: Rob Bradford Date: Thu, 6 Dec 2012 12:07:48 +0000 Subject: shell: Remove confusing case fall-through This avoids calling weston_surface_set_position twice on the same surface. The second call has no effect in many cases because sx and sy are usually zero on this path. This change now means that any sx/sy values passed into ::attach will be ignored on the first attach for popup surfaces. This similar to the behaviour for other surface types. --- src/shell.c | 1 + 1 file changed, 1 insertion(+) (limited to 'src') diff --git a/src/shell.c b/src/shell.c index 93139604..f8cee0ec 100644 --- a/src/shell.c +++ b/src/shell.c @@ -2920,6 +2920,7 @@ map(struct desktop_shell *shell, struct weston_surface *surface, break; case SHELL_SURFACE_POPUP: shell_map_popup(shsurf); + break; case SHELL_SURFACE_NONE: weston_surface_set_position(surface, surface->geometry.x + sx, -- cgit v1.2.3