From ee79b90066e7f3d0587fcb445df7a7f8b82e112e Mon Sep 17 00:00:00 2001 From: Cedric BAIL Date: Tue, 20 Dec 2016 14:54:59 -0800 Subject: [PATCH] elementary: fix float comparison warning in bg test. --- src/bin/elementary/test_bg.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/bin/elementary/test_bg.c b/src/bin/elementary/test_bg.c index 3d1d8856b4..bb6b1197a0 100644 --- a/src/bin/elementary/test_bg.c +++ b/src/bin/elementary/test_bg.c @@ -47,13 +47,13 @@ _cb_color_changed(void *data, Evas_Object *obj, void *event EINA_UNUSED) double val = 0.0; val = elm_spinner_value_get(obj); - if (val == 1.0) + if (EINA_DBL_CMP(val, 1.0)) elm_bg_color_set(o_bg, 255, 255, 255); - else if (val == 2.0) + else if (EINA_DBL_CMP(val, 2.0)) elm_bg_color_set(o_bg, 255, 0, 0); - else if (val == 3.0) + else if (EINA_DBL_CMP(val, 3.0)) elm_bg_color_set(o_bg, 0, 0, 255); - else if (val == 4.0) + else if (EINA_DBL_CMP(val, 4.0)) elm_bg_color_set(o_bg, 0, 255, 0); }