discomfitor pushed a commit to branch master.

http://git.enlightenment.org/core/enlightenment.git/commit/?id=2c7e91d38f09ecb615b6936207a220702029999a

commit 2c7e91d38f09ecb615b6936207a220702029999a
Author: Mike Blumenkrantz <[email protected]>
Date:   Fri Feb 24 14:15:42 2017 -0500

    make e_comp_wl->ptr.x/y ints and fix usage to be consistent
    
    sometimes these were treated as ints and sometimes wl_fixed
---
 src/bin/e_comp_wl.h                     |  2 +-
 src/bin/e_comp_wl_data.c                |  4 ++--
 src/modules/wl_desktop_shell/wl_shell.c | 12 ++++++------
 src/modules/wl_desktop_shell/xdg5.c     | 12 ++++++------
 src/modules/wl_desktop_shell/xdg6.c     | 12 ++++++------
 5 files changed, 21 insertions(+), 21 deletions(-)

diff --git a/src/bin/e_comp_wl.h b/src/bin/e_comp_wl.h
index 9a211d6..0b45241 100644
--- a/src/bin/e_comp_wl.h
+++ b/src/bin/e_comp_wl.h
@@ -195,7 +195,7 @@ struct _E_Comp_Wl_Data
    struct
      {
         Eina_List *resources;
-        wl_fixed_t x, y;
+        Evas_Coord x, y;
         wl_fixed_t grab_x, grab_y;
         uint32_t button;
         uint32_t serial[2]; //down/up
diff --git a/src/bin/e_comp_wl_data.c b/src/bin/e_comp_wl_data.c
index 0f9eba5..53dc07b 100644
--- a/src/bin/e_comp_wl_data.c
+++ b/src/bin/e_comp_wl_data.c
@@ -1017,8 +1017,8 @@ e_comp_wl_data_device_send_enter(E_Client *ec)
         return;
      }
 #endif
