edj_viewer: Fix cursor position on status bar.

Fix cursor position on status bar not to be bigger than view size.
This commit is contained in:
Jaehyun Cho 2015-02-24 16:48:11 +09:00
parent 89bbb67032
commit f2d5a22240
1 changed files with 2 additions and 2 deletions

View File

@ -129,8 +129,8 @@ rect_mouse_move_cb(void *data, Evas *e EINA_UNUSED,
Evas_Coord x, y, w, h;
evas_object_geometry_get(obj, &x, &y, &w, &h);
cursor.x = ev->cur.canvas.x;
cursor.y = ev->cur.canvas.y;
cursor.x = ev->cur.canvas.x - x;
cursor.y = ev->cur.canvas.y - y;
cursor.relx = (float) ((ev->cur.canvas.x - x) / (float) w);
cursor.rely = (float) ((ev->cur.canvas.y - y) / (float) h);