From 91aedd588828af9b5c44100cd4e3b351b93efe98 Mon Sep 17 00:00:00 2001 From: Ryan Fleury Date: Tue, 8 Oct 2024 15:33:52 -0700 Subject: [PATCH] be a bit less careful with disabled animation delay --- src/ui/ui_core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/ui/ui_core.c b/src/ui/ui_core.c index a438de75..3d4213bf 100644 --- a/src/ui/ui_core.c +++ b/src/ui/ui_core.c @@ -1332,7 +1332,7 @@ ui_end_build(void) // rjf: grab states informing animation B32 is_hot = ui_key_match(box->key, ui_state->hot_box_key); B32 is_active = ui_key_match(box->key, ui_state->active_box_key[UI_MouseButtonKind_Left]); - B32 is_disabled = !!(box->flags & UI_BoxFlag_Disabled) && (box->first_disabled_build_index+10 < ui_state->build_index || + B32 is_disabled = !!(box->flags & UI_BoxFlag_Disabled) && (box->first_disabled_build_index+2 < ui_state->build_index || box->first_touched_build_index == box->first_disabled_build_index); B32 is_focus_hot = !!(box->flags & UI_BoxFlag_FocusHot) && !(box->flags & UI_BoxFlag_FocusHotDisabled); B32 is_focus_active = !!(box->flags & UI_BoxFlag_FocusActive) && !(box->flags & UI_BoxFlag_FocusActiveDisabled);