RoleSettingWindow.xaml 8.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596
  1. <Window x:Class="ivf_tl_Manage.Win.RoleSettingWindow"
  2. xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  3. xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  4. xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
  5. xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
  6. xmlns:local="clr-namespace:ivf_tl_Manage.Win"
  7. xmlns:customControl="clr-namespace:ivf_tl_CustomControls;assembly=ivf_tl_CustomControls_PC"
  8. xmlns:controls="clr-namespace:ivf_tl_Manage.UserControls"
  9. mc:Ignorable="d"
  10. FontFamily="{StaticResource sourceHan}"
  11. WindowStyle="None"
  12. ShowInTaskbar="False"
  13. WindowStartupLocation="CenterOwner"
  14. Background="Transparent"
  15. AllowsTransparency="True"
  16. Width="710" Height="615">
  17. <Canvas Width="710" Height="615">
  18. <Canvas.Background>
  19. <ImageBrush ImageSource="pack://application:,,,/ivf_tl_Manage;component/Resources/Images/RoleSettingWindowBackground.png"/>
  20. </Canvas.Background>
  21. <DockPanel Canvas.Left="60" Canvas.Top="57">
  22. <TextBlock DockPanel.Dock="Top" Margin="2 0 2 2" x:Name="_title_TextBlock" Canvas.Left="60" Canvas.Top="57" Text="{DynamicResource 0213}" FontWeight="Medium" Foreground="Black" FontSize="20"/>
  23. <Rectangle DockPanel.Dock="Bottom" Canvas.Left="58" Canvas.Top="90" Height="3" Fill="#4D75AC" RadiusX="1.5" RadiusY="1.5"/>
  24. </DockPanel>
  25. <!--<TextBlock x:Name="_title_TextBlock" Canvas.Left="60" Canvas.Top="57" Text="{DynamicResource 0213}" FontWeight="Medium" Foreground="Black" FontSize="20"/>
  26. <Rectangle Canvas.Left="58" Canvas.Top="90" Width="84" Height="2" Fill="#4D75AC" RadiusX="1" RadiusY="1"/>-->
  27. <customControl:ButtonImage Canvas.Left="634" Canvas.Top="60" Width="18" Height="18" Click="Cancel_Click"
  28. IconSource="pack://application:,,,/ivf_tl_Manage;component/Resources/Images/CloseGrayIcon.png"
  29. MouseOverIconSource="pack://application:,,,/ivf_tl_Manage;component/Resources/Images/CloseBlueIcon.png"/>
  30. <Border Canvas.Left="60" Canvas.Top="110" Width="590" Height="365" BorderThickness="1" BorderBrush="#C6C6C6" CornerRadius="6">
  31. <Grid>
  32. <Grid.ColumnDefinitions>
  33. <ColumnDefinition />
  34. <ColumnDefinition Width="auto"/>
  35. <ColumnDefinition Width="auto"/>
  36. </Grid.ColumnDefinitions>
  37. <ListBox x:Name="_listBox" Grid.Column="0" Style="{StaticResource ListBoxStyleUserBus}" HorizontalContentAlignment="Stretch" MaxHeight="355" VerticalAlignment="Top"
  38. BorderThickness="0" Background="Transparent" SelectionChanged="_listBox_SelectionChanged" Margin="0 5 0 0">
  39. <ListBox.ItemContainerStyle>
  40. <Style TargetType="{x:Type ListBoxItem}">
  41. <Setter Property="FocusVisualStyle" Value="{x:Null}"/>
  42. <Setter Property="Template">
  43. <Setter.Value>
  44. <ControlTemplate TargetType="{x:Type ListBoxItem}">
  45. <StackPanel x:Name="_listBoxItem" Background="Transparent" Orientation="Horizontal" HorizontalAlignment="Stretch" Height="30">
  46. <Image VerticalAlignment="Center" Width="20" Height="20" Margin="15 0 10 0" MouseDown="Rectangle_MouseDown" Tag="{Binding}"
  47. Source="{Binding isOpen,Converter={StaticResource CustomButtonMouseOverIconConvert},ConverterParameter=SettingIcon}"/>
  48. <customControl:CheckBoxContent Height="20" Padding="0 0 10 0" IsChecked="{Binding isChecked}"
  49. TextCntent="{Binding name}" Tag="{Binding}" FontWeight="Medium" FontSize="16" Foreground="#4D4D4D"
  50. CheckImageSource="pack://application:,,,/ivf_tl_Manage;component/Resources/Images/MarkDefeatIcon.png">
  51. <customControl:CheckBoxContent.Content>
  52. <Rectangle Width="20" Height="20" StrokeThickness="1" Stroke="#9B9B9B" RadiusX="2" RadiusY="2"/>
  53. </customControl:CheckBoxContent.Content>
  54. </customControl:CheckBoxContent>
  55. </StackPanel>
  56. <ControlTemplate.Triggers>
  57. <Trigger Property="IsSelected" Value="True">
  58. <Setter TargetName="_listBoxItem" Property="Background" Value="#ECEEF2"/>
  59. </Trigger>
  60. </ControlTemplate.Triggers>
  61. </ControlTemplate>
  62. </Setter.Value>
  63. </Setter>
  64. </Style>
  65. </ListBox.ItemContainerStyle>
  66. </ListBox>
  67. <Rectangle Grid.Column="1" Width="1" Height="365" Fill="#C6C6C6"
  68. Visibility="{Binding ElementName=_children,Path=HasItems,Converter={StaticResource BooleanToVisibilityConverter}}"/>
  69. <Border Width="294" Height="363" Grid.Column="2" Background="#ECEEF2" CornerRadius="0 5 5 0"
  70. Visibility="{Binding ElementName=_children,Path=HasItems,Converter={StaticResource BooleanToVisibilityConverter}}">
  71. <ListBox x:Name="_children" DisplayMemberPath="name" Style="{StaticResource ListBoxStyleUserBus}" Width="294" HorizontalContentAlignment="Stretch" MaxHeight="355" VerticalAlignment="Top"
  72. BorderThickness="0" Background="Transparent" Margin="0 5 0 0" FontWeight="Medium" Foreground="#4D4D4D" FontSize="16"
  73. >
  74. </ListBox>
  75. </Border>
  76. </Grid>
  77. </Border>
  78. <TextBlock x:Name="message" Canvas.Left="100" Canvas.Top="508" Text="" MaxWidth="320" FontWeight="Medium" FontSize="16" Foreground="Red" TextWrapping="Wrap"/>
  79. <customControl:ButtonCornerRadius IsTabStop="False" Canvas.Left="554" Canvas.Top="497" Width="104" Height="56" Click="Ok_Click" IsDefault="True" Content="{DynamicResource 0024}" FontSize="14" MarginMask="10">
  80. <customControl:ButtonCornerRadius.Background>
  81. <ImageBrush ImageSource="pack://application:,,,/ivf_tl_Manage;component/Resources/Images/OkButtonIcon1.png"/>
  82. </customControl:ButtonCornerRadius.Background>
  83. </customControl:ButtonCornerRadius>
  84. <customControl:ButtonCornerRadius Canvas.Left="446" Canvas.Top="497" Width="104" Height="56" Click="Cancel_Click" IsCancel="True" Content="{DynamicResource 0025}" Foreground="#717171" FontSize="14" MarginMask="10">
  85. <customControl:ButtonCornerRadius.Background>
  86. <ImageBrush ImageSource="pack://application:,,,/ivf_tl_Manage;component/Resources/Images/CancelButtonIcon1.png"/>
  87. </customControl:ButtonCornerRadius.Background>
  88. </customControl:ButtonCornerRadius>
  89. <!--<customControl:ButtonImage IsTabStop="False" Canvas.Left="446" Canvas.Top="497" Width="104" Height="56" Click="Cancel_Click" IsCancel="True" IconSource="pack://application:,,,/ivf_tl_Manage;component/Resources/Images/CancelButtonIcon.png" MouseOverIconSource="pack://application:,,,/ivf_tl_Manage;component/Resources/Images/CancelButtonMouseOverIcon.png"/>-->
  90. <!--<customControl:ButtonImage IsTabStop="False" Canvas.Left="554" Canvas.Top="497" Width="104" Height="56" Click="Ok_Click" IsDefault="True" IconSource="pack://application:,,,/ivf_tl_Manage;component/Resources/Images/OkButtonIcon.png" MouseOverIconSource="pack://application:,,,/ivf_tl_Manage;component/Resources/Images/OkButtonMouseOverIcon.png"/>-->
  91. </Canvas>
  92. </Window>