diff options
| author | Ray <raysan5@gmail.com> | 2019-05-20 17:21:46 +0200 |
|---|---|---|
| committer | Ray <raysan5@gmail.com> | 2019-05-20 17:21:46 +0200 |
| commit | 316b6aa1813fb8f5cd56ea135368de73eccc49f6 (patch) | |
| tree | d57db54514aaca4fff00441f3674c434d261ee17 /src | |
| parent | 72ab65277b0050635bfcde0b7ff471358e563659 (diff) | |
| download | raylib-316b6aa1813fb8f5cd56ea135368de73eccc49f6.tar.gz raylib-316b6aa1813fb8f5cd56ea135368de73eccc49f6.zip | |
Reverted change that breaks mouse on web
Diffstat (limited to 'src')
| -rw-r--r-- | src/core.c | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -2163,11 +2163,12 @@ bool IsMouseButtonPressed(int button) if ((currentMouseState[button] != previousMouseState[button]) && (currentMouseState[button] == 1)) pressed = true; #endif +/* #if defined(PLATFORM_WEB) Vector2 pos = GetTouchPosition(0); if ((pos.x > 0) && (pos.y > 0)) pressed = true; // There was a touch! #endif - +*/ return pressed; } @@ -2239,13 +2240,14 @@ Vector2 GetMousePosition(void) #else position = (Vector2){ (mousePosition.x + mouseOffset.x)*mouseScale.x, (mousePosition.y + mouseOffset.y)*mouseScale.y }; #endif +/* #if defined(PLATFORM_WEB) Vector2 pos = GetTouchPosition(0); // Touch position has priority over mouse position if ((pos.x > 0) && (pos.y > 0)) position = pos; // There was a touch! #endif - +*/ return position; } |