-   x = wl_fixed_to_int(e_comp_wl->ptr.x) - 
e_comp_wl->selection.target->client.x;
-   y = wl_fixed_to_int(e_comp_wl->ptr.y) - 
e_comp_wl->selection.target->client.y;
+   x = e_comp_wl->ptr.x - e_comp_wl->selection.target->client.x;
+   y = e_comp_wl->ptr.y - e_comp_wl->selection.target->client.y;
    serial = wl_display_next_serial(e_comp_wl->wl.disp);
    wl_data_device_send_enter(data_device_res, serial, ec->comp_data->surface,
                              wl_fixed_from_int(x), wl_fixed_from_int(y),
diff --git a/src/modules/wl_desktop_shell/wl_shell.c 
b/src/modules/wl_desktop_shell/wl_shell.c
index 5b22721..1d84982 100644
--- a/src/modules/wl_desktop_shell/wl_shell.c
+++ b/src/modules/wl_desktop_shell/wl_shell.c
@@ -49,8 +49,8 @@ _wl_shell_surface_cb_move(struct wl_client *client 
EINA_UNUSED, struct wl_resour
      }
 
    e_comp_object_frame_xy_unadjust(ec->frame,
-                                   wl_fixed_to_int(e_comp_wl->ptr.x),
-                                   wl_fixed_to_int(e_comp_wl->ptr.y),
+                                   e_comp_wl->ptr.x,
+                                   e_comp_wl->ptr.y,
                                    &ev.canvas.x, &ev.canvas.y);
 
    e_shell_surface_mouse_down_helper(ec, &ev, EINA_TRUE);
@@ -81,8 +81,8 @@ _wl_shell_surface_cb_resize(struct wl_client *client 
EINA_UNUSED, struct wl_reso
 
    e_comp_wl->resize.resource = resource;
    e_comp_wl->resize.edges = edges;
-   e_comp_wl->ptr.grab_x = e_comp_wl->ptr.x - wl_fixed_from_int(ec->client.x);
-   e_comp_wl->ptr.grab_y = e_comp_wl->ptr.y - wl_fixed_from_int(ec->client.y);
+   e_comp_wl->ptr.grab_x = wl_fixed_from_int(e_comp_wl->ptr.x) - 
wl_fixed_from_int(ec->client.x);
+   e_comp_wl->ptr.grab_y = wl_fixed_from_int(e_comp_wl->ptr.y) - 
wl_fixed_from_int(ec->client.y);
 
    switch (e_comp_wl->ptr.button)
      {
@@ -101,8 +101,8 @@ _wl_shell_surface_cb_resize(struct wl_client *client 
EINA_UNUSED, struct wl_reso
      }
 
    e_comp_object_frame_xy_unadjust(ec->frame,
-                                   wl_fixed_to_int(e_comp_wl->ptr.x),
-                                   wl_fixed_to_int(e_comp_wl->ptr.y),
+                                   e_comp_wl->ptr.x,
+                                   e_comp_wl->ptr.y,
                                    &ev.canvas.x, &ev.canvas.y);
 
    e_shell_surface_mouse_down_helper(ec, &ev, EINA_FALSE);
diff --git a/src/modules/wl_desktop_shell/xdg5.c 
b/src/modules/wl_desktop_shell/xdg5.c
index 4d4857a..cb12d50 100644
--- a/src/modules/wl_desktop_shell/xdg5.c
+++ b/src/modules/wl_desktop_shell/xdg5.c
@@ -256,8 +256,8 @@ _e_xdg_shell_surface_cb_move(struct wl_client *client 
EINA_UNUSED, struct wl_res
      }
 
    e_comp_object_frame_xy_unadjust(ec->frame,
-                                   wl_fixed_to_int(e_comp_wl->ptr.x),
-                                   wl_fixed_to_int(e_comp_wl->ptr.y),
+                                   e_comp_wl->ptr.x,
+                                   e_comp_wl->ptr.y,
                                    &ev.canvas.x, &ev.canvas.y);
 
    e_shell_surface_mouse_down_helper(ec, &ev, EINA_TRUE);
@@ -290,8 +290,8 @@ _e_xdg_shell_surface_cb_resize(struct wl_client *client 
EINA_UNUSED, struct wl_r
 
    e_comp_wl->resize.resource = resource;
    e_comp_wl->resize.edges = edges;
-   e_comp_wl->ptr.grab_x = e_comp_wl->ptr.x - wl_fixed_from_int(ec->client.x);
-   e_comp_wl->ptr.grab_y = e_comp_wl->ptr.y - wl_fixed_from_int(ec->client.y);
+   e_comp_wl->ptr.grab_x = wl_fixed_from_int(e_comp_wl->ptr.x) - 
wl_fixed_from_int(ec->client.x);
+   e_comp_wl->ptr.grab_y = wl_fixed_from_int(e_comp_wl->ptr.y) - 
wl_fixed_from_int(ec->client.y);
 
    switch (e_comp_wl->ptr.button)
      {
@@ -310,8 +310,8 @@ _e_xdg_shell_surface_cb_resize(struct wl_client *client 
EINA_UNUSED, struct wl_r
      }
 
    e_comp_object_frame_xy_unadjust(ec->frame,
-                                   wl_fixed_to_int(e_comp_wl->ptr.x),
-                                   wl_fixed_to_int(e_comp_wl->ptr.y),
+                                   e_comp_wl->ptr.x,
+                                   e_comp_wl->ptr.y,
                                    &ev.canvas.x, &ev.canvas.y);
 
    e_shell_surface_mouse_down_helper(ec, &ev, EINA_FALSE);
diff --git a/src/modules/wl_desktop_shell/xdg6.c 
b/src/modules/wl_desktop_shell/xdg6.c
index 8045b45..ab14245 100644
--- a/src/modules/wl_desktop_shell/xdg6.c
+++ b/src/modules/wl_desktop_shell/xdg6.c
@@ -1062,8 +1062,8 @@ _e_xdg_toplevel_cb_move(struct wl_client *client 
EINA_UNUSED, struct wl_resource
      }
 
    e_comp_object_frame_xy_unadjust(ec->frame,
-                                   wl_fixed_to_int(e_comp_wl->ptr.x),
-                                   wl_fixed_to_int(e_comp_wl->ptr.y),
+                                   e_comp_wl->ptr.x,
+                                   e_comp_wl->ptr.y,
                                    &ev.canvas.x, &ev.canvas.y);
 
    e_shell_surface_mouse_down_helper(ec, &ev, EINA_TRUE);
@@ -1096,8 +1096,8 @@ _e_xdg_toplevel_cb_resize(struct wl_client *client 
EINA_UNUSED, struct wl_resour
 
    e_comp_wl->resize.resource = resource;
    e_comp_wl->resize.edges = edges;
-   e_comp_wl->ptr.grab_x = e_comp_wl->ptr.x - wl_fixed_from_int(ec->client.x);
-   e_comp_wl->ptr.grab_y = e_comp_wl->ptr.y - wl_fixed_from_int(ec->client.y);
+   e_comp_wl->ptr.grab_x = wl_fixed_from_int(e_comp_wl->ptr.x) - 
wl_fixed_from_int(ec->client.x);
+   e_comp_wl->ptr.grab_y = wl_fixed_from_int(e_comp_wl->ptr.y) - 
wl_fixed_from_int(ec->client.y);
 
    switch (e_comp_wl->ptr.button)
      {
@@ -1116,8 +1116,8 @@ _e_xdg_toplevel_cb_resize(struct wl_client *client 
EINA_UNUSED, struct wl_resour
      }
 
    e_comp_object_frame_xy_unadjust(ec->frame,
-                                   wl_fixed_to_int(e_comp_wl->ptr.x),
-                                   wl_fixed_to_int(e_comp_wl->ptr.y),
+                                   e_comp_wl->ptr.x,
+                                   e_comp_wl->ptr.y,
                                    &ev.canvas.x, &ev.canvas.y);
 
    e_shell_surface_mouse_down_helper(ec, &ev, EINA_FALSE);

-- 


Reply via email to