添加项目文件。
This commit is contained in:
47
WPFWCSDemo/Views/CustomComponent/InputDialog.xaml
Normal file
47
WPFWCSDemo/Views/CustomComponent/InputDialog.xaml
Normal file
@@ -0,0 +1,47 @@
|
||||
<Window x:Class="WPFWCSDemo.Views.CustomComponent.InputDialog"
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
||||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
||||
xmlns:md="http://materialdesigninxaml.net/winfx/xaml/themes"
|
||||
xmlns:local="clr-namespace:WPFWCSDemo.ViewModels.CustomComponent"
|
||||
d:DataContext="{d:DesignInstance Type=local:InputDialogViewModel}"
|
||||
mc:Ignorable="d"
|
||||
d:DesignHeight="160" d:DesignWidth="270"
|
||||
MaxHeight="200"
|
||||
MaxWidth="300"
|
||||
AllowsTransparency="True"
|
||||
Topmost="True"
|
||||
WindowState="Normal"
|
||||
WindowStyle="None"
|
||||
BorderBrush="BlueViolet"
|
||||
BorderThickness="3"
|
||||
WindowStartupLocation="CenterScreen"
|
||||
Background="GhostWhite"
|
||||
x:Name="inputWindow">
|
||||
|
||||
<Window.Effect>
|
||||
<DropShadowEffect BlurRadius="20" ShadowDepth="15" Direction="225" Opacity="0.7"/>
|
||||
</Window.Effect>
|
||||
|
||||
<DockPanel>
|
||||
<md:ColorZone x:Name="colorZone" CornerRadius="0" Padding="0" Height="30" md:ElevationAssist.Elevation="Dp4" DockPanel.Dock="Top" Mode="PrimaryMid">
|
||||
<TextBlock Text="{Binding Caption}" VerticalAlignment="Center" Margin="20 0"/>
|
||||
</md:ColorZone>
|
||||
<md:ColorZone Height="6" CornerRadius="0"/>
|
||||
<Grid Margin="10">
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="*"/>
|
||||
<RowDefinition Height="*"/>
|
||||
<RowDefinition Height="auto"/>
|
||||
</Grid.RowDefinitions>
|
||||
|
||||
<TextBlock TextWrapping="Wrap" Text="请输入密码:" VerticalAlignment="Center" LineHeight="20" Padding="20 20 30 0"/>
|
||||
<TextBox Grid.Row="1" Text="{Binding Content}" VerticalContentAlignment="Bottom" VerticalAlignment="Center" Width="200" />
|
||||
<DockPanel Grid.Row="2" LastChildFill="False" Margin="20,10,20,0">
|
||||
<Button Content="确认" Background="Lavender" Width="100" IsDefault="True" Style="{StaticResource MaterialDesignFlatButton}" Command="{Binding AcceptCommand}"/>
|
||||
<Button Content="取消" Background="Lavender" Width="100" Style="{StaticResource MaterialDesignFlatButton}" DockPanel.Dock="Right" Command="{Binding CancelCommand}" CommandParameter="{Binding InputDialog}"/>
|
||||
</DockPanel>
|
||||
</Grid>
|
||||
</DockPanel>
|
||||
</Window>
|
||||
Reference in New Issue
Block a user