feat: 支持状态栏显示进度条

This commit is contained in:
uye
2024-10-29 02:56:41 +08:00
parent 906de62d58
commit 28f5e009a2
2 changed files with 16 additions and 0 deletions

View File

@@ -90,6 +90,19 @@ namespace MaaWpfGui.ViewModels.UI
set => SetAndNotify(ref _windowTitle, value);
}
private double _progress;
/// <summary>
/// Gets or sets the progress.
/// 0.0 to 1.0.
/// 置 0 以隐藏进度条.
/// </summary>
public double Progress
{
get => _progress;
set => SetAndNotify(ref _progress, value);
}
private bool _windowTitleScrollable = Convert.ToBoolean(ConfigurationHelper.GetValue(ConfigurationKeys.WindowTitleScrollable, bool.FalseString));
/// <summary>

View File

@@ -51,6 +51,9 @@
Foreground="{Binding WindowTopMostButtonForeground}" />
</Grid>
</hc:Window.NonClientAreaContent>
<Window.TaskbarItemInfo>
<TaskbarItemInfo ProgressState="Normal" ProgressValue="{Binding Progress}" />
</Window.TaskbarItemInfo>
<DockPanel>
<local:NotifyIcon x:Name="NotifyIcon" Visibility="Hidden" />
<TabControl