Skip to content

Refresh waveform context menu after UI language changes#12232

Merged
niksedk merged 1 commit into
SubtitleEdit:mainfrom
pdjdev:fix/waveform-context-menu-language-refresh
Jul 7, 2026
Merged

Refresh waveform context menu after UI language changes#12232
niksedk merged 1 commit into
SubtitleEdit:mainfrom
pdjdev:fix/waveform-context-menu-language-refresh

Conversation

@pdjdev

@pdjdev pdjdev commented Jul 6, 2026

Copy link
Copy Markdown
Contributor

Problem

After changing the UI language via Options > Choose UI Language..., most controls were updated immediately, but the waveform context menu continued to use the previous language.

The updated menu text only appeared after closing and restarting Subtitle Edit.

Cause & Fix

The AudioVisualizer control is reused when the main layout is rebuilt. However, its context menu was created inside the vm.AudioVisualizer == null block, so the menu labels were only initialized when the control was first created.

The fix rebuilds the waveform context menu whenever the layout is rebuilt. The existing AudioVisualizer instance and its event subscriptions are preserved; only the context menu and accessible name are refreshed using the current UI language.

Screenshots

Before After
The context menu remains in the previous language The context menu updates immediately after changing the UI language
2026-07-0700-27-13-ezgif.com-mute-video.mp4
2026-07-0700-27-13-ezgif.com-mute-video.1.mp4

Testing

Tested on Windows 11 x64 (local Release build).

@niksedk niksedk merged commit d80d1e6 into SubtitleEdit:main Jul 7, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants