Flex 4 和 ScrollBar 步长
我想指定使用 VScrollBar 滚动的量。 所以在 Flex 3 中我们有“lineScrollSize”,但是这个属性在 Flex 4 中如何调用呢? 我认为它是 VScolBar.stepSize — 但它没有做任何事情。
有人请帮助我。 我只是希望我的内容在鼠标滚轮上滚动得更快。
I want to specify amount to scroll with VScrollBar.
So in Flex 3 we have "lineScrollSize" but how this property called in Flex 4?
I thought it VScrolBar.stepSize — but it dose not do anything.
Somebody please help me.
I just whant my content to scroll faster on mouse wheel.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
查看
LayoutBase.getVerticalScrollPositionDelta
。您可能想要子类化并覆盖它!这是我在自己的布局类中所做的:
Have a look into
LayoutBase.getVerticalScrollPositionDelta
. You might want to subclass and override it!Here's what I did in my own layout class:
这里有一个如何增加 mouseWheel 滚动的步长的示例:
http://forums.adobe.com/message/2783736
您应该能够取消 mouseWheel 滚动使用此增强功能会更容易一些:
http://bugs.adobe.com/jira/browse/SDK-26432
与该错误相关的子任务有一个简单的代码示例,您应该能够修改该示例以防止鼠标滚轮滚动并调用缩放逻辑:
此线程中的讨论也可能对您有用:
http://forums.adobe.com/message/3393852#3393852
There is an example of how to increase the stepSize for mouseWheel scrolling here:
http://forums.adobe.com/message/2783736
You should be able to cancel mouseWheel scrolling a little easier with this enhancement:
http://bugs.adobe.com/jira/browse/SDK-26432
The sub-task linked to that bug has a simple code sample that you should be able to modify to prevent mouse wheel scrolling and call your zooming logic instead:
The discussion in this thread might also be useful to you:
http://forums.adobe.com/message/3393852#3393852
我想出了一个解决方法,需要子类化/扩展滚动条的皮肤。
这样,您只需使用自定义滚动条,而不是修改滚动条内的每个视口,
我将其放在 Flex SDK bug 的注释中,显然不应该以
https://bugs.adobe.com/jira/browse/SDK-17288
I've come up with a workaround, which requires subclassing/extending the skins of the scrollbars.
This way you only have to use a custom scroller, rather then modify each viewport inside the scroller
I put it in the comment on the Flex SDK bug, which clearly should not have been ignored to begin with
https://bugs.adobe.com/jira/browse/SDK-17288