Files
2026-03-27 14:45:36 +01:00

69 lines
2.8 KiB
XML

<ContentDialog
x:Class="Wino.Dialogs.MoveMailDialog"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:controls="using:Wino.Controls"
xmlns:coreControls="using:Wino.Mail.WinUI.Controls"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:domain="using:Wino.Core.Domain"
xmlns:folders="using:Wino.Core.Domain.Models.Folders"
xmlns:helpers="using:Wino.Helpers"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:muxc="using:Microsoft.UI.Xaml.Controls"
Title="{x:Bind domain:Translator.MoveMailDialog_Title}"
DefaultButton="Primary"
PrimaryButtonClick="CancelClicked"
PrimaryButtonText="{x:Bind domain:Translator.Buttons_Cancel}"
Style="{StaticResource WinoDialogStyle}"
mc:Ignorable="d">
<ContentDialog.Resources>
<x:Double x:Key="ContentDialogMinWidth">600</x:Double>
<x:Double x:Key="ContentDialogMaxWidth">600</x:Double>
<x:Double x:Key="ContentDialogMinHeight">756</x:Double>
<x:Double x:Key="ContentDialogMaxHeight">756</x:Double>
<DataTemplate x:Key="FolderStructureMenuFlyoutItemTemplate" x:DataType="folders:IMailItemFolder">
<TreeViewItem IsExpanded="True" ItemsSource="{x:Bind ChildFolders}">
<StackPanel
Height="36"
Orientation="Horizontal"
Spacing="14">
<coreControls:WinoFontIcon FontSize="20" Icon="{x:Bind helpers:XamlHelpers.GetSpecialFolderPathIconGeometry(SpecialFolderType)}" />
<TextBlock
VerticalAlignment="Center"
Style="{ThemeResource BodyTextBlockStyle}"
Text="{x:Bind FolderName}" />
</StackPanel>
</TreeViewItem>
</DataTemplate>
</ContentDialog.Resources>
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="Auto" />
<RowDefinition Height="*" />
</Grid.RowDefinitions>
<Border
x:Name="InvalidFolderBorder"
Margin="0,0,0,6"
Padding="12,8"
Background="{ThemeResource SystemFillColorCautionBackgroundBrush}"
CornerRadius="4"
Visibility="Collapsed">
<TextBlock x:Name="InvalidFolderText" Foreground="{ThemeResource InfoBarWarningSeverityIconBackground}" />
</Border>
<TreeView
x:Name="FolderTreeView"
Grid.Row="1"
CanDragItems="False"
CanReorderItems="False"
ItemTemplate="{StaticResource FolderStructureMenuFlyoutItemTemplate}"
ItemsSource="{x:Bind FolderList}"
SelectedItem="{x:Bind SelectedFolder, Mode=TwoWay}"
SelectionMode="Single" />
</Grid>
</ContentDialog>