|
71 | 71 | <ColumnDefinition Width="Auto" />
|
72 | 72 | <ColumnDefinition />
|
73 | 73 | </Grid.ColumnDefinitions>
|
74 |
| - <Button Name="ButtonIcon" Visibility="{TemplateBinding Icon,Converter={StaticResource Object2VisibilityConverter}}" Command="{x:Static shell:SystemCommands.ShowSystemMenuCommand}" Background="Transparent" Margin="10,0,0,0" shell:WindowChrome.IsHitTestVisibleInChrome="True" Style="{StaticResource ButtonCustom}" VerticalAlignment="Center"> |
| 74 | + <Button Name="ButtonIcon" Command="{x:Static shell:SystemCommands.ShowSystemMenuCommand}" Background="Transparent" Margin="10,0,0,0" shell:WindowChrome.IsHitTestVisibleInChrome="True" Style="{StaticResource ButtonCustom}" VerticalAlignment="Center"> |
| 75 | + <Button.Visibility> |
| 76 | + <MultiBinding Converter="{StaticResource BooleanArr2VisibilityConverter}"> |
| 77 | + <MultiBinding.Bindings> |
| 78 | + <Binding Path="ShowIcon" RelativeSource="{RelativeSource TemplatedParent}" /> |
| 79 | + <Binding Path="Icon" RelativeSource="{RelativeSource TemplatedParent}" Converter="{StaticResource Object2BooleanConverter}" /> |
| 80 | + </MultiBinding.Bindings> |
| 81 | + </MultiBinding> |
| 82 | + </Button.Visibility> |
75 | 83 | <interactivity:Interaction.Triggers>
|
76 | 84 | <interactivity:EventTrigger EventName="MouseDoubleClick">
|
77 | 85 | <interactivity:InvokeCommandAction Command="{x:Static shell:SystemCommands.CloseWindowCommand}" />
|
|
172 | 180 | <ColumnDefinition Width="Auto" />
|
173 | 181 | <ColumnDefinition />
|
174 | 182 | </Grid.ColumnDefinitions>
|
175 |
| - <Button Name="ButtonIcon" Visibility="{TemplateBinding Icon,Converter={StaticResource Object2VisibilityConverter}}" Command="{x:Static shell:SystemCommands.ShowSystemMenuCommand}" Background="Transparent" Margin="10,0,0,0" shell:WindowChrome.IsHitTestVisibleInChrome="True" Style="{StaticResource ButtonCustom}" VerticalAlignment="Center"> |
| 183 | + <Button Name="ButtonIcon" Command="{x:Static shell:SystemCommands.ShowSystemMenuCommand}" Background="Transparent" Margin="10,0,0,0" shell:WindowChrome.IsHitTestVisibleInChrome="True" Style="{StaticResource ButtonCustom}" VerticalAlignment="Center"> |
| 184 | + <Button.Visibility> |
| 185 | + <MultiBinding Converter="{StaticResource BooleanArr2VisibilityConverter}"> |
| 186 | + <MultiBinding.Bindings> |
| 187 | + <Binding Path="ShowIcon" RelativeSource="{RelativeSource TemplatedParent}" /> |
| 188 | + <Binding Path="Icon" RelativeSource="{RelativeSource TemplatedParent}" Converter="{StaticResource Object2BooleanConverter}" /> |
| 189 | + </MultiBinding.Bindings> |
| 190 | + </MultiBinding> |
| 191 | + </Button.Visibility> |
176 | 192 | <interactivity:Interaction.Triggers>
|
177 | 193 | <interactivity:EventTrigger EventName="MouseDoubleClick">
|
178 | 194 | <interactivity:InvokeCommandAction Command="{x:Static shell:SystemCommands.CloseWindowCommand}" />
|
|
0 commit comments