mirror of
https://github.com/nicbarker/clay.git
synced 2025-01-23 09:56:03 +00:00
Fix scroll on mouse down being overriden by touch scroll (#42)
This commit is contained in:
parent
05eb12bed7
commit
3b03a79f28
@ -141,7 +141,7 @@ void UpdateDrawFrame(void)
|
||||
//----------------------------------------------------------------------------------
|
||||
// Handle scroll containers
|
||||
Clay_Vector2 mousePosition = RAYLIB_VECTOR2_TO_CLAY_VECTOR2(GetMousePosition());
|
||||
Clay_SetPointerState(mousePosition, IsMouseButtonDown(0));
|
||||
Clay_SetPointerState(mousePosition, IsMouseButtonDown(0) && !scrollbarData.mouseDown);
|
||||
Clay_SetLayoutDimensions((Clay_Dimensions) { (float)GetScreenWidth(), (float)GetScreenHeight() });
|
||||
if (!IsMouseButtonDown(0)) {
|
||||
scrollbarData.mouseDown = false;
|
||||
|
Loading…
Reference in New Issue
Block a user