Reputation: 2973
I have used HorizontalListView which does the functioning of ListView
but in horizontal manner. This HorizontalListView doesn't show fadingEdge
on scroll to first and last items of the list.So I need to add fadingEdge
on this view.I may find the scroll of first and last child,but I don't have any idea on how to show fadingEdge
when scroll reaches to first and last child as done in ListView
.Further I have already added
<com.ui.widgets.HorizontalListView
android:id="@+id/horizontalListView"
android:layout_width="fill_parent"
android:layout_height="120dip"
android:gravity="left"
android:fadingEdge="horizontal"/>
And it doesn't have any effect.So could you point me in the right direction on how to programmatically add fadingEdge
to the HorizontalListView
Upvotes: 0
Views: 3014
Reputation: 116
Try using the android:overScrollMode
attribute.
Just add
android:overScrollMode="always"
to your View.
android:overScrollMode can have three values: "always", "never", "ifContentScrolls".
Upvotes: 0
Reputation: 15280
From the documentation for fadingEdge
:
This attribute is deprecated and will be ignored as of API level 14 (
ICE_CREAM_SANDWICH
). Using fading edges may introduce noticeable performance degradations and should be used only when required by the application's visual design. To request fading edges with API level 14 and above, use theandroid:requiresFadingEdge
attribute instead.
Upvotes: 2