bc23b64315
New Controls/ folder + namespace ytLive.Controls. BottomBar takes the Grid.Row=3 footer: gear menu button (with its GearButton_Click handler moved to the control's code-behind), centered stream-stats (bitrate/FPS/dropped/ duration/health), and the quality dropdown. All bindings inherit the window DataContext; app-level styles resolve from Themes/Controls.xaml as before. Zero behavior change; build 0 warnings; 246 pass, only the 2 known failures. Docs: ViewModels/index.md tracker gains a Phase 2 section in the same commit.
22 lines
521 B
C#
22 lines
521 B
C#
using System.Windows;
|
|
using System.Windows.Controls;
|
|
|
|
namespace ytLive.Controls;
|
|
|
|
public partial class BottomBar : UserControl
|
|
{
|
|
public BottomBar()
|
|
{
|
|
InitializeComponent();
|
|
}
|
|
|
|
private void GearButton_Click(object sender, RoutedEventArgs e)
|
|
{
|
|
if (sender is Button { ContextMenu: { } menu } button)
|
|
{
|
|
menu.PlacementTarget = button;
|
|
menu.Placement = System.Windows.Controls.Primitives.PlacementMode.Bottom;
|
|
menu.IsOpen = true;
|
|
}
|
|
}
|
|
} |