From 6af9999aa64bea78e4d4a8e5522a6148563f3fdb Mon Sep 17 00:00:00 2001 From: Kees Bakker Date: Thu, 27 Oct 2011 22:53:28 +0200 Subject: [PATCH] Correct usage of SDL_AddDollarGesture (return value >= 0 on success) --- src/events/SDL_gesture.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/events/SDL_gesture.c b/src/events/SDL_gesture.c index 92e6c6de9..a30615227 100644 --- a/src/events/SDL_gesture.c +++ b/src/events/SDL_gesture.c @@ -227,7 +227,8 @@ int SDL_LoadDollarTemplates(SDL_TouchID touchId, SDL_RWops *src) if (touchId >= 0) { //printf("Adding loaded gesture to 1 touch\n"); - if (SDL_AddDollarGesture(touch,templ.path)) loaded++; + if (SDL_AddDollarGesture(touch, templ.path) >= 0) + loaded++; } else { //printf("Adding to: %i touches\n",SDL_numGestureTouches);