commit a77e11d29e0656aeed65ce87974af8c6c5389478
parent e44829c7e136892f33cbed45ea29216c048523ad
Author: Michael Forney <mforney@mforney.org>
Date: Sat, 12 Jul 2014 19:08:59 -0700
compositor: Remove redundant setting of x and y in handle_motion
Diffstat:
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/libswc/compositor.c b/libswc/compositor.c
@@ -741,13 +741,10 @@ bool handle_motion(struct pointer_handler * handler, uint32_t time,
{
struct compositor_view * view;
bool found = false;
- int32_t x, y;
+ int32_t x = wl_fixed_to_int(fx), y = wl_fixed_to_int(fy);
wl_list_for_each(view, &compositor.views, link)
{
- x = wl_fixed_to_int(fx);
- y = wl_fixed_to_int(fy);
-
if (swc_rectangle_contains_point(&view->base.geometry, x, y)
&& pixman_region32_contains_point(&view->surface->state.input,
x - view->base.geometry.x,