简体   繁体   English

C#WinRT / Metro应用程序-ScrollViewer分页

[英]C# WinRT/Metro app - ScrollViewer paging

I need to implement horizontal paging functionality on ScrollViewer like in iOS. 我需要像在iOS中那样在ScrollViewer上实现水平分页功能。 To do that I need to catch the event when ScrollViewer did ends decelerating, but ScrollViewer doesn't have that kind of events like in IOS, eg 为此,我需要在ScrollViewer确实结束减速时捕获事件,但是ScrollViewer没有像IOS这样的事件,例如
-scrollViewDidEndDecelerating:
-scrollViewDidEndScrollingAnimation: ,etc... -scrollViewDidEndScrollingAnimation:

Does any one know how to catch those events, or suggest a better method how to achieve paging functionality, or may be you know a 3rd party already implemented ScrollViewer with paging? 是否有人知道如何捕获这些事件,或者提出了一种更好的方法来实现分页功能,或者您知道第3方已经通过分页实现了ScrollViewer?

I'm not sure what paging means in iOS, but if I am guessing correctly - you might be interested in looking at HorizontalSnapPointsAlignment and HorizontalSnapPointsType properties. 我不确定分页在iOS中的含义,但是如果我猜对了,您可能会对查看HorizontalSnapPointsAlignmentHorizontalSnapPointsType属性感兴趣。 Or even better just use the FlipView control. 甚至更好的方法是使用FlipView控件。 The two properties will allow the ScrollViewer to automatically snap to elements of the ItemsPanel(Root) , so for example if the panel is an (Items)StackPanel - it will snap to the elements of that and thus give you the page snap behavior in a control similar to the FlipView . 这两个属性将允许ScrollViewer自动捕捉到ItemsPanel(Root)元素,因此例如,如果面板是(Items)StackPanel它将捕捉到该元素的元素,从而为您提供页面捕捉行为控件类似于FlipView

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Win8 Javascript Metro App,带有C#WinRT组件和SQLite - Win8 Javascript Metro App, with C# WinRT Component and SQLite 在C#Metro / WinRT应用中使用CAST加密 - Using CAST encryption in a C# Metro/WinRT app 在WinRT Metro App C#中获取操作系统版本 - Get OS-Version in WinRT Metro App C# C#Winrt / Metro应用程序,WebView自定义字体 - C# winrt/metro app, WebView custom font 如何在WinRT Metro App C#中配置应用程序以使用实时Coonect API? - How to configure app to use live coonect api in winRT metro app c#? 如何序列化和反序列化字典 <string,object> 在WinRT中(C#和XAML中的Metro应用)? - How to serialize and deserliaze a Dictionary<string,object> in WinRT (Metro app in C# and XAML)? 如何在C#Windows应用商店应用(又名WinRT / Metro)中创建查询字符串? - How do I create a query string in a C# Windows Store App (a.k.a. WinRT/Metro)? Windows 8 Metro ListView-无法禁用ScrollViewer(C#/ XAML) - Windows 8 Metro ListView - can't disable ScrollViewer (C#/XAML) C#Windows 8 Store(Metro,WinRT)字节数组到BitmapImage - C# Windows 8 Store (Metro, WinRT) Byte array to BitmapImage 在应用内购买,WinRT,C# - In app purchase, WinRT, C#
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM