不完全理解 ScrollViewer SnappingPoints
Don't fully understand ScrollViewer SnappingPoints
我正在尝试在我的 Windows 8.1 应用程序中使用 SnappingPoints,但我并不完全理解不同类型的捕捉点:
https://msdn.microsoft.com/en-us/library/windows/apps/windows.ui.xaml.controls.snappointstype.aspx
Mandatory 和 Optional 在 SnapPointsType 枚举中究竟有什么区别?还对 MandatorySingle 和 OptionalSingle?
感到困惑
当使用触摸屏并快速滚动时(即您希望 ScrollViewer 在您移开手指后继续滚动),强制 和可选 的工作方式与 MandatorySingle 和 OptionalSingle 相同:
- Mandatory 和 Optional 让你一次滚动多个元素,但是当滚动停止时(由于惯性),当前 leftmost/uppermost 元素的 left/upper 边框需要与的边框对齐滚动查看器
- MandatorySingle 和 OptionalSingle:与上面相同,但您始终只能滚动到下一个元素
缓慢滚动时(即您希望 ScrollViewer 在您移开手指后停止滚动),Mandatory 和 MandatorySingle 工作相同方式,Optional 和 OptionalSingle:
- Mandatory 和 MandatorySingle 只允许您完全滚动元素,即如果您移开手指,当前 leftmost/uppermost 元素的 left/upper 边框需要与 ScrollViewer[=32] 的边框对齐=]
- Optional 和 OptionalSingle 让你想停就停,ScrollViewer 不会自动滚动到下一个 SnapPoint
我正在尝试在我的 Windows 8.1 应用程序中使用 SnappingPoints,但我并不完全理解不同类型的捕捉点:
https://msdn.microsoft.com/en-us/library/windows/apps/windows.ui.xaml.controls.snappointstype.aspx
Mandatory 和 Optional 在 SnapPointsType 枚举中究竟有什么区别?还对 MandatorySingle 和 OptionalSingle?
感到困惑当使用触摸屏并快速滚动时(即您希望 ScrollViewer 在您移开手指后继续滚动),强制 和可选 的工作方式与 MandatorySingle 和 OptionalSingle 相同:
- Mandatory 和 Optional 让你一次滚动多个元素,但是当滚动停止时(由于惯性),当前 leftmost/uppermost 元素的 left/upper 边框需要与的边框对齐滚动查看器
- MandatorySingle 和 OptionalSingle:与上面相同,但您始终只能滚动到下一个元素
缓慢滚动时(即您希望 ScrollViewer 在您移开手指后停止滚动),Mandatory 和 MandatorySingle 工作相同方式,Optional 和 OptionalSingle:
- Mandatory 和 MandatorySingle 只允许您完全滚动元素,即如果您移开手指,当前 leftmost/uppermost 元素的 left/upper 边框需要与 ScrollViewer[=32] 的边框对齐=]
- Optional 和 OptionalSingle 让你想停就停,ScrollViewer 不会自动滚动到下一个 SnapPoint