我需要从 GridView 中删除褪色边缘。我做了一些研究,目前下面是我的 GridView 的样子,问题是没有任何效果。有什么方法可以禁用/删除/隐藏褪色边缘吗?
<GridView
android:id="@+id/shop_grid_cart_items"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_weight="1"
android:background="#C4C4C4"
android:fadingEdge="none"
android:fadingEdgeLength="0px"
android:numColumns="1"
android:overScrollMode="never"
android:padding="20dp"
android:scrollbarStyle="outsideInset"
android:verticalSpacing="3dip"
android:requiresFadingEdge="none"
android:cacheColorHint="@android:color/transparent"
tools:listitem="@layout/shop_cart_grid_item" />
OnCreateView:cartItems.setVerticalFadingEdgeEnabled(false);
最佳答案
你可以试试这个:
android:overScrollMode="从不"
还有这里的答案: Is there a way to disable/edit the fading that a list view has at its edges?
关于android - 删除 GridView 上的 FadingEdge。安卓 hive ,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/16103226/