From e0c16136022d9aefcaf20e2a642dfc46382c2633 Mon Sep 17 00:00:00 2001 From: Jaehwan Kim Date: Wed, 15 Jul 2015 16:21:06 +0900 Subject: [PATCH] elm_macro: add cast. It is used by pixel calculation. It should be changed to int. --- legacy/elementary/src/lib/elm_macros.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/legacy/elementary/src/lib/elm_macros.h b/legacy/elementary/src/lib/elm_macros.h index 2f62003efe..c786c68a08 100644 --- a/legacy/elementary/src/lib/elm_macros.h +++ b/legacy/elementary/src/lib/elm_macros.h @@ -1,7 +1,7 @@ /* handy macros */ #define ELM_RECTS_INTERSECT(x, y, w, h, xx, yy, ww, hh) (((x) < ((xx) + (ww))) && ((y) < ((yy) + (hh))) && (((x) + (w)) > (xx)) && (((y) + (h)) > (yy))) #define ELM_PI 3.14159265358979323846 -#define ELM_SCALE_SIZE(x) (((x) / elm_app_base_scale_get()) * elm_config_scale_get()) +#define ELM_SCALE_SIZE(x) (int)(((double)(x) / elm_app_base_scale_get()) * elm_config_scale_get()) // checks if the point(xx, yy) stays out of the rectangle(x, y, w, h) area. #define ELM_RECTS_POINT_OUT(x, y, w, h, xx, yy) (((xx) < (x)) || ((yy) < (y)) || ((xx) > ((x) + (w))) || ((yy) > ((y) + (h))))