Flex Spark List 鼠标滚轮滚动速度
我有一个扩展 Spark 列表的组件,当我使用鼠标滚轮滚动时,它一次性滚动太多。我尝试在 List 类和 VerticalLayout 类中寻找处理鼠标滚轮滚动的处理程序来覆盖,但我找不到它。
我是否应该有另一种方法来改变这个,或者我错过了什么?
I have a component extending a Spark List, and when I scroll using the mouse wheel it scrolls too much in one go. I have tried looking for the handler that deals with mouse wheel scrolling in the List class and VerticalLayout class to override but I cannot find it.
Is there another way I'm supposed to change this, or am I missing something?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
MouseEvent.MOUSE_WHEEL 的“delta”属性定义一轮滚动将滚动多少行。您可以尝试在 MOUSE_WHEEL 处理程序中更改它(在捕获阶段)。例如,以下代码将逐行滚动:
The "delta" property of MouseEvent.MOUSE_WHEEL defines how many lines will be scrolled by one wheel-scrolling. You could try changing it in the MOUSE_WHEEL handler (during capture phase). For example the following code will scroll line-by-line:
“horizontalLineScrollSize”和“verticalLineScrollSize”属性确定当用户选择滚动条箭头时要滚动的像素数。 “verticalLineScrollSize”属性还控制使用“鼠标滚轮”时的滚动量。默认值为 5 像素。
“horizontalPageScrollSize”和“verticalPageScrollSize”属性确定当用户选择“滚动条轨道”时要滚动的像素数。默认值为 20 像素。
更多详细信息:http://livedocs.adobe.com/ flex/3/html/help.html?content=containers_intro_4.html
The "horizontalLineScrollSize" and "verticalLineScrollSize" properties determine how many pixels to scroll when the user selects the scroll bar arrows. The "verticalLineScrollSize" property also controls the amount of scrolling when using the "mouse wheel". The default value is 5 pixels.
The "horizontalPageScrollSize" and "verticalPageScrollSize" properties determine how many pixels to scroll when the user selects the "scroll bar track". The default value is 20 pixels.
More details: http://livedocs.adobe.com/flex/3/html/help.html?content=containers_intro_4.html