I added web view to my android studio project(activity_main.xml).also added progress bar,swipe refresh layout also.So when scrolling web page three or four times,page goes top indefinitely.It doesn't stop at bottom.can help me to stop this headache.I added my xml code below.
<androidx.swiperefreshlayout.widget.SwipeRefreshLayout
android:id="@+id/swipe"
android:layout_width="match_parent"
android:layout_height="match_parent">
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_alignParentTop="true"
android:layout_centerInParent="true"
android:orientation="vertical">
<LinearLayout
android:id="@+id/liProgressContainer"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical">
<ProgressBar
android:id="@+id/progressBar"
style="@style/Widget.AppCompat.ProgressBar.Horizontal"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="#FFFFFF"
android:indeterminate="true" />
<TextView
android:id="@+id/tvLoadingPercentage"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="#FFFFFF" />
</LinearLayout>
<androidx.core.widget.NestedScrollView
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_below="@id/liProgressContainer">
<WebView
android:id="@+id/webView"
android:layout_width="match_parent"
android:layout_height="match_parent" />
</androidx.core.widget.NestedScrollView>
</RelativeLayout>
</androidx.swiperefreshlayout.widget.SwipeRefreshLayout>
<com.google.android.gms.ads.AdView xmlns:ads="http://schemas.android.com/apk/res-auto"
android:id="@+id/adView"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:layout_centerHorizontal="true"
ads:adSize="BANNER"
ads:adUnitId="ca-app-pub-3940256099942544/6300978111" />