refactor: modal-gate helper + data-driven colormap table
Two extensibility easy-wins, both behavior-preserving: - UiModalOpen() centralizes the "an overlay owns input" check that was copy-pasted as `!showFileBrowser && !showAbout` across 6 input gates. New overlays now update one place. - Colormaps become a COLORMAPS[] table (name + function) indexed by enum. GetColormapColor and the sidebar both read it, so adding a colormap is one enum value + one Cmap* fn + one row — and the sidebar name can no longer drift from the enum (deleted the parallel colormapNames[] array). Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
@@ -11,6 +11,7 @@ float MeasureTextScaled(const char* text, float baseSize);
|
||||
|
||||
// --- Colormaps ---
|
||||
void GenerateColormapTexture(void);
|
||||
const char* ColormapName(ColormapType type);
|
||||
|
||||
// --- Spectrogram texture ---
|
||||
// GenerateSpectrogramTexture recomputes the synchrosqueezed reassignment (use
|
||||
|
||||
Reference in New Issue
Block a user