mirror of
https://github.com/wismna/ModernKeePass.git
synced 2025-10-03 15:40:18 -04:00
52 lines
3.7 KiB
XML
52 lines
3.7 KiB
XML
<UserControl x:Name="UserControl"
|
|
x:Class="ModernKeePass.Views.UserControls.TopMenuUserControl"
|
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
|
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
|
mc:Ignorable="d">
|
|
<StackPanel Orientation="Horizontal">
|
|
<StackPanel Orientation="Horizontal" Visibility="{Binding OverflowButtonsVisibility, ElementName=UserControl}">
|
|
<Button Command="{Binding RestoreCommand, ElementName=UserControl}" Visibility="{Binding RestoreButtonVisibility, ElementName=UserControl}" Click="RestoreButton_Click" Style="{StaticResource NoBorderButtonStyle}" Height="50">
|
|
<SymbolIcon Symbol="Undo">
|
|
<ToolTipService.ToolTip>
|
|
<ToolTip x:Uid="TopMenuRestoreButton" />
|
|
</ToolTipService.ToolTip>
|
|
</SymbolIcon>
|
|
</Button>
|
|
<Button Command="{Binding SaveCommand, ElementName=UserControl}" Style="{StaticResource NoBorderButtonStyle}" Height="50">
|
|
<SymbolIcon Symbol="Save">
|
|
<ToolTipService.ToolTip>
|
|
<ToolTip x:Uid="TopMenuSaveButton" />
|
|
</ToolTipService.ToolTip>
|
|
</SymbolIcon>
|
|
</Button>
|
|
<ToggleButton Command="{Binding EditCommand, ElementName=UserControl}" IsChecked="{Binding IsEditButtonChecked, ElementName=UserControl, Mode=TwoWay}" Click="EditButton_Click" Style="{StaticResource NoBorderToggleButtonStyle}" Height="50">
|
|
<SymbolIcon Symbol="Edit">
|
|
<ToolTipService.ToolTip>
|
|
<ToolTip x:Uid="TopMenuEditButton" />
|
|
</ToolTipService.ToolTip>
|
|
</SymbolIcon>
|
|
</ToggleButton>
|
|
<Button Command="{Binding DeleteCommand, ElementName=UserControl}" IsEnabled="{Binding IsDeleteButtonEnabled, ElementName=UserControl}" Visibility="{Binding DeleteButtonVisibility, ElementName=UserControl}" Click="DeleteButton_Click" Style="{StaticResource NoBorderButtonStyle}" Height="50">
|
|
<SymbolIcon Symbol="Delete">
|
|
<ToolTipService.ToolTip>
|
|
<ToolTip x:Uid="TopMenuDeleteButton" />
|
|
</ToolTipService.ToolTip>
|
|
</SymbolIcon>
|
|
</Button>
|
|
</StackPanel>
|
|
<Button Visibility="{Binding MoreButtonVisibility, ElementName=UserControl}" Style="{StaticResource NoBorderButtonStyle}" Height="50">
|
|
<SymbolIcon Symbol="More" />
|
|
<Button.Flyout>
|
|
<MenuFlyout>
|
|
<MenuFlyoutItem x:Uid="TopMenuRestoreFlyout" Command="{Binding RestoreCommand, ElementName=UserControl}" Click="RestoreButton_Click" Visibility="{Binding RestoreButtonVisibility, ElementName=UserControl}" />
|
|
<MenuFlyoutItem x:Uid="TopMenuSaveFlyout" Command="{Binding SaveCommand, ElementName=UserControl}" />
|
|
<ToggleMenuFlyoutItem x:Uid="TopMenuEditFlyout" Command="{Binding EditCommand, ElementName=UserControl}" IsChecked="{Binding IsEditButtonChecked, ElementName=UserControl, Mode=TwoWay}" Click="EditButton_Click" />
|
|
<MenuFlyoutItem x:Uid="TopMenuDeleteFlyout" Command="{Binding DeleteCommand, ElementName=UserControl}" Click="DeleteButton_Click" Visibility="{Binding DeleteButtonVisibility, ElementName=UserControl}" IsEnabled="{Binding IsDeleteButtonEnabled, ElementName=UserControl}" />
|
|
</MenuFlyout>
|
|
</Button.Flyout>
|
|
</Button>
|
|
</StackPanel>
|
|
</UserControl>
|