开发者

BlackBerry PaneManager (MVC) - how to block scrolling out of bounds

开发者 https://www.devze.com 2023-04-03 06:59 出处:网络
How do I disable the \"elastic\" scrolling in a BlackBerry PaneManagerModel/View and HorizontalScrollableTitleVie开发者_运维技巧w/HorizontalScrollableController?

How do I disable the "elastic" scrolling in a BlackBerry PaneManagerModel/View and HorizontalScrollableTitleVie开发者_运维技巧w/HorizontalScrollableController?

I mean: when I drag the leftmost pane to the right (dragging the title bar), the white background appears, and when I lift my finger, it bounces back.

I find it very annoying, I suppose it's a feature of the PaneManagerView, or the HorizontalScrollableTitleView, can I disable it?


What about adding a ScrollChangeListener to the View that adjusts the scroll whenever it goes beyond the bounds? For example:

public void scrollChanged(Manager mgr, int newHorizScroll, int newVertScroll) {
    if (newHorizScroll < 0) {
        setHorizontalScroll(0);
    }
    // and so on
}
0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号