From c88bb49416aaeb13c3969727a305bc7ed3263963 Mon Sep 17 00:00:00 2001 From: Physick <96335032+DegustatorPonos@users.noreply.github.com> Date: Thu, 3 Sep 2026 19:11:39 +0500 Subject: more transitions --- src/puzzles/puzzle.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src/puzzles/puzzle.h') diff --git a/src/puzzles/puzzle.h b/src/puzzles/puzzle.h index 5af6d6e..b269282 100644 --- a/src/puzzles/puzzle.h +++ b/src/puzzles/puzzle.h @@ -116,6 +116,8 @@ typedef struct CollectionElement { size_t childCount; /// OnClick callback void (*callback)(struct CollectionElement *); + /// The data that will be passed with the callback + void *callbackData; /// If the element is initialized it has children and an icon loaded into mem bool IsInitialized; /// The element has an icon @@ -127,7 +129,7 @@ typedef struct CollectionElement { /// Accepts an element which children will be created and a generic callback that /// will be called when the collection enement is selected. /// The element passes a selected element as a callback argummment -void InitializeCollection(CollectionElement *el, void (*callback)(CollectionElement *)); +void InitializeCollection(CollectionElement *el, void (*callback)(CollectionElement *), void *callbackData); void DrawCollectionElement(CollectionElement *el, CollectionElement *parent, Rectangle rec); void UpdateCollectionElement(CollectionElement *el); void DeinitCollectionElement(CollectionElement *el); -- cgit v1.3