summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorUmesh Tanwar <umesh.tanwar@samsung.com>2017-03-10 11:49:16 +0530
committerAmitesh Singh <amitesh.sh@samsung.com>2017-03-10 11:57:08 +0530
commit3b4cbc56bb86d3344ddc6f40b874cc178c26b216 (patch)
treecde8e2952379c2fb1fa94e38303c5346c71b65bc
parent6c62ae3e6e1531d76a31aaacebee35f76b0abfa4 (diff)
ecore_animator: use EINA_DBL_EQ for comparing double values
Summary: EINA_FLT_EQ was used to compare double values. replace it with EINA_DBL_EQ @fix Signed-off-by: Umesh Tanwar <umesh.tanwar@samsung.com> Reviewers: raster, cedric, singh.amitesh Reviewed By: singh.amitesh Subscribers: atulfokk Differential Revision: https://phab.enlightenment.org/D4712 Signed-off-by: Amitesh Singh <amitesh.sh@samsung.com>
-rw-r--r--src/lib/ecore/ecore_anim.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/lib/ecore/ecore_anim.c b/src/lib/ecore/ecore_anim.c
index 8990c074c8..461d035152 100644
--- a/src/lib/ecore/ecore_anim.c
+++ b/src/lib/ecore/ecore_anim.c
@@ -223,7 +223,7 @@ _timer_tick_core(void *data EINA_UNUSED, Ecore_Thread *thread)
223 d = fmod(t0, ft); 223 d = fmod(t0, ft);
224 if (tick) 224 if (tick)
225 { 225 {
226 if (!EINA_FLT_EQ(pframetime, ft)) 226 if (!EINA_DBL_EQ(pframetime, ft))
227 { 227 {
228 t = (ft - d) * 1000000000.0; 228 t = (ft - d) * 1000000000.0;
229 t_ft = ft * 1000000000.0; 229 t_ft = ft * 1000000000.0;
@@ -686,7 +686,7 @@ _cubic_bezier_t_get(double a,
686 for (int i = 0; i < LIMIT; i++) 686 for (int i = 0; i < LIMIT; i++)
687 { 687 {
688 current_slope = _cubic_bezier_slope_get(guess_t, x1, x2); 688 current_slope = _cubic_bezier_slope_get(guess_t, x1, x2);
689 if (EINA_FLT_EQ(current_slope, 0.0)) return guess_t; 689 if (EINA_DBL_EQ(current_slope, 0.0)) return guess_t;
690 current_x = _cubic_bezier_calc(guess_t, x1, x2) - a; 690 current_x = _cubic_bezier_calc(guess_t, x1, x2) - a;
691 change = current_x / current_slope; 691 change = current_x / current_slope;
692 guess_t -= change; 692 guess_t -= change;
@@ -702,8 +702,8 @@ _pos_map_cubic_bezier(double pos,
702 double x2, 702 double x2,
703 double y2) 703 double y2)
704{ 704{
705 if (EINA_FLT_EQ(x1, y1) && 705 if (EINA_DBL_EQ(x1, y1) &&
706 EINA_FLT_EQ(x2, y2)) 706 EINA_DBL_EQ(x2, y2))
707 return pos; 707 return pos;
708 return _cubic_bezier_calc(_cubic_bezier_t_get(pos, x1, x2), y1, y2); 708 return _cubic_bezier_calc(_cubic_bezier_t_get(pos, x1, x2), y1, y2);
709} 709}
@@ -844,7 +844,7 @@ ecore_animator_frametime_set(double frametime)
844{ 844{
845 EINA_MAIN_LOOP_CHECK_RETURN; 845 EINA_MAIN_LOOP_CHECK_RETURN;
846 if (frametime < 0.0) frametime = 0.0; 846 if (frametime < 0.0) frametime = 0.0;
847 if (EINA_FLT_EQ(animators_frametime, frametime)) return ; 847 if (EINA_DBL_EQ(animators_frametime, frametime)) return ;
848 animators_frametime = frametime; 848 animators_frametime = frametime;
849 _end_tick(); 849 _end_tick();
850 if (_have_animators()) _begin_tick(); 850 if (_have_animators()) _begin_tick();