summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWooHyun Jung <wh0705.jung@samsung.com>2019-03-25 08:52:10 -0400
committerMike Blumenkrantz <zmike@samsung.com>2019-03-25 08:52:10 -0400
commitd761658985f45c582a9d5cbc6ab6a1beada6d642 (patch)
treed058a20d10065284a2c265fb52968b5488a316ca
parent620eb070f40f398ecb180181f98469fbb6ac9dd8 (diff)
elm_entry: fix a bug in moving the magnifier
Summary: When moving the magnifier in elm_entry, _magnifier_move function occured infinite loop problem by calling evas_object_move twice with different positions. So, I changed it to call evas_object_move once. ref T7202 Test Plan: 1. Set profile to "mobile" 2. elementary_test 3. entry 4. long press mouse button on elm_entry 5. when the magnifier is shown, try to move it Reviewers: zmike, bu5hm4n, bowonryu, id213sin Reviewed By: zmike Subscribers: cedric, #reviewers, #committers Tags: #efl Maniphest Tasks: T7202 Differential Revision: https://phab.enlightenment.org/D8462
-rw-r--r--src/lib/elementary/elm_entry.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/lib/elementary/elm_entry.c b/src/lib/elementary/elm_entry.c
index d42f630c01..ed7035fd90 100644
--- a/src/lib/elementary/elm_entry.c
+++ b/src/lib/elementary/elm_entry.c
@@ -1891,9 +1891,8 @@ _magnifier_move(void *data)
1891 cx += ex; 1891 cx += ex;
1892 cy += ey; 1892 cy += ey;
1893 1893
1894 //Move the Magnifier 1894 // calculate the position of the magnifier
1895 edje_object_parts_extends_calc(sd->mgf_bg, &x, &y, &w, &h); 1895 edje_object_parts_extends_calc(sd->mgf_bg, &x, &y, &w, &h);
1896 evas_object_move(sd->mgf_bg, cx - x - (w / 2), cy - y - h);
1897 1896
1898 mx = cx - x - (w / 2); 1897 mx = cx - x - (w / 2);
1899 my = cy - y - h; 1898 my = cy - y - h;
@@ -1920,9 +1919,11 @@ _magnifier_move(void *data)
1920 my = 0; 1919 my = 0;
1921 if (my + mh > wh) 1920 if (my + mh > wh)
1922 my = wh - mh; 1921 my = wh - mh;
1923 evas_object_move(sd->mgf_bg, mx, my);
1924 } 1922 }
1925 1923
1924 // move the magnifier to the proper position
1925 evas_object_move(sd->mgf_bg, mx, my);
1926
1926 //Set the Proxy Render Area 1927 //Set the Proxy Render Area
1927 evas_object_geometry_get(data, &x, &y, &w, &h); 1928 evas_object_geometry_get(data, &x, &y, &w, &h);
1928 evas_object_geometry_get(sd->mgf_proxy, &px, &py, &pw, &ph); 1929 evas_object_geometry_get(sd->mgf_proxy, &px, &py, &pw, &ph);