Unbreak TOUCH_JOY_LOG() macro

This commit is contained in:
Aaron Culliney 2016-01-24 10:08:44 -08:00
parent 1358a52eee
commit 661b4220ef

View File

@ -619,7 +619,7 @@ static inline void _reset_model_position(GLModel *model, float touchX, float tou
} }
} }
static inline void _axis_touch_down(int x, int y) { static inline void _axis_touch_down(interface_touch_event_t action, int x, int y) {
axes.centerX = x; axes.centerX = x;
axes.centerY = y; axes.centerY = y;
@ -630,7 +630,7 @@ static inline void _axis_touch_down(int x, int y) {
variant.curr->axisDown(); variant.curr->axisDown();
} }
static inline void _button_touch_down(int x, int y) { static inline void _button_touch_down(interface_touch_event_t action, int x, int y) {
buttons.centerX = x; buttons.centerX = x;
buttons.centerY = y; buttons.centerY = y;
@ -666,7 +666,7 @@ static inline void _button_move(int x, int y) {
variant.curr->buttonMove(x, y); variant.curr->buttonMove(x, y);
} }
static inline void _axis_touch_up(int x, int y) { static inline void _axis_touch_up(interface_touch_event_t action, int x, int y) {
#if DEBUG_TOUCH_JOY #if DEBUG_TOUCH_JOY
bool resetIndex = false; bool resetIndex = false;
if (buttons.trackingIndex > axes.trackingIndex) { if (buttons.trackingIndex > axes.trackingIndex) {
@ -686,7 +686,7 @@ static inline void _axis_touch_up(int x, int y) {
axes.azimuthModelDirty = false; axes.azimuthModelDirty = false;
} }
static inline void _button_touch_up(int x, int y) { static inline void _button_touch_up(interface_touch_event_t action, int x, int y) {
#if DEBUG_TOUCH_JOY #if DEBUG_TOUCH_JOY
bool resetIndex = false; bool resetIndex = false;
if (axes.trackingIndex > buttons.trackingIndex) { if (axes.trackingIndex > buttons.trackingIndex) {
@ -737,7 +737,7 @@ static int64_t gltouchjoy_onTouchEvent(interface_touch_event_t action, int point
} else { } else {
axisConsumed = true; axisConsumed = true;
axes.trackingIndex = pointer_idx; axes.trackingIndex = pointer_idx;
_axis_touch_down(x, y); _axis_touch_down(action, x, y);
} }
} else { } else {
if (pointer_idx == axes.trackingIndex) { if (pointer_idx == axes.trackingIndex) {
@ -749,7 +749,7 @@ static int64_t gltouchjoy_onTouchEvent(interface_touch_event_t action, int point
} else { } else {
buttonConsumed = true; buttonConsumed = true;
buttons.trackingIndex = pointer_idx; buttons.trackingIndex = pointer_idx;
_button_touch_down(x, y); _button_touch_down(action, x, y);
} }
} }
} }
@ -777,11 +777,11 @@ static int64_t gltouchjoy_onTouchEvent(interface_touch_event_t action, int point
if (pointer_idx == axes.trackingIndex) { if (pointer_idx == axes.trackingIndex) {
int x = (int)x_coords[axes.trackingIndex]; int x = (int)x_coords[axes.trackingIndex];
int y = (int)y_coords[axes.trackingIndex]; int y = (int)y_coords[axes.trackingIndex];
_axis_touch_up(x, y); _axis_touch_up(action, x, y);
} else if (pointer_idx == buttons.trackingIndex) { } else if (pointer_idx == buttons.trackingIndex) {
int x = (int)x_coords[buttons.trackingIndex]; int x = (int)x_coords[buttons.trackingIndex];
int y = (int)y_coords[buttons.trackingIndex]; int y = (int)y_coords[buttons.trackingIndex];
_button_touch_up(x, y); _button_touch_up(action, x, y);
} else { } else {
if (pointer_count == 1) { if (pointer_count == 1) {
TOUCH_JOY_LOG("!!! : RESETTING TOUCH JOYSTICK STATE MACHINE"); TOUCH_JOY_LOG("!!! : RESETTING TOUCH JOYSTICK STATE MACHINE");