View 的 scrollBy和scrollTo

Scrolling
The framework provides basic support for views that wish to internally scroll their content. This includes keeping track of the X and Y scroll offset as well as mechanisms for drawing scrollbars. See scrollBy(int, int), scrollTo(int, int), and awakenScrollBars() for more details.

scrollBy是将view的内容移动多大的距离,而scrollTo是将view的内容移动到那个点上。
http://www.javaworld.com.tw/jute/post/view?bid=26&id=273508

注意:scroll是scroll their content移动view的内容非view本身。你可以把view和view的内容分开来看,让其中一个作为参照物进行对比就可以理解了。

你可能感兴趣的:(scroll)