Files
ThreadPilot/MainWindow.xaml
T
Prime Build 9a4baba19a feat: release 1.7.7 stable without experimental Game Boost
* feat: back up persistent rules and resolve rule precedence deterministically

- Configuration export now includes persistent process rules (schema 3.0),
  stays compatible with 2.0 bundles, validates before writing, previews
  what an import replaces and rolls back on failure.
- Matching rules apply broad-to-specific (name, wildcard path, exact path,
  then most recently edited), shared by the engine and the process summary,
  which now lists the apply order and flags conflicting values.
- Localized the new strings in all seven languages.

* feat: clearer process and rule editors

- Process details: CPU, memory and I/O priority pickers with an explicit
  Apply, undo of the last manual priority change (guarded against reused
  PIDs), adaptive side/bottom details panel.
- Manual process control stays available while automation is paused, with
  a persistent notice instead of an overlay.
- Saved-rule editor stages all edits (including the core mask) and saves
  them together, showing pending changes.
- Localized the new strings in all seven languages.

* fix: one save path for a saved rule's cores

The rules editor's core mask went through a new update path that reported
success without saving when no affinity payload was built, and kept a
legacy mask next to a CPU selection. Merge it with the old single-purpose
method (now unused), keep its checks, and localize the undo message.

* feat: per-process efficiency mode (EcoQoS) for live processes and rules

Closes #66.

- Native: SetProcessInformation/GetProcessInformation with
  ProcessPowerThrottling (EXECUTION_SPEED), three states: Windows decides,
  On (EcoQoS), Off (never throttle / HighQoS).
- Process tab: context menu entries, a picker with Apply in the details
  panel, current state in the summary, undo of the last change, included
  when saving current settings as a rule (only if explicitly set).
- Rules: EfficiencyMode + ApplyEfficiencyModeOnStart, applied by the rules
  engine, editable in the saved-rule editor, validated on import and part
  of conflict detection.
- The summary flags when the global Power Throttling tweak voids it. CPU
  priority is left alone, unlike Task Manager's efficiency mode.
- Localized in all seven languages.

* chore: keep CRLF line endings in SelectedProcessSummaryViewModel

* feat: clearer navigation, process page and rules editor

- Navigation pane open with short labels instead of seven bare icons.
- Processes: one toolbar row (search with placeholder, Filters and
  Columns menus, sort, refresh); details split into Process, Priority,
  CPU cores and Rule cards; pickers start from the process's current
  values and stay empty when a value cannot be read; help paragraphs
  moved into tooltips; core picker always visible.
- Rules: process rules first, clearer tab names, localized choices in the
  saved-rule editor instead of internal enum names.
- Shorter page titles and subtitles in all seven languages; removed the
  strings this made unused.

No data format changes.

* feat: settings and tweaks as Windows 11 rows, localized rule list

- Settings: one column of rows (what it is on the left, its switch on the
  right), most used sections first, Save as the primary action.
- Tweaks: one tweak per row with its status dot and switch.
- Rule list: 'Applies' and 'Mode' columns use the same localized labels as
  the editor and refresh on language change.
- Removed 76 strings no code referenced, from all seven languages.

* fix: issues found testing the beta in a clean Windows 11 VM

- Process counter could show more visible processes than the total
  ('157 / 151'): the batch total was a snapshot from the first load.
- Narrow windows (or 150% scaling): toolbar buttons move under the search
  box instead of squeezing it to a few letters.
- Rules list keeps the 'Applies' column readable when narrow.
- Settings status message gets its own line instead of being cut.

Tested in a Hyper-V Windows 11 VM: clean install, upgrade, uninstall,
light and dark theme, 100% and 150% scaling.

* feat: remember layout choices; Windows 11 toggles in Tweaks

- The navigation pane, window size/position/maximized state, and the
  process list filters, sort and columns now survive a restart. They live
  in ui-state.json, apart from settings.json, so they never mark the
  Settings page as unsaved or travel in exported configurations. A corrupt
  file falls back to defaults; tests write to a temp file.
- Fixes the pane re-opening on every start (it was hard-coded open).
- Tweaks use a native-looking Windows 11 switch (40x20 track, sliding
  thumb) with On/Off written beside it.
- New test: every on/off setting survives save and reload.

* docs: handoff for the 1.7.7 PR stack and beta test

