Silence compiler warning "conversion from 'double' to 'float', possible loss of data"
authorGarrett Brown <garbearucla@gmail.com>
Sun, 9 Jun 2013 22:06:53 +0000 (15:06 -0700)
committerGarrett Brown <garbearucla@gmail.com>
Mon, 10 Jun 2013 18:45:11 +0000 (11:45 -0700)
xbmc/input/touch/generic/GenericTouchSwipeDetector.cpp

index 6685e7f..487affd 100644 (file)
 // maximum time between touch down and up (in nanoseconds)
 #define SWIPE_MAX_TIME            500000000
 // maxmium swipe distance between touch down and up (in multiples of screen DPI)
-#define SWIPE_MIN_DISTANCE        0.5
+#define SWIPE_MIN_DISTANCE        0.5f
 // original maximum variance of the touch movement
-#define SWIPE_MAX_VARIANCE        0.2
+#define SWIPE_MAX_VARIANCE        0.2f
 // tangens of the maximum angle (20 degrees) the touch movement may vary in a
 // direction perpendicular to the swipe direction (in radians)
 // => tan(20 deg) = tan(20 * M_PI / 180)
-#define SWIPE_MAX_VARIANCE_ANGLE  0.363970234266
+#define SWIPE_MAX_VARIANCE_ANGLE  0.36397023f
 
 CGenericTouchSwipeDetector::CGenericTouchSwipeDetector(ITouchActionHandler *handler, float dpi)
   : IGenericTouchGestureDetector(handler, dpi),