From 16689c0a807945c19257584c1544c30cc64b7f48 Mon Sep 17 00:00:00 2001 From: gramps Date: Fri, 30 Oct 2026 13:19:58 -0700 Subject: [PATCH] feat(dock): the dock is now the only audio surface (unit 10, final) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Deletes the preview's live-controls strip — mic meter + speaker + volume, the game-audio chip, the TRAX button and the lip-sync slider — and the three code-behind handlers that served it. One sound surface instead of two: the same gains in two places was the original duplication, and two places to set a gain is how a creator ends up with a meter that disagrees with what they hear. ~16.7 KB of XAML and 60 lines of event code gone. Verified: the preview still loads and its interactions still work (selected-layer hit testing, the socials preview, the brand-logo preview), plus the theme's resource guard. --- Controls/PreviewPane.xaml | 161 +---------------------------------- Controls/PreviewPane.xaml.cs | 18 ---- 2 files changed, 3 insertions(+), 176 deletions(-) diff --git a/Controls/PreviewPane.xaml b/Controls/PreviewPane.xaml index c16bde8..5399101 100644 --- a/Controls/PreviewPane.xaml +++ b/Controls/PreviewPane.xaml @@ -963,164 +963,9 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + diff --git a/Controls/PreviewPane.xaml.cs b/Controls/PreviewPane.xaml.cs index 1e0dc94..97ad74e 100644 --- a/Controls/PreviewPane.xaml.cs +++ b/Controls/PreviewPane.xaml.cs @@ -208,13 +208,6 @@ public partial class PreviewPane : UserControl return null; } - private void MicSpeaker_MouseLeftButtonUp(object sender, MouseButtonEventArgs e) - { - if (sender is FrameworkElement { DataContext: MainViewModel vm }) - { - vm.ToggleMicMuteCommand.Execute(null); - } - } private void GameSpeaker_MouseLeftButtonUp(object sender, MouseButtonEventArgs e) { @@ -227,18 +220,7 @@ public partial class PreviewPane : UserControl // TRAX (TASK 9): left-click toggles play/pause (picks a track when none is // loaded); right-click always opens the picker. The picker is the OS file // dialog — the "never the OS viewer" rule covers the preview, not pickers. - private void TraxButton_Click(object sender, RoutedEventArgs e) - { - if (DataContext is ViewModels.MainViewModel vm) - vm.TraxLeftClick(); - } - private void TraxButton_PreviewMouseRightButtonUp(object sender, MouseButtonEventArgs e) - { - if (DataContext is ViewModels.MainViewModel vm) - vm.TraxRightClick(); - e.Handled = true; // the button's right-click context menu must not fire - } // ─── Webcam / background context menus (right-click on overlay elements) ─── private void WebcamMenu_ChangeWebcam(object sender, RoutedEventArgs e)