From e64f8a1f09b4f222d2c15eec1220b6efb5ed7342 Mon Sep 17 00:00:00 2001 From: Daniel Juyung Seo Date: Sun, 23 Mar 2014 17:57:08 +0900 Subject: [PATCH] macros: Fixed wrong ELM_RECTS_INCLUDE logic. --- src/lib/elm_macros.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib/elm_macros.h b/src/lib/elm_macros.h index 4656a89..c25e956 100644 --- a/src/lib/elm_macros.h +++ b/src/lib/elm_macros.h @@ -6,4 +6,4 @@ #define ELM_RECTS_POINT_OUT(x, y, w, h, xx, yy) (((xx) < (x)) || ((yy) < (y)) || ((xx) > ((x) + (w))) || ((yy) > ((y) + (h)))) // check if the rect (x, y, w, h) includes whole body of rect (xx, yy, ww, hh) -#define ELM_RECTS_INCLUDE(x, y, w, h, xx, yy, ww, hh) (((x) <= (xx)) && (((x) + (w)) >= (xx)) && ((y) <= (yy)) && (((y) + (h)) >= (yy))) +#define ELM_RECTS_INCLUDE(x, y, w, h, xx, yy, ww, hh) (((x) <= (xx)) && (((x) + (w)) >= ((xx + (ww))) && ((y) <= (yy)) && (((y) + (h)) >= ((yy) + (hh))))) -- 2.7.4