Thursday, March 3, 2011

[android-developers] how to understand when I am at the bottom of a page in WebView

Hi All,
How can i understand if when I am at the bottom of a web page?
When scrolling down i need to find out when i am at the bottom or very
close to it, but that proves to be a challenge.
I use onScrollChanged method /@Override protected void
onScrollChanged(int x, int y, int oldx, int oldy)/ , but the y is
probably not in the same pixels as the getContentHeight() method.
I thought that this is because of the automatic scaling that android
does if the density is not specified, but this did not helped as still
with pages that have very big height or with some that barely exceed
the screen size it act totally different.

Any Ideas on that problem? Anyone ever need to find out if onscroll it
has hit the bottom?
Is there another event, like for example "onBottomReached()" or
something? :)

--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscribe@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

No comments:

Post a Comment