WPF Scrollviewer PanningMode 移动窗口? [英] WPF Scrollviewer PanningMode move Window?

查看:82
本文介绍了WPF Scrollviewer PanningMode 移动窗口?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用 ScrollViewer.PanningMode 在我的 WPF4 窗口中添加了一个 ScrollViewer.当我在多点触控屏幕上拖动滚动查看器时,一切正常.但是......当我到达顶部滚动或底部滚动时,窗口会随着滚动而移动.我们如何避免这种情况?

I have add a ScrollViewer in my WPF4 Window with ScrollViewer.PanningMode. When I drag scrollviewer on my multitouch screen it's OK. But... the Window move with scroll when I arrive on top scroll or bottom scroll. How can we avoid this?

推荐答案

完成答案:有一个本机事件可以标记为已处理:ManipulationBoundaryFeedback

To complete the answer: There is a native event for this which can just be marked as handled: ManipulationBoundaryFeedback

这种运动称为边界反馈,由操作系统管理(用户可以在平移上的Pen and Touch设置中进行设置)代码>标签).我不知道 Windows API 是否允许您阻止它,此页面 可能是相关的.

This movement is called boundary feedback which is governed by the operating system (can be set by users in the Pen and Touch settings on the Panning tab). I do not know if the Windows API allows you to prevent it, this page might be relevant.

这篇关于WPF Scrollviewer PanningMode 移动窗口?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