zoukankan      html  css  js  c++  java
  • 元素自动调整位置System.Windows.Interactivity,Microsoft.Expression.Interactions

    <Window x:Class="WpfApplication4.MainWindow"
            xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
            xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
            Title="MainWindow" Height="350" Width="525"
            xmlns:ei="clr-namespace:Microsoft.Expression.Interactivity.Layout;assembly=Microsoft.Expression.Interactions"
            xmlns:i="http://schemas.microsoft.com/expression/2010/interactivity">
        <Grid>
            <Grid.RowDefinitions>
                <RowDefinition Height="Auto"/>
                <RowDefinition Height="*"/>
            </Grid.RowDefinitions>
            <StackPanel Grid.Row="0">
                <Button Content="Add" Click="add_Click" Visibility="Hidden"/>
                <Button Content="Remove" Click="remove_Click" Visibility="Hidden"/>
            </StackPanel>
            <ListBox x:Name="listView" ItemsSource="{Binding}" Grid.Row="1">
                <ListBox.ItemTemplate>
                    <DataTemplate>
                        <Image Source="{Binding}" Height="80" Width="48" />
                    </DataTemplate>
                </ListBox.ItemTemplate>
                <ListBox.ItemsPanel>
                    <ItemsPanelTemplate>
                        <UniformGrid>
                            <i:Interaction.Behaviors>
                                <ei:FluidMoveBehavior AppliesTo="Children" Duration="0:0:0.5">
                                    <ei:FluidMoveBehavior.EaseY>
                                        <!--<BackEase EasingMode="EaseInOut" />-->
                                        <QuarticEase EasingMode="EaseInOut" />
                                    </ei:FluidMoveBehavior.EaseY>
                                    <ei:FluidMoveBehavior.EaseX>
                                        <!--<BackEase EasingMode="EaseOut"/>-->
                                        <QuarticEase EasingMode="EaseOut" />
                                    </ei:FluidMoveBehavior.EaseX>
                                </ei:FluidMoveBehavior>
                            </i:Interaction.Behaviors>
                        </UniformGrid>
                    </ItemsPanelTemplate>
                </ListBox.ItemsPanel>
            </ListBox>
    
        </Grid>
    </Window>
    
  • 相关阅读:
    第三方登录(QQ登录)开发流程详解
    编译PHP并与Ngnix整合
    Ngnix的日志管理和用定时任务完成日志切割
    Ngnix 安装、信号量、虚拟主机配置
    Redis命令操作详解
    Redis的安装和部署
    消息队列
    Ubuntu中Google Chrome安装
    关于双系统下Ubuntu不能访问Windows中某个盘的问题
    numpy.random.shuffle()与numpy.random.permutation()的区别
  • 原文地址:https://www.cnblogs.com/makubexsoft/p/2330929.html
Copyright © 2011-2022 走看看