采用Storyboard技术实现WPF中的图片动态滚动消失效果
发布时间
阅读量:
阅读量
在此过程中,我们采用Storyboard技术来实时呈现ListView组件中元素位置的变动情况,实际展示效果如下(与采用FluidMoveBehavior方式所实现的功能相比,前几帧图像的加载表现存在差异,而后续滚动时的消失效果则保持高度一致性)。

操作流程:
1、图像资源绑定类ListBindData.cs的实现方式与第一种方法保持一致,此处省略详细说明。
2、图像滚动效果的呈现是通过Storyboard对ListViewItem的RenderTransform属性进行动态调整来达成的。
界面xaml:
<Window x:Class="SmoothScroll.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/e
全部评论 (0)
还没有任何评论哟~
