XFE Git
XFE Studio Git
Git 首页 全局搜索
XFE 主站 文档 NuGet

XFEToolBox

【WPF】XFE工具箱

公开
关注 0 Fork 0 Star 0
UTF-8
<Page x:Class="XFEToolBox.Client.Views.Pages.Popups.PinnedItemsPopupPage"
      xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
      xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
      xmlns:controls="clr-namespace:XFEToolBox.WpfCore.Controls;assembly=XFEToolBox.WpfCore"
      Loaded="Page_Loaded">
    <Grid Margin="18">
        <Grid.RowDefinitions><RowDefinition Height="Auto"/><RowDefinition Height="*"/><RowDefinition Height="Auto"/></Grid.RowDefinitions>
        <StackPanel Margin="2,0,0,12">
            <TextBlock Text="管理快速访问" Foreground="#414156" FontSize="18" FontWeight="Bold"/>
            <TextBlock Text="调整固定项顺序,主页和命令面板会立即同步" Foreground="#8D8D9F" FontSize="10" Margin="0,5,0,0"/>
        </StackPanel>
        <Border Grid.Row="1" Background="#F5F5FA" BorderBrush="#E3E3ED" BorderThickness="1" CornerRadius="13" Padding="5">
            <Grid>
                <ListBox x:Name="PinnedList" Background="Transparent" BorderThickness="0" SelectionChanged="PinnedList_SelectionChanged">
                    <ListBox.ItemTemplate>
                        <DataTemplate>
                            <Border Margin="2" Padding="10,8" Background="White" CornerRadius="10">
                                <Grid>
                                    <Grid.ColumnDefinitions><ColumnDefinition Width="38"/><ColumnDefinition Width="*"/><ColumnDefinition Width="Auto"/></Grid.ColumnDefinitions>
                                    <Image Source="{Binding IconSource}" Width="25" Height="25"/>
                                    <StackPanel Grid.Column="1" Margin="8,0" VerticalAlignment="Center"><TextBlock Text="{Binding Title}" Foreground="#45455A" FontSize="11" FontWeight="SemiBold"/><TextBlock Text="{Binding Subtitle}" Foreground="#9292A3" FontSize="8.8" Margin="0,3,0,0" TextTrimming="CharacterEllipsis"/></StackPanel>
                                    <TextBlock Grid.Column="2" Text="{Binding KindText}" Foreground="#7777C7" FontSize="8.5" VerticalAlignment="Center"/>
                                </Grid>
                            </Border>
                        </DataTemplate>
                    </ListBox.ItemTemplate>
                </ListBox>
                <TextBlock x:Name="EmptyText" Text="还没有固定项目" Foreground="#858597" HorizontalAlignment="Center" VerticalAlignment="Center" Visibility="Collapsed"/>
            </Grid>
        </Border>
        <Grid Grid.Row="2" Margin="0,12,0,0">
            <StackPanel Orientation="Horizontal">
                <Button x:Name="MoveUpButton" Content="上移" IsEnabled="False" Margin="0,0,7,0" Click="MoveUpButton_Click"/>
                <Button x:Name="MoveDownButton" Content="下移" IsEnabled="False" Margin="0,0,7,0" Click="MoveDownButton_Click"/>
                <Button x:Name="RemoveButton" Content="取消固定" IsEnabled="False" Click="RemoveButton_Click"/>
            </StackPanel>
            <Button Content="完成" HorizontalAlignment="Right" controls:ButtonAssist.IsPrimary="True" Click="CloseButton_Click"/>
        </Grid>
    </Grid>
</Page>