Files
ReLibreHardwareMonitor/LibreHardwareMonitor.Windows.WinUI/MainWindow.xaml
T
JMR-devandCopilot fa1b16a8f3 Move status text and loading overlay to MainWindow.xaml (Phase 5b step 2)
Express the status TextBlock and full loading overlay (ProgressRing + label) declaratively with x:Bind to ViewModel.StatusText and ViewModel.HardwareLoadingVisibility. Delete the imperative StatusHost population and BuildLoadingOverlay helper.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-06-02 13:25:55 -05:00

47 lines
2.1 KiB
XML

<!-- This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0.
If a copy of the MPL was not distributed with this file, You can obtain one at http://mozilla.org/MPL/2.0/.
Copyright (C) LibreHardwareMonitor and Contributors. -->
<Window
x:Class="LibreHardwareMonitor.Windows.WinUI.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="using:LibreHardwareMonitor.Windows.WinUI">
<Grid x:Name="RootGrid">
<Grid.RowDefinitions>
<RowDefinition Height="Auto" />
<RowDefinition Height="*" />
<RowDefinition Height="Auto" />
</Grid.RowDefinitions>
<Grid x:Name="MenuHost" Grid.Row="0" />
<Grid x:Name="ContentGrid" Grid.Row="1">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*" />
<ColumnDefinition Width="320" />
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="*" />
<RowDefinition Height="220" />
</Grid.RowDefinitions>
</Grid>
<TextBlock x:Name="StatusText"
Grid.Row="2"
Padding="8,4,8,4"
TextTrimming="CharacterEllipsis"
Text="{x:Bind ViewModel.StatusText, Mode=OneWay}" />
<Grid x:Name="OverlayHost"
Grid.RowSpan="3"
IsHitTestVisible="True"
Visibility="{x:Bind ViewModel.HardwareLoadingVisibility, Mode=OneWay}">
<Grid.Background>
<SolidColorBrush Color="#80808080" />
</Grid.Background>
<StackPanel HorizontalAlignment="Center" VerticalAlignment="Center" Spacing="12">
<ProgressRing Width="64" Height="64" IsIndeterminate="True" />
<TextBlock Text="Loading hardware devices..."
FontWeight="SemiBold"
HorizontalAlignment="Center" />
</StackPanel>
</Grid>
</Grid>
</Window>