|
@ -2163,11 +2163,12 @@ bool IsMouseButtonPressed(int button) |
|
|
if ((currentMouseState[button] != previousMouseState[button]) && (currentMouseState[button] == 1)) pressed = true; |
|
|
if ((currentMouseState[button] != previousMouseState[button]) && (currentMouseState[button] == 1)) pressed = true; |
|
|
#endif |
|
|
#endif |
|
|
|
|
|
|
|
|
|
|
|
/* |
|
|
#if defined(PLATFORM_WEB) |
|
|
#if defined(PLATFORM_WEB) |
|
|
Vector2 pos = GetTouchPosition(0); |
|
|
Vector2 pos = GetTouchPosition(0); |
|
|
if ((pos.x > 0) && (pos.y > 0)) pressed = true; // There was a touch! |
|
|
if ((pos.x > 0) && (pos.y > 0)) pressed = true; // There was a touch! |
|
|
#endif |
|
|
#endif |
|
|
|
|
|
|
|
|
|
|
|
*/ |
|
|
return pressed; |
|
|
return pressed; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
@ -2239,13 +2240,14 @@ Vector2 GetMousePosition(void) |
|
|
#else |
|
|
#else |
|
|
position = (Vector2){ (mousePosition.x + mouseOffset.x)*mouseScale.x, (mousePosition.y + mouseOffset.y)*mouseScale.y }; |
|
|
position = (Vector2){ (mousePosition.x + mouseOffset.x)*mouseScale.x, (mousePosition.y + mouseOffset.y)*mouseScale.y }; |
|
|
#endif |
|
|
#endif |
|
|
|
|
|
/* |
|
|
#if defined(PLATFORM_WEB) |
|
|
#if defined(PLATFORM_WEB) |
|
|
Vector2 pos = GetTouchPosition(0); |
|
|
Vector2 pos = GetTouchPosition(0); |
|
|
|
|
|
|
|
|
// Touch position has priority over mouse position |
|
|
// Touch position has priority over mouse position |
|
|
if ((pos.x > 0) && (pos.y > 0)) position = pos; // There was a touch! |
|
|
if ((pos.x > 0) && (pos.y > 0)) position = pos; // There was a touch! |
|
|
#endif |
|
|
#endif |
|
|
|
|
|
|
|
|
|
|
|
*/ |
|
|
return position; |
|
|
return position; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|