?
?鄭州app開發過程中遇到用NestedScrollView處理遮擋問題。那么如何處理呢?
其實是需要在布局中加入NestedScrollView就可以了。下面是布局代碼:
{androidx.core.widget.NestedScrollView
android:layout_width="match_parent"
android:layout_height="match_parent"}
{/androidx.core.widget.NestedScrollView}
只需要把代碼放進NestedScrollView其中就可以,就可以避免遮擋問題了,只不過在這里要提醒大家一下,NestedScrollView里面只能有一個控件,或者說只能有一個孩子,不能有兩個以及以上控件孩子,不然會報錯的。