* fix: P/E cores from the highest EfficiencyClass, AMD CCDs from real L3 groups

The legacy topology treated the lowest EfficiencyClass as the performance
core, swapping P- and E-cores on hybrid Intel CPUs. AMD CCDs were guessed
as 8 cores each, which split 6+6 parts (7900X3D, 9900X3D) into 8+4; they now
come from the L3 groups Windows reports, with the guess kept only as a
fallback. The topology snapshot also keeps each L3 group's size.

* feat: Game Boost, CPU Sets for the game and selected background apps

While a detected game runs, Game Boost sets process default CPU Sets from
the CPU topology: on AMD X3D with one larger L3 the game goes to the V-Cache
CCD, on Intel hybrid CPUs to the P-cores, and selected background apps
(browsers, sync clients, updaters, launchers) to the other cores. On dual-CCD
parts with equal L3 only the background moves, unless Isolation mode also
keeps the game on CCD0. Single-L3 and unreadable topologies are left to
Windows. Above Normal priority for the game is optional; never High.

Each change is written to a journal before it is made and undone when the
game exits, Game Boost is turned off or ThreadPilot closes, and on the next
start after a crash. Only values still exactly as Game Boost set them are
restored, never one a user rule or a manual change has taken over since.
Persistent rules and Game Boost share one apply gate, and a rule always
wins over Game Boost for the setting it covers.

The switch, mode and lists are on the Tweaks page, off by default, and take
effect without a restart.

* fix: Game Boost background entries with a full path never matched

The background list compared full-path entries against an empty path, so
only bare process names worked. Found by a new integration test that runs
the real services on two copies of PING.EXE: CPU Sets and priority are set
and read back through Windows, removed when Game Boost is turned off, and
undone from the journal after a simulated crash. The topology is simulated
from this machine's CPU Set IDs, so the test also runs on CPUs where Game
Boost would not act; it skips itself below 8 cores.

* feat: report Game Boost sessions and restore results in Activity

* test: diagnose EcoQoS read failures on Windows Server

* chore: prepare 1.7.7-beta.2 and keep prereleases out of stable channels

* test: use native full-query access mask in EcoQoS diagnostic

* docs: update beta handoff and prerelease publication policy

* ci: run native EcoQoS tests on a Windows 11-era kernel

Windows Server 2022 build 20348 rejects GetProcessInformation(ProcessPowerThrottling) with ERROR_INVALID_PARAMETER (87), with both limited and full query handles. Windows 11 local tests pass. Use Server 2025 for CI/release tests and smoke testing; keep the real round-trip assertions, remove temporary probes.

* test: lock beta publication and native runner contracts

* chore: separate stable 1.7.7 from experimental Game Boost

Stable retains the validated EcoQoS/rules/UI stack. Preserve the complete local Game Boost implementation at ef2ec24 for the separate 1.7.8-beta.1 prerelease; no experimental Game Boost/topology changes ship in stable. Keep channel-aware publication and Windows 11-era native CI tests.
2026-10-16 12:03:54 +02:00

592 lines
34 KiB
XML

