修复托盘退出卡死、启动隐藏闪窗和隐藏实例再次启动无法唤醒的问题。 统一深色主题资源与控件模板,补齐卡片、内置图标、右键菜单和弹窗背景样式。 验证:dotnet build PersonalToolbox.sln;dotnet run --project tests\PersonalToolbox.Tests\PersonalToolbox.Tests.csproj。
49 lines
1.8 KiB
XML
49 lines
1.8 KiB
XML
<Window x:Class="PersonalToolbox.Views.PromptWindow"
|
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
|
Title="输入"
|
|
Width="380"
|
|
Height="180"
|
|
ResizeMode="NoResize"
|
|
Background="{DynamicResource AppBackgroundBrush}"
|
|
Foreground="{DynamicResource PrimaryTextBrush}"
|
|
WindowStartupLocation="CenterOwner">
|
|
<Grid Margin="18"
|
|
Background="{DynamicResource AppBackgroundBrush}">
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition Height="Auto" />
|
|
<RowDefinition Height="Auto" />
|
|
<RowDefinition Height="*" />
|
|
<RowDefinition Height="Auto" />
|
|
</Grid.RowDefinitions>
|
|
|
|
<TextBlock x:Name="PromptText"
|
|
FontSize="14"
|
|
TextWrapping="Wrap"
|
|
ToolTip="当前需要输入的信息名称。" />
|
|
|
|
<TextBox x:Name="ValueTextBox"
|
|
Grid.Row="1"
|
|
Margin="0,12,0,0"
|
|
MinHeight="32"
|
|
ToolTip="请输入名称,按 Enter 确认。"
|
|
KeyDown="ValueTextBox_OnKeyDown" />
|
|
|
|
<StackPanel Grid.Row="3"
|
|
Orientation="Horizontal"
|
|
HorizontalAlignment="Right">
|
|
<Button Content="确定"
|
|
Width="82"
|
|
Margin="0,0,8,0"
|
|
IsDefault="True"
|
|
ToolTip="保存输入内容并关闭窗口。"
|
|
Click="OkButton_OnClick" />
|
|
<Button Content="取消"
|
|
Width="82"
|
|
IsCancel="True"
|
|
ToolTip="放弃本次输入。"
|
|
Click="CancelButton_OnClick" />
|
|
</StackPanel>
|
|
</Grid>
|
|
</Window>
|