PasswordDialog.xaml 4.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768
  1. <UserControl x:Class="Compdfkit_Tools.Common.PasswordDialog"
  2. xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  3. xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  4. xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
  5. xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
  6. xmlns:local="clr-namespace:Compdfkit_Tools.Common"
  7. mc:Ignorable="d"
  8. d:DesignHeight="226" d:DesignWidth="534" BorderBrush="Black" BorderThickness="1">
  9. <UserControl.Resources>
  10. <local:CommonResourceConverter x:Key="CommonResourceConverter" />
  11. </UserControl.Resources>
  12. <Grid Width="534" Height="226" HorizontalAlignment="Center" VerticalAlignment="Center" Background="White">
  13. <Grid.ColumnDefinitions>
  14. <ColumnDefinition Width="*"></ColumnDefinition>
  15. <ColumnDefinition Width="*"></ColumnDefinition>
  16. </Grid.ColumnDefinitions>
  17. <Grid.RowDefinitions>
  18. <RowDefinition Height="auto"></RowDefinition>
  19. <RowDefinition Height="*"></RowDefinition>
  20. <RowDefinition Height="auto"></RowDefinition>
  21. </Grid.RowDefinitions>
  22. <TextBlock Height="20" FontSize="14" LineHeight="16" Margin="12,6,0,0" HorizontalAlignment="Left"
  23. Text="{Binding Converter={StaticResource CommonResourceConverter},ConverterParameter=Title_Password}"></TextBlock>
  24. <Button Grid.Column="1" Width="16" Height="16" HorizontalAlignment="Right" Margin="0,8,8,0" BorderThickness="0" Click="PasswordDialogClose_Click">
  25. <Button.Content>
  26. <Path Fill="Black">
  27. <Path.Data>
  28. M6.69495 6L11.5 1.19495L10.805 0.5L6 5.30505L1.19495 0.5L0.5 1.19495L5.30505 6L0.5 10.805L1.19495 11.5L6 6.69495L10.805 11.5L11.5 10.805L6.69495 6Z
  29. </Path.Data>
  30. </Path>
  31. </Button.Content>
  32. </Button>
  33. <Grid Grid.Row="1" Margin="0,36,0,0" Grid.ColumnSpan="2">
  34. <Grid.ColumnDefinitions>
  35. <ColumnDefinition Width="80"></ColumnDefinition>
  36. <ColumnDefinition Width="*"></ColumnDefinition>
  37. </Grid.ColumnDefinitions>
  38. <Grid.RowDefinitions>
  39. <RowDefinition Height="auto"></RowDefinition>
  40. <RowDefinition Height="auto"></RowDefinition>
  41. </Grid.RowDefinitions>
  42. <Image Width="32" Height="32" Source="../../Asset/Resource/warn.png"/>
  43. <TextBlock FontSize="14" Foreground="#43474D" Grid.Column="1" Name="FileEncryptText" VerticalAlignment="Center"></TextBlock>
  44. <StackPanel Orientation="Horizontal" Grid.Column="1" Grid.Row="1" Height="62" Margin="0,22,0,0" >
  45. <TextBlock FontSize="14" Foreground="#43474D" Margin="0,-30,0,0" VerticalAlignment="Center"
  46. Text="{Binding Converter={StaticResource CommonResourceConverter},ConverterParameter=Tip_Password}"></TextBlock>
  47. <StackPanel Margin="8,0,0,0">
  48. <PasswordBox Name="PasswordBoxText" Padding="5,0,0,0" Height="32" Width="185" VerticalContentAlignment="Center" VerticalAlignment="Center"></PasswordBox>
  49. <TextBlock Name="ErrorTipsText" Foreground="Red" Margin="0,4,0,0" Visibility="Collapsed"></TextBlock>
  50. </StackPanel>
  51. </StackPanel>
  52. </Grid>
  53. <StackPanel Orientation="Horizontal" HorizontalAlignment="Right" Grid.Row="2" Margin="0,0,24,12" Grid.ColumnSpan="2">
  54. <Button Width="112" Height="32" Click="PasswordDialogConfirm_Click"
  55. Content="{Binding Converter={StaticResource CommonResourceConverter},ConverterParameter=Button_OK}"></Button>
  56. <Button Width="112" Height="32" Margin="8,0,0,0" Click="PasswordDialogCancel_Click"
  57. Content="{Binding Converter={StaticResource CommonResourceConverter},ConverterParameter=Button_Cancel}"></Button>
  58. </StackPanel>
  59. </Grid>
  60. </UserControl>