hermet pushed a commit to branch master.

http://git.enlightenment.org/core/elementary.git/commit/?id=35f801d765780f68a552019d02d7ff7ee9dcc386

commit 35f801d765780f68a552019d02d7ff7ee9dcc386
Author: ChunEon Park <her...@hermet.pe.kr>
Date:   Thu Dec 18 14:37:39 2014 +0900

    transit: adjust control point position range in the bezier sample
---
 src/bin/test_transit_bezier.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/src/bin/test_transit_bezier.c b/src/bin/test_transit_bezier.c
index fe4c6d8..3b429fe 100644
--- a/src/bin/test_transit_bezier.c
+++ b/src/bin/test_transit_bezier.c
@@ -93,8 +93,8 @@ ctrl_pt1_mouse_move_cb(void *data, Evas *e EINA_UNUSED,
 
    x = (ev->cur.canvas.x - (w/2));
    y = (ev->cur.canvas.y - (h/2));
-   if (x < 0) x = 0;
-   if (y < 0) y = 0;
+   if (x < -(w/2)) x = -(w/2);
+   if (y < -(h/2)) y = -(h/2);
    if (x > WIN_W) x = WIN_W - (w/2);
    if (y > WIN_H) y = WIN_H - (h/2);
    evas_object_move(obj, x, y);
@@ -117,8 +117,8 @@ ctrl_pt2_mouse_move_cb(void *data, Evas *e EINA_UNUSED,
 
    x = (ev->cur.canvas.x - (w/2));
    y = (ev->cur.canvas.y - (h/2));
-   if (x < 0) x = 0;
-   if (y < 0) y = 0;
+   if (x < -(w/2)) x = -(w/2);
+   if (y < -(h/2)) y = -(h/2);
    if (x > WIN_W) x = WIN_W - (w/2);
    if (y > WIN_H) y = WIN_H - (h/2);
    evas_object_move(obj, x, y);

-- 


Reply via email to