The nuance is that I need to make a sweep, for example, to the bottom of a specific WebView, but the data in the WebView is loaded after creating the markup, and apparently because of this, the ScrollView data on the size of the layout elements is incorrect / irrelevant, so either it’s not scrolling at all, or scrolls to a shorter length than the item with loaded content. Tell me how to handle a scroll in such a situation, if at all possible? Or, perhaps, how to update the status of the children of ScrollView? Although I should have a click on the button, but for verification I tried to scroll immediately after downloading the content like this:
mWebView.setWebViewClient(new WebViewClient() { @Override public void onPageFinished(WebView view, String url) { super.onPageFinished(view, url); mWebView.scrollTo(0, 2000); } }
And the result is zero. Maybe someone will throw at least some direction where to dig, how to overcome this problem? webview
don’t need to scroll webview
itself; all content can fit in a few lines; ScrollView
should be ScrollView
to the height of a specific webview or to the bottom of a specific webview
, that is, it is normal for scrollView.scrollTo(0, myWebView.getBottom())
or scrollView.scrollTo(0, myWebView.getContentHeight())
ScrollView
, why do you scroll through theWebView
? - Vladyslav Matviienko