|
4 | 4 | xmlns:system="clr-namespace:System;assembly=mscorlib"
|
5 | 5 | xmlns:ui="http://schemas.modernwpf.com/2019">
|
6 | 6 |
|
| 7 | + <ContextMenu x:Key="TextBoxContextMenu"> |
| 8 | + <MenuItem Command="ApplicationCommands.Cut" Header="{DynamicResource cut}"> |
| 9 | + <MenuItem.Icon> |
| 10 | + <ui:FontIcon Glyph="" /> |
| 11 | + </MenuItem.Icon> |
| 12 | + </MenuItem> |
| 13 | + <MenuItem Command="ApplicationCommands.Copy" Header="{DynamicResource copy}"> |
| 14 | + <MenuItem.Icon> |
| 15 | + <ui:FontIcon Glyph="" /> |
| 16 | + </MenuItem.Icon> |
| 17 | + </MenuItem> |
| 18 | + <MenuItem Command="ApplicationCommands.Paste" Header="{DynamicResource paste}"> |
| 19 | + <MenuItem.Icon> |
| 20 | + <ui:FontIcon Glyph="" /> |
| 21 | + </MenuItem.Icon> |
| 22 | + </MenuItem> |
| 23 | + <MenuItem Command="ApplicationCommands.Undo" Header="{DynamicResource undo}"> |
| 24 | + <MenuItem.Icon> |
| 25 | + <ui:FontIcon Glyph="" /> |
| 26 | + </MenuItem.Icon> |
| 27 | + </MenuItem> |
| 28 | + <MenuItem Command="ApplicationCommands.SelectAll" Header="{DynamicResource selectAll}" /> |
| 29 | + </ContextMenu> |
| 30 | + |
7 | 31 |
|
8 | 32 | <Style TargetType="{x:Type ContentControl}">
|
9 | 33 | <Setter Property="Foreground" Value="{DynamicResource Color05B}" />
|
|
1357 | 1381 | </Setter>
|
1358 | 1382 | </Style>
|
1359 | 1383 |
|
1360 |
| - <Style BasedOn="{StaticResource DefaultTextBoxStyle}" TargetType="TextBox" /> |
| 1384 | + <Style BasedOn="{StaticResource DefaultTextBoxStyle}" TargetType="TextBox"> |
| 1385 | + <Setter Property="ContextMenu" Value="{StaticResource TextBoxContextMenu}" /> |
| 1386 | + </Style> |
| 1387 | + |
| 1388 | + <Style BasedOn="{StaticResource DefaultPasswordBoxStyle}" TargetType="PasswordBox"> |
| 1389 | + <Setter Property="ContextMenu" Value="{StaticResource TextBoxContextMenu}" /> |
| 1390 | + </Style> |
1361 | 1391 |
|
1362 | 1392 | <Style
|
1363 | 1393 | x:Key="DataGridTextBoxStyle"
|
|
2969 | 2999 | <Setter TargetName="KeyboardAcceleratorTextBlock" Property="Foreground" Value="{DynamicResource MenuFlyoutItemKeyboardAcceleratorTextForegroundPressed}" />
|
2970 | 3000 | </Trigger>
|
2971 | 3001 | <Trigger Property="IsEnabled" Value="False">
|
| 3002 | + <!-- Hide Disabled Item --> |
| 3003 | + <Setter TargetName="LayoutRoot" Property="Visibility" Value="Collapsed" /> |
2972 | 3004 | <Setter TargetName="LayoutRoot" Property="Background" Value="{DynamicResource MenuFlyoutItemBackgroundDisabled}" />
|
2973 | 3005 | <Setter TargetName="LayoutRoot" Property="TextElement.Foreground" Value="{DynamicResource MenuFlyoutItemForegroundDisabled}" />
|
2974 | 3006 | <Setter TargetName="ContentPresenter" Property="TextElement.Foreground" Value="{DynamicResource MenuFlyoutItemForegroundDisabled}" />
|
|
3252 | 3284 | </Trigger>
|
3253 | 3285 | </Style.Triggers>
|
3254 | 3286 | </Style>
|
| 3287 | + |
| 3288 | + |
3255 | 3289 | </ResourceDictionary>
|
0 commit comments