FieldWorkClient/View/Send/SendControl.xaml

59 lines
2.9 KiB
XML

<UserControl x:Class="HeBianGu.App.Disk.Send.SendControl"
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:h="https://github.com/HeBianGu"
xmlns:local="clr-namespace:HeBianGu.App.Disk"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
d:DesignHeight="450"
d:DesignWidth="800"
mc:Ignorable="d">
<Grid>
<Grid.Resources>
<Style BasedOn="{StaticResource {x:Static h:ButtonKeys.Transparent}}" TargetType="Button">
<Setter Property="Margin" Value="0,0,20,0" />
<Setter Property="RenderTransform" Value="{StaticResource {x:Static h:SystemKeys.TransformGroup}}" />
</Style>
</Grid.Resources>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="170" />
<ColumnDefinition />
</Grid.ColumnDefinitions>
<ListBox h:Cattach.ItemHorizontalAlignment="Stretch"
h:Cattach.ItemHorizontalContentAlignment="Stretch"
BorderBrush="{DynamicResource {x:Static h:BrushKeys.BorderBrushDefault}}"
BorderThickness="0,0,1,0"
ItemContainerStyle="{StaticResource {x:Static h:ListBoxItemKeys.LeftAccent}}"
ItemsSource="{Binding LinkActions}"
SelectedIndex="0"
SelectedItem="{Binding SelectLink, Mode=TwoWay}">
<ListBox.Resources>
<DataTemplate DataType="{x:Type h:LinkAction}">
<Grid Height="{DynamicResource {x:Static h:SystemKeys.ItemHeight}}">
<StackPanel Margin="10,0,0,0" VerticalAlignment="Center" Orientation="Horizontal">
<TextBlock Style="{DynamicResource {x:Static h:TextBlockKeys.Icon}}" Text="{Binding Logo}" />
<TextBlock Margin="10,0,0,0" VerticalAlignment="Center" Text="{Binding DisplayName}" />
<TextBlock Margin="5,0,0,0" VerticalAlignment="Center" Text="{Binding FullName}" />
</StackPanel>
</Grid>
</DataTemplate>
</ListBox.Resources>
<ListBox.Template>
<ControlTemplate TargetType="ListBox">
<Grid>
<Border Background="{DynamicResource {x:Static h:BrushKeys.Dark0_2}}" />
<ItemsPresenter SnapsToDevicePixels="True" />
</Grid>
</ControlTemplate>
</ListBox.Template>
</ListBox>
<Grid Grid.Column="1">
<h:LinkActionFrame LinkAction="{Binding SelectLink, Mode=TwoWay}" />
</Grid>
</Grid>
</UserControl>