mirror of
https://github.com/chylex/Backup-Essentials.git
synced 2024-10-17 08:42:44 +02:00
74 lines
4.4 KiB
XML
74 lines
4.4 KiB
XML
<Page x:Class="BackupEssentials.Pages.BackupDrop"
|
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
|
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
|
xmlns:sys="clr-namespace:System;assembly=mscorlib"
|
|
xmlns:system="clr-namespace:BackupEssentials.Sys"
|
|
xmlns:backup="clr-namespace:BackupEssentials.Backup"
|
|
mc:Ignorable="d"
|
|
d:DesignWidth="{StaticResource PageWidth}" d:DesignHeight="{StaticResource PageHeight}" Background="{StaticResource PageBackground}"
|
|
Title="Backup">
|
|
|
|
<Page.Resources>
|
|
<sys:Double x:Key="LocationListItemHeight">46</sys:Double>
|
|
</Page.Resources>
|
|
|
|
<Grid Margin="0,0,0,13">
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition Height="48"/>
|
|
<RowDefinition Height="*"/>
|
|
</Grid.RowDefinitions>
|
|
|
|
<StackPanel Orientation="Horizontal" DataContext="{Binding Source={x:Static system:Settings.Default}}">
|
|
<StackPanel.Resources>
|
|
<Style TargetType="Button">
|
|
<Setter Property="Margin" Value="8,8,0,0"/>
|
|
<Setter Property="FontSize" Value="16"/>
|
|
<Setter Property="Template" Value="{StaticResource ButtonStyleDefault}"/>
|
|
</Style>
|
|
</StackPanel.Resources>
|
|
<Button x:Name="ButtonBackup" Content="{Binding Language[BackupDrop.Button.Run]}" IsEnabled="False" Click="ClickBackup"/>
|
|
<Button x:Name="ButtonCancel" Content="{Binding Language[BackupDrop.Button.Cancel]}" Template="{StaticResource ButtonStyleRedDefault}" Click="ClickCancel"/>
|
|
</StackPanel>
|
|
|
|
<ListView Name="LocationsListView" Grid.Row="1" Margin="8" Style="{StaticResource ListViewStyleDefault}" SelectionChanged="ListViewSelectionChanged">
|
|
<ListView.Resources>
|
|
<Style TargetType="{x:Type ListViewItem}">
|
|
<Setter Property="Padding" Value="8,4,8,8"/>
|
|
<Setter Property="Template">
|
|
<Setter.Value>
|
|
<ControlTemplate TargetType="{x:Type ListViewItem}">
|
|
<Border x:Name="border" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}" Padding="{TemplateBinding Padding}" SnapsToDevicePixels="True">
|
|
<VisualStateManager.VisualStateGroups>
|
|
<VisualStateGroup x:Name="CommonStates">
|
|
<VisualState x:Name="Normal"/>
|
|
<VisualState x:Name="MouseOver" Storyboard="{StaticResource ListViewItemStoryboardMouseOver}"/>
|
|
<VisualState x:Name="Selected" Storyboard="{StaticResource ListViewItemStoryboardSelected}"/>
|
|
</VisualStateGroup>
|
|
</VisualStateManager.VisualStateGroups>
|
|
|
|
<Grid Width="740" Height="{StaticResource LocationListItemHeight}" SnapsToDevicePixels="True" HorizontalAlignment="Left">
|
|
<TextBlock Foreground="#FFDDDDDD" Text="{Binding Name}" VerticalAlignment="Top" FontSize="20"/>
|
|
<TextBlock Foreground="#FFCCCCCC" Text="{Binding Directory}" VerticalAlignment="Bottom" FontSize="16"/>
|
|
</Grid>
|
|
</Border>
|
|
</ControlTemplate>
|
|
</Setter.Value>
|
|
</Setter>
|
|
</Style>
|
|
</ListView.Resources>
|
|
|
|
<ListView.Items>
|
|
<backup:BackupLocation Name="Test1" Directory="C:\Abc"/>
|
|
<backup:BackupLocation Name="Test2" Directory="C:\Abc"/>
|
|
<backup:BackupLocation Name="Test3" Directory="C:\Abc"/>
|
|
<backup:BackupLocation Name="Test4" Directory="C:\Abc"/>
|
|
<backup:BackupLocation Name="Test5" Directory="C:\Abc"/>
|
|
<backup:BackupLocation Name="Test6" Directory="C:\Abc"/>
|
|
<backup:BackupLocation Name="Test7" Directory="C:\Abc"/>
|
|
<backup:BackupLocation Name="Test8" Directory="C:\Abc"/>
|
|
</ListView.Items>
|
|
</ListView>
|
|
</Grid>
|
|
</Page> |