diff --git a/clay.h b/clay.h index beff035..3257897 100644 --- a/clay.h +++ b/clay.h @@ -510,11 +510,11 @@ typedef struct { uintptr_t userData; } Clay_ErrorHandler; -CLAY__TYPEDEF(Clay_PointQueryResult, struct +typedef struct { int32_t length; const Clay_ElementId *results; -}); +} Clay_PointQueryResult; // Function Forward Declarations --------------------------------- // Public API functions --- @@ -3206,7 +3206,7 @@ Clay_PointQueryResult Clay_GetElementIdsAtPoint(Clay_Vector2 position) { continue; } context->treeNodeVisited.internalArray[dfsBuffer.length - 1] = true; - Clay_LayoutElement *currentElement = Clay_LayoutElementArray_Get(&context->layoutElements, Clay__int32_tArray_Get(&dfsBuffer, (int)dfsBuffer.length - 1)); + Clay_LayoutElement *currentElement = Clay_LayoutElementArray_Get(&context->layoutElements, Clay__int32_tArray_GetValue(&dfsBuffer, (int)dfsBuffer.length - 1)); Clay_LayoutElementHashMapItem *mapItem = Clay__GetHashMapItem(currentElement->id); // TODO think of a way around this, maybe the fact that it's essentially a binary tree limits the cost, but the worst case is not great Clay_BoundingBox elementBox = mapItem->boundingBox; elementBox.x -= root->pointerOffset.x;