diff options
| author | Adam Malczewski <[email protected]> | 2026-06-29 13:36:35 +0900 |
|---|---|---|
| committer | Adam Malczewski <[email protected]> | 2026-06-29 13:36:35 +0900 |
| commit | 5a54b683fa077b8a557ce3bd5745f3007579db07 (patch) | |
| tree | 71c9af9c22e478c6824862724966dd3a4afff8e1 /src/ui.c | |
| parent | 7f0444bc308fef0b78b2fd4fa8aa269da619324c (diff) | |
| download | study-player-dev.tar.gz study-player-dev.zip | |
docs: P8 vocabulary governance + WSL run tribal knowledgedev
- AGENTS.md §4 'Naming & vocabulary': wire to GLOSSARY.md (P8 — never coin a
synonym for an existing concept; propose new terms, don't coin silently).
- AGENTS.md §8 'Tribal knowledge (notes/)': establish notes/<topic>.md as the
non-inferable-knowledge store with the P6 test.
- Rename study_segment_seek_target -> study_portion_seek_target ('segment' was
a glossary-proscribed synonym for 'speaking portion'); fix 'Section nav' /
'jump to start' comments to canonical terms (portion nav / seek).
- notes/wsl-arch-razer-run.md: how to run the desktop app under WSLg on the
Arch/Razer dev machine (the LIBGL_ALWAYS_INDIRECT segfault trap, required
env vars, GPU driver options).
Diffstat (limited to 'src/ui.c')
| -rw-r--r-- | src/ui.c | 16 |
1 files changed, 8 insertions, 8 deletions
@@ -136,7 +136,7 @@ void ui_handle_input(UIState *ui, PlayerState *state, const UILayout *layout) player_play(state); } - /* --- Section nav buttons --- */ + /* --- Portion nav buttons --- */ { float progress = (state->duration > 0.0f) ? state->currentTime / state->duration : 0.0f; int portion = study_current_speaking_portion(state, progress) + 1; @@ -154,7 +154,7 @@ void ui_handle_input(UIState *ui, PlayerState *state, const UILayout *layout) bool inSil = (study_find_silence_at(state, pos) >= 0); bool inPad = study_in_padding_zone(state, pos, p); if ((inSil || inPad) && p > 0) p--; - float target = study_segment_seek_target(state, p); + float target = study_portion_seek_target(state, p); player_seek(state, target); state->wasInSilence = false; state->lastSilenceIdx = -1; @@ -164,7 +164,7 @@ void ui_handle_input(UIState *ui, PlayerState *state, const UILayout *layout) float pos = state->currentTime / state->duration; int p = study_current_speaking_portion(state, pos); if (p < total - 1) p++; - float target = study_segment_seek_target(state, p); + float target = study_portion_seek_target(state, p); player_seek(state, target); state->wasInSilence = false; state->lastSilenceIdx = -1; @@ -207,7 +207,7 @@ void ui_handle_input(UIState *ui, PlayerState *state, const UILayout *layout) { float pos = state->currentTime / state->duration; int portion = study_current_speaking_portion(state, pos); - float target = study_segment_seek_target(state, portion); + float target = study_portion_seek_target(state, portion); player_seek(state, target); player_play(state); } @@ -223,7 +223,7 @@ void ui_handle_input(UIState *ui, PlayerState *state, const UILayout *layout) bool inPad = study_in_padding_zone(state, pos, portion); if ((inSil || inPad) && portion > 0) portion--; - float target = study_segment_seek_target(state, portion); + float target = study_portion_seek_target(state, portion); player_seek(state, target); state->wasInSilence = false; state->lastSilenceIdx = -1; @@ -235,7 +235,7 @@ void ui_handle_input(UIState *ui, PlayerState *state, const UILayout *layout) int portion = study_current_speaking_portion(state, pos); int total = study_total_speaking_portions(state); if (portion < total - 1) portion++; - float target = study_segment_seek_target(state, portion); + float target = study_portion_seek_target(state, portion); player_seek(state, target); state->wasInSilence = false; state->lastSilenceIdx = -1; @@ -378,7 +378,7 @@ void ui_render_player(const UIState *ui, const PlayerState *state, else draw_play_icon(ppx, layout->btnY, 50, ui->textColor); - /* Speaking portion counter with prev/next section buttons */ + /* Speaking portion counter with prev/next portion buttons */ { int portion = study_current_speaking_portion(state, progress) + 1; int total = study_total_speaking_portions(state); @@ -394,7 +394,7 @@ void ui_render_player(const UIState *ui, const PlayerState *state, (Vector2){ portionX, portionY }, ui->szSmall, portionSpacing, ui->mutedColor); - /* Section nav buttons */ + /* Portion nav buttons */ float secPrevX = layout->secNavX - 65.0f; float secNextX = layout->secNavX + 65.0f; float secBtnY_draw = layout->secNavY; |
