From 4a10f33a6d5044480712cf56f3bcfd10cd1f2acb Mon Sep 17 00:00:00 2001 From: rexim Date: Wed, 28 Feb 2024 23:31:55 +0700 Subject: [PATCH] Toolbar: take into account microphone button in "narrow mode" --- src/plug.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/plug.c b/src/plug.c index 71329e8..d6ea11f 100644 --- a/src/plug.c +++ b/src/plug.c @@ -1304,7 +1304,13 @@ static bool toolbar(Track *track, Rectangle boundary) bool interacted = false; int state = 0; - if (boundary.width < HUD_BUTTON_SIZE*4) return interacted; +#ifdef MUSIALIZER_MICROPHONE + size_t buttons_count = 5; +#else + size_t buttons_count = 4; +#endif // MUSIALIZER_MICROPHONE + + if (boundary.width < HUD_BUTTON_SIZE*buttons_count) return interacted; DrawRectangleRec(boundary, COLOR_TRACK_PANEL_BACKGROUND);