<ui:FluentWindow x:Class="ThreadPilot.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:local="clr-namespace:ThreadPilot"
xmlns:views="clr-namespace:ThreadPilot.Views"
xmlns:viewModels="clr-namespace:ThreadPilot.ViewModels"
xmlns:ui="http://schemas.lepo.co/wpfui/2022/xaml"
mc:Ignorable="d"
ExtendsContentIntoTitleBar="True"
WindowBackdropType="Mica"
Title="{DynamicResource MainWindow_Title}"
Height="864"
Width="1280"
WindowStartupLocation="CenterScreen"
UseLayoutRounding="True"
SnapsToDevicePixels="True"
KeyboardNavigation.TabNavigation="Cycle"
KeyboardNavigation.ControlTabNavigation="Cycle">
<ui:FluentWindow.Resources>
<!-- Loading Spinner Animation -->
<Storyboard x:Key="SpinnerAnimation" RepeatBehavior="Forever">
<DoubleAnimation Storyboard.TargetName="SpinnerRotation"
Storyboard.TargetProperty="Angle"
From="0" To="360" Duration="0:0:1"/>
</Storyboard>
<!-- Fade In Animation -->
<Storyboard x:Key="FadeInAnimation">
<DoubleAnimation Storyboard.TargetName="LoadingOverlay"
Storyboard.TargetProperty="Opacity"
From="0" To="1" Duration="0:0:0.2"/>
</Storyboard>
<!-- Fade Out Animation -->
<Storyboard x:Key="FadeOutAnimation">
<DoubleAnimation Storyboard.TargetName="LoadingOverlay"
Storyboard.TargetProperty="Opacity"
From="1" To="0" Duration="0:0:0.3"/>
</Storyboard>
</ui:FluentWindow.Resources>
<Grid>
<Grid x:Name="UIContent">
<Grid.Style>
<Style TargetType="Grid">
<Style.Triggers>
<DataTrigger Binding="{Binding ElementName=PerformanceIntroOverlay, Path=Visibility}" Value="Visible">
<Setter Property="IsHitTestVisible" Value="False"/>
<Setter Property="Effect">
<Setter.Value>
<BlurEffect Radius="8" KernelType="Gaussian"/>
</Setter.Value>
</Setter>
</DataTrigger>
<DataTrigger Binding="{Binding ElementName=UnsavedSettingsOverlay, Path=Visibility}" Value="Visible">
<Setter Property="IsHitTestVisible" Value="False"/>
<Setter Property="Effect">
<Setter.Value>
<BlurEffect Radius="8" KernelType="Gaussian"/>
</Setter.Value>
</Setter>
</DataTrigger>
</Style.Triggers>
</Style>
</Grid.Style>
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="*"/>
<RowDefinition Height="Auto"/>
</Grid.RowDefinitions>
<ui:TitleBar Grid.Row="0" Title="ThreadPilot">
<ui:TitleBar.Icon>
<ui:ImageIcon Source="pack://application:,,,/assets/icons/ico.ico"/>
</ui:TitleBar.Icon>
</ui:TitleBar>
<Grid Grid.Row="1">
<!-- Main Application Content (NavigationView) -->
<ui:NavigationView x:Name="RootNavigation"
PaneDisplayMode="Left"
IsBackButtonVisible="Collapsed"
OpenPaneLength="200"
CompactPaneLength="52"
AutomationProperties.Name="{DynamicResource MainWindow_PrimaryNavigation}">
<ui:NavigationView.Resources>
<Style TargetType="ui:NavigationViewItem">
<Setter Property="Background" Value="Transparent"/>
<Setter Property="BorderThickness" Value="0"/>
<Setter Property="BorderBrush" Value="Transparent"/>
<Setter Property="Margin" Value="0"/>
<Setter Property="Padding" Value="12,4"/>
<Setter Property="MinHeight" Value="36"/>
<Style.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter Property="Background" Value="{DynamicResource QuietRowBackgroundBrush}"/>
</Trigger>
<Trigger Property="IsActive" Value="True">
<Setter Property="Background" Value="{DynamicResource SoftSelectionBackgroundBrush}"/>
<Setter Property="BorderThickness" Value="0"/>
</Trigger>
</Style.Triggers>
</Style>
<!-- Remove default NavigationViewItem horizontal separator lines -->
<Style x:Key="NavigationViewItemSeparator" TargetType="Rectangle">
<Setter Property="Fill" Value="Transparent"/>
<Setter Property="Height" Value="0"/>
<Setter Property="Margin" Value="0"/>
</Style>
</ui:NavigationView.Resources>
<ui:NavigationView.MenuItems>
<ui:NavigationViewItem x:Name="NavProcess" Content="{DynamicResource MainWindow_NavProcess}" Tag="Process" TargetPageTag="Process" Click="NavMenuItem_Click">
<ui:NavigationViewItem.Icon>
<ui:SymbolIcon Symbol="Apps24"/>
</ui:NavigationViewItem.Icon>
</ui:NavigationViewItem>
<ui:NavigationViewItem x:Name="NavMasks" Content="{DynamicResource MainWindow_NavMasks}" Tag="Masks" TargetPageTag="Masks" Click="NavMenuItem_Click">
<ui:NavigationViewItem.Icon>
<ui:SymbolIcon Symbol="BranchFork24"/>
</ui:NavigationViewItem.Icon>
</ui:NavigationViewItem>
<ui:NavigationViewItem x:Name="NavPower" Content="{DynamicResource MainWindow_NavPower}" Tag="Power" TargetPageTag="Power" Click="NavMenuItem_Click">
<ui:NavigationViewItem.Icon>
<ui:SymbolIcon Symbol="Power24"/>
</ui:NavigationViewItem.Icon>
</ui:NavigationViewItem>
<ui:NavigationViewItem x:Name="NavRules" Content="{DynamicResource MainWindow_NavRules}" Tag="Rules" TargetPageTag="Rules" Click="NavMenuItem_Click">
<ui:NavigationViewItem.Icon>
<ui:SymbolIcon Symbol="TasksApp24"/>
</ui:NavigationViewItem.Icon>
</ui:NavigationViewItem>
<ui:NavigationViewItem x:Name="NavPerf" Content="{DynamicResource MainWindow_NavDiagnostics}" Tag="Performance" TargetPageTag="Performance" Click="NavMenuItem_Click">
<ui:NavigationViewItem.Icon>
<ui:SymbolIcon Symbol="DataHistogram24"/>
</ui:NavigationViewItem.Icon>
</ui:NavigationViewItem>
<ui:NavigationViewItem x:Name="NavLogs" Content="{DynamicResource MainWindow_NavActivity}" Tag="Logs" TargetPageTag="Logs" Click="NavMenuItem_Click">
<ui:NavigationViewItem.Icon>
<ui:SymbolIcon Symbol="DocumentText24"/>
</ui:NavigationViewItem.Icon>
</ui:NavigationViewItem>
<ui:NavigationViewItem x:Name="NavTweaks" Content="{DynamicResource MainWindow_NavTweaks}" Tag="Tweaks" TargetPageTag="Tweaks" Click="NavMenuItem_Click">
<ui:NavigationViewItem.Icon>
<ui:SymbolIcon Symbol="Wrench24"/>
</ui:NavigationViewItem.Icon>
</ui:NavigationViewItem>
</ui:NavigationView.MenuItems>
<ui:NavigationView.FooterMenuItems>
<ui:NavigationViewItem x:Name="NavSettings" TargetPageTag="Settings" Content="{DynamicResource MainWindow_NavSettings}" Tag="Settings" Click="NavMenuItem_Click">
<ui:NavigationViewItem.Icon>
<ui:SymbolIcon Symbol="Settings24"/>
</ui:NavigationViewItem.Icon>
</ui:NavigationViewItem>
</ui:NavigationView.FooterMenuItems>
<ui:NavigationView.ContentOverlay>
<Grid x:Name="MainContent" Margin="12,0,12,12">
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<!-- Elevation Warning Modal (Shell Login Style) -->
<Grid x:Name="ElevationWarningOverlay"
Grid.RowSpan="2"
Visibility="Collapsed"
Panel.ZIndex="900"
AutomationProperties.Name="{DynamicResource MainWindow_ElevationWarningOverlay}">
<!-- Blurred Backdrop -->
<Grid x:Name="ElevationWarningBackdrop"
Background="{DynamicResource OverlayBrush}"
IsHitTestVisible="True">
<Grid.Effect>
<BlurEffect x:Name="ElevationWarningBlur" Radius="0"/>
</Grid.Effect>
</Grid>
<!-- Shell Login Popup -->
<Border x:Name="ElevationWarningCard"
Background="{DynamicResource CardSurfaceBrush}"
BorderBrush="{DynamicResource BorderSubtleBrush}"
BorderThickness="1"
CornerRadius="{DynamicResource StandardCardCornerRadius}"
Padding="24"
HorizontalAlignment="Center"
VerticalAlignment="Center"
MinWidth="420"
MaxWidth="560"
IsHitTestVisible="True">
<Border.Effect>
<DropShadowEffect BlurRadius="12" ShadowDepth="0" Opacity="0.18"/>
</Border.Effect>
<StackPanel>
<StackPanel Orientation="Horizontal" Margin="0,0,0,16">
<TextBlock Text="⚠️"
FontSize="28"
VerticalAlignment="Center"
Margin="0,0,12,0"/>
<TextBlock Text="{DynamicResource MainWindow_ElevationWarningTitle}"
FontSize="22"
FontWeight="SemiBold"
Foreground="{DynamicResource TextFillColorPrimaryBrush}"
VerticalAlignment="Center"
TextWrapping="Wrap"/>
</StackPanel>
<TextBlock Text="{DynamicResource MainWindow_ElevationWarningDescription}"
TextWrapping="Wrap"
Margin="0,0,0,12"
FontSize="14"
Foreground="{DynamicResource TextFillColorPrimaryBrush}"/>
<TextBlock Text="{DynamicResource MainWindow_ElevationWarningRequired}"
FontWeight="SemiBold"
Margin="0,0,0,8"
Foreground="{DynamicResource TextFillColorSecondaryBrush}"/>
<StackPanel Margin="20,0,0,0">
<TextBlock Text="{DynamicResource MainWindow_ElevationWarningPowerPlans}"
TextWrapping="Wrap"
Margin="0,0,0,4"
Foreground="{DynamicResource TextFillColorSecondaryBrush}"/>
<TextBlock Text="{DynamicResource MainWindow_ElevationWarningAffinity}"
TextWrapping="Wrap"
Margin="0,0,0,4"
Foreground="{DynamicResource TextFillColorSecondaryBrush}"/>
<TextBlock Text="{DynamicResource MainWindow_ElevationWarningTweaks}"
TextWrapping="Wrap"
Margin="0,0,0,4"
Foreground="{DynamicResource TextFillColorSecondaryBrush}"/>
<TextBlock Text="{DynamicResource MainWindow_ElevationWarningProtected}"
TextWrapping="Wrap"
Margin="0,0,0,16"
Foreground="{DynamicResource TextFillColorSecondaryBrush}"/>
</StackPanel>
<StackPanel Orientation="Horizontal" HorizontalAlignment="Right">
<Button Content="{DynamicResource MainWindow_ContinueWithoutElevation}"
Click="ElevationWarningDismiss_Click"
Margin="0,0,12,0"
Background="{DynamicResource ControlFillColorDefaultBrush}"
Foreground="{DynamicResource TextFillColorPrimaryBrush}"
Padding="16,8"/>
<Button Content="{DynamicResource MainWindow_RequestElevation}"
Command="{Binding RequestElevationCommand}"
Click="ElevationWarningRequestElevation_Click"
Background="{DynamicResource ControlFillColorTertiaryBrush}"
Foreground="{DynamicResource TextFillColorPrimaryBrush}"
Padding="16,8"/>
</StackPanel>
</StackPanel>
</Border>
</Grid>
<!-- Hosted Views toggled natively to retain ViewModel mapping -->
<Grid Grid.Row="1">
<views:ProcessView x:Name="ProcessManagementTab" Visibility="Visible"/>
<views:MasksView x:Name="CoreMasksTab" Visibility="Collapsed"/>
<views:PowerPlanView x:Name="PowerPlanViewControl" Visibility="Collapsed"/>
<views:ProcessPowerPlanAssociationView x:Name="AssociationView" Visibility="Collapsed"/>
<views:PerformanceView x:Name="PerformanceViewControl" Visibility="Collapsed"/>
<views:LogViewerView x:Name="LogViewerViewControl" Visibility="Collapsed"/>
<views:SystemTweaksView x:Name="SystemTweaksView" Visibility="Collapsed"/>
<views:SettingsView x:Name="SettingsView" Visibility="Collapsed"/>
</Grid>
</Grid>
</ui:NavigationView.ContentOverlay>
</ui:NavigationView>
</Grid>
<!-- Status Bar -->
<Border Grid.Row="2" Background="{DynamicResource SolidBackgroundFillColorBaseBrush}" BorderThickness="0,1,0,0" BorderBrush="{DynamicResource BorderSubtleBrush}" Padding="12,4">
<Border.Resources>
<Style TargetType="TextBlock">
<Setter Property="FontFamily" Value="{DynamicResource AppFontFamily}"/>
<Setter Property="FontSize" Value="12"/>
</Style>
</Border.Resources>
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="Auto"/>
</Grid.ColumnDefinitions>
<TextBlock Grid.Column="0" Text="{Binding StatusMessage}" VerticalAlignment="Center" Opacity="{Binding StatusOpacity}"/>
<StackPanel Grid.Column="1" Orientation="Horizontal" VerticalAlignment="Center">
<TextBlock Text="{Binding ElevationStatusText}"/>
<TextBlock Text="🔒"
Margin="5,0,0,0"
Visibility="{Binding IsRunningAsAdministrator, Converter={StaticResource BoolToVisibilityConverter}}"/>
<TextBlock Text=" • " Margin="8,0,8,0" Opacity="0.7"/>
<TextBlock Text="{Binding ApplicationVersion}" Opacity="0.85"/>
</StackPanel>
</Grid>
</Border>
</Grid>
<Grid x:Name="PopupOverlay"
Panel.ZIndex="950">
<Grid x:Name="PerformanceIntroOverlay"
Visibility="Collapsed"
AutomationProperties.Name="{DynamicResource MainWindow_PerformanceIntroductionOverlay}">
<Border x:Name="PerformanceIntroCard"
Background="{DynamicResource CardSurfaceBrush}"
BorderBrush="{DynamicResource BorderSubtleBrush}"
BorderThickness="1"
CornerRadius="{DynamicResource StandardCardCornerRadius}"
Padding="24"
HorizontalAlignment="Center"
VerticalAlignment="Center"
MinWidth="360"
MaxWidth="560"
Opacity="1">
<Border.Effect>
<DropShadowEffect BlurRadius="12" ShadowDepth="0" Opacity="0.18"/>
</Border.Effect>
<StackPanel>
<TextBlock x:Name="PerformanceIntroTitle"
Text="{DynamicResource PerformanceView_OptionalDiagnostics}"
FontSize="24"
FontWeight="SemiBold"
Foreground="{DynamicResource TextFillColorPrimaryBrush}"
Margin="0,0,0,10"/>
<TextBlock x:Name="PerformanceIntroDescription"
Text="{DynamicResource PerformanceView_DiagnosticsDesc}"
TextWrapping="Wrap"
Margin="0,0,0,10"
Foreground="{DynamicResource TextFillColorSecondaryBrush}"/>
<TextBlock x:Name="PerformanceIntroTipsHeader"
Text="{DynamicResource PerformanceView_QuickTips}"
FontWeight="SemiBold"
Foreground="{DynamicResource TextFillColorPrimaryBrush}"
Margin="0,0,0,6"/>
<TextBlock x:Name="PerformanceIntroTip1"
Text="{DynamicResource PerformanceView_Tip1}"
Foreground="{DynamicResource TextFillColorSecondaryBrush}"
Margin="0,0,0,4"/>
<TextBlock x:Name="PerformanceIntroTip2"
Text="{DynamicResource PerformanceView_Tip2}"
Foreground="{DynamicResource TextFillColorSecondaryBrush}"
Margin="0,0,0,4"/>
<TextBlock x:Name="PerformanceIntroTip3"
Text="{DynamicResource PerformanceView_Tip3}"
TextWrapping="Wrap"
Foreground="{DynamicResource TextFillColorSecondaryBrush}"
Margin="0,0,0,16"/>
<Button x:Name="PerformanceIntroContinueButton"
Content="{DynamicResource PerformanceView_Continue}"
Click="PerformanceIntroContinue_Click"
HorizontalAlignment="Right"
Background="{DynamicResource ControlFillColorTertiaryBrush}"
Foreground="{DynamicResource TextFillColorPrimaryBrush}"
Padding="16,8"/>
</StackPanel>
</Border>
</Grid>
<Grid x:Name="StartupMinimizedSuggestionOverlay"
Visibility="Collapsed"
Panel.ZIndex="955"
Background="{DynamicResource OverlayBrush}"
AutomationProperties.Name="{DynamicResource MainWindow_StartupMinimizedSuggestion}">
<Border Background="{DynamicResource CardSurfaceBrush}"
BorderBrush="{DynamicResource BorderSubtleBrush}"
BorderThickness="1"
CornerRadius="{DynamicResource StandardCardCornerRadius}"
Padding="20"
HorizontalAlignment="Center"
VerticalAlignment="Top"
Margin="0,56,0,0"
MinWidth="420"
MaxWidth="560"
IsHitTestVisible="True">
<Border.Effect>
<DropShadowEffect BlurRadius="12" ShadowDepth="0" Opacity="0.16"/>
</Border.Effect>
<StackPanel>
<Border Background="{DynamicResource StatusPillBackgroundBrush}"
BorderBrush="{DynamicResource StatusPillBorderBrush}"
BorderThickness="1"
CornerRadius="{DynamicResource StandardCardCornerRadius}"
Padding="8,3"
HorizontalAlignment="Left"
Margin="0,0,0,10">
<TextBlock Text="{DynamicResource MainWindow_Recommended}"
FontSize="{DynamicResource CaptionFontSize}"
FontWeight="SemiBold"
Foreground="{DynamicResource TextFillColorSecondaryBrush}"/>
</Border>
<TextBlock Text="{DynamicResource MainWindow_StartupMinimizedSuggestionTitle}"
FontSize="20"
FontWeight="SemiBold"
Foreground="{DynamicResource TextFillColorPrimaryBrush}"
Margin="0,0,0,8"/>
<TextBlock Text="{DynamicResource MainWindow_StartupMinimizedSuggestionDescription}"
TextWrapping="Wrap"
Foreground="{DynamicResource TextFillColorSecondaryBrush}"
Margin="0,0,0,16"/>
<StackPanel Orientation="Horizontal" HorizontalAlignment="Right">
<Button Content="{DynamicResource MainWindow_DontShowAgain}"
Click="StartupSuggestionDontShowAgain_Click"
Background="{DynamicResource ControlFillColorDefaultBrush}"
Foreground="{DynamicResource TextFillColorPrimaryBrush}"
Padding="14,7"
Margin="0,0,10,0"/>
<Button Content="{DynamicResource MainWindow_OpenSettings}"
Click="StartupSuggestionOpenSettings_Click"
Background="{DynamicResource ControlFillColorTertiaryBrush}"
Foreground="{DynamicResource TextFillColorPrimaryBrush}"
Padding="14,7"/>
</StackPanel>
</StackPanel>
</Border>
</Grid>
<Grid x:Name="CpuAssignmentModeChangedOverlay"
Visibility="Collapsed"
Panel.ZIndex="956"
Background="{DynamicResource OverlayBrush}"
AutomationProperties.Name="{DynamicResource MainWindow_CpuAssignmentModeChangedTitle}">
<Border Background="{DynamicResource CardSurfaceBrush}"
BorderBrush="{DynamicResource BorderSubtleBrush}"
BorderThickness="1"
CornerRadius="{DynamicResource StandardCardCornerRadius}"
Padding="20"
HorizontalAlignment="Center"
VerticalAlignment="Top"
Margin="0,56,0,0"
MinWidth="420"
MaxWidth="560"
IsHitTestVisible="True">
<Border.Effect>
<DropShadowEffect BlurRadius="12" ShadowDepth="0" Opacity="0.16"/>
</Border.Effect>
<StackPanel>
<Border Background="{DynamicResource StatusPillBackgroundBrush}"
BorderBrush="{DynamicResource StatusPillBorderBrush}"
BorderThickness="1"
CornerRadius="{DynamicResource StandardCardCornerRadius}"
Padding="8,3"
HorizontalAlignment="Left"
Margin="0,0,0,10">
<TextBlock Text="{DynamicResource MainWindow_WhatsNew}"
FontSize="{DynamicResource CaptionFontSize}"
FontWeight="SemiBold"
Foreground="{DynamicResource TextFillColorSecondaryBrush}"/>
</Border>
<TextBlock Text="{DynamicResource MainWindow_CpuAssignmentModeChangedTitle}"
FontSize="20"
FontWeight="SemiBold"
Foreground="{DynamicResource TextFillColorPrimaryBrush}"
Margin="0,0,0,8"/>
<TextBlock Text="{DynamicResource MainWindow_CpuAssignmentModeChangedDescription}"
TextWrapping="Wrap"
Foreground="{DynamicResource TextFillColorSecondaryBrush}"
Margin="0,0,0,16"/>
<StackPanel Orientation="Horizontal" HorizontalAlignment="Right">
<Button x:Name="CpuAssignmentModeChangedGotItButton"
Content="{DynamicResource MainWindow_GotIt}"
Click="CpuAssignmentModeChangedGotIt_Click"
Background="{DynamicResource ControlFillColorDefaultBrush}"
Foreground="{DynamicResource TextFillColorPrimaryBrush}"
Padding="14,7"
Margin="0,0,10,0"/>
<Button Content="{DynamicResource MainWindow_OpenSettings}"
Click="CpuAssignmentModeChangedOpenSettings_Click"
Background="{DynamicResource ControlFillColorTertiaryBrush}"
Foreground="{DynamicResource TextFillColorPrimaryBrush}"
Padding="14,7"/>
</StackPanel>
</StackPanel>
</Border>
</Grid>
<Grid x:Name="UnsavedSettingsOverlay"
Visibility="Collapsed"
Panel.ZIndex="960"
Background="{DynamicResource OverlayBrush}"
AutomationProperties.Name="{DynamicResource MainWindow_UnsavedSettingsDialog}">
<Border Background="{DynamicResource CardSurfaceBrush}"
BorderBrush="{DynamicResource BorderSubtleBrush}"
BorderThickness="1"
CornerRadius="{DynamicResource StandardCardCornerRadius}"
Padding="24"
HorizontalAlignment="Center"
VerticalAlignment="Center"
MinWidth="420"
MaxWidth="560"
IsHitTestVisible="True">
<Border.Effect>
<DropShadowEffect BlurRadius="12" ShadowDepth="0" Opacity="0.18"/>
</Border.Effect>
<StackPanel>
<TextBlock Text="{DynamicResource SettingsWindow_UnsavedTitle}"
FontSize="22"
FontWeight="SemiBold"
Foreground="{DynamicResource TextFillColorPrimaryBrush}"
Margin="0,0,0,10"/>
<TextBlock x:Name="UnsavedSettingsDialogMessage"
Text="{DynamicResource SettingsWindow_UnsavedDescription}"
TextWrapping="Wrap"
Foreground="{DynamicResource TextFillColorSecondaryBrush}"
Margin="0,0,0,18"/>
<StackPanel Orientation="Horizontal" HorizontalAlignment="Right">
<Button Content="{DynamicResource SettingsWindow_Cancel}"
Click="UnsavedSettingsCancel_Click"
Background="{DynamicResource ControlFillColorDefaultBrush}"
Foreground="{DynamicResource TextFillColorPrimaryBrush}"
Padding="16,8"
Margin="0,0,10,0"/>
<Button Content="{DynamicResource SettingsWindow_Discard}"
Click="UnsavedSettingsDiscard_Click"
Background="{DynamicResource ControlFillColorDefaultBrush}"
Foreground="{DynamicResource TextFillColorPrimaryBrush}"
Padding="16,8"
Margin="0,0,10,0"/>
<Button Content="{DynamicResource SettingsWindow_Save}"
Click="UnsavedSettingsSave_Click"
Background="{DynamicResource ControlFillColorTertiaryBrush}"
Foreground="{DynamicResource TextFillColorPrimaryBrush}"
Padding="16,8"/>
</StackPanel>
</StackPanel>
</Border>
</Grid>
<!-- Startup Loading Overlay -->
<Grid x:Name="LoadingOverlay"
Visibility="Visible"
Panel.ZIndex="1000"
AutomationProperties.Name="{DynamicResource MainWindow_LoadingOverlay}"
AutomationProperties.LiveSetting="Polite">
<!-- Loading Popup -->
<Border Background="{DynamicResource CardSurfaceBrush}"
BorderBrush="{DynamicResource BorderSubtleBrush}"
BorderThickness="1"
CornerRadius="{DynamicResource StandardCardCornerRadius}"
Padding="30"
HorizontalAlignment="Center"
VerticalAlignment="Center"
MinWidth="300"
MaxWidth="400"
IsHitTestVisible="True"
Opacity="1">
<StackPanel HorizontalAlignment="Center" VerticalAlignment="Center">
<!-- Application Icon -->
<Border x:Name="LoadingIconBackground"
Background="{DynamicResource QuietRowBackgroundBrush}"
CornerRadius="{DynamicResource StandardCardCornerRadius}"
Padding="10"
Margin="0,0,0,20"
HorizontalAlignment="Center">
<Image x:Name="LoadingIcon"
Source="pack://application:,,,/assets/icons/ico.ico"
Width="64"
Height="64"
HorizontalAlignment="Center"/>
</Border>
<!-- Loading Spinner -->
<ui:ProgressRing IsIndeterminate="True" Margin="0,0,0,15" />
<TextBlock Text="{Binding InitializationStage}"
FontSize="14"
FontWeight="SemiBold"
Foreground="{DynamicResource TextFillColorPrimaryBrush}"
HorizontalAlignment="Center"
Margin="0,0,0,10"/>
<TextBlock Text="{Binding InitializationDetails}"
FontSize="12"
Foreground="{DynamicResource TextFillColorSecondaryBrush}"
HorizontalAlignment="Center"
TextWrapping="Wrap"
TextAlignment="Center"/>
</StackPanel>
</Border>
</Grid>
</Grid>
</Grid>
</ui:FluentWindow>