mirror of
https://github.com/sourcegit-scm/sourcegit
synced 2025-06-03 01:55:00 +00:00
ux: new attached property MenuItemExtension.Command
for MenuItem
Signed-off-by: leo <longshuang@msn.cn>
This commit is contained in:
parent
6a1026c992
commit
dd254ebf4f
10 changed files with 42 additions and 15 deletions
|
@ -2,6 +2,7 @@
|
|||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:s="using:SourceGit"
|
||||
xmlns:vm="using:SourceGit.ViewModels"
|
||||
xmlns:v="using:SourceGit.Views"
|
||||
xmlns:c="using:SourceGit.Converters"
|
||||
xmlns:ae="using:AvaloniaEdit"
|
||||
xmlns:aee="using:AvaloniaEdit.Editing"
|
||||
|
@ -844,7 +845,19 @@
|
|||
HorizontalAlignment="Right"
|
||||
VerticalAlignment="Center"
|
||||
Foreground="{DynamicResource MenuFlyoutItemKeyboardAcceleratorTextForeground}"
|
||||
FontSize="11"/>
|
||||
FontSize="11"
|
||||
IsVisible="{TemplateBinding (v:MenuItemExtension.Command), Converter={x:Static StringConverters.IsNullOrEmpty}}"/>
|
||||
|
||||
<TextBlock x:Name="PART_CommandTip"
|
||||
Grid.Column="2"
|
||||
Classes="CaptionTextBlockStyle"
|
||||
Margin="{DynamicResource MenuInputGestureTextMargin}"
|
||||
Text="{TemplateBinding (v:MenuItemExtension.Command)}"
|
||||
HorizontalAlignment="Right"
|
||||
VerticalAlignment="Center"
|
||||
Foreground="{DynamicResource MenuFlyoutItemKeyboardAcceleratorTextForeground}"
|
||||
FontSize="11"
|
||||
IsVisible="{TemplateBinding (v:MenuItemExtension.Command), Converter={x:Static StringConverters.IsNotNullOrEmpty}}"/>
|
||||
|
||||
<Path Name="PART_ChevronPath"
|
||||
Width="6"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue