android - Drag Listview Item on Top -


how drag array item when code execute?

<listview         android:layout_width="match_parent"         android:layout_height="match_parent"         android:layout_alignparentleft="true"         android:id="@+id/listview"         android:layout_alignparentstart="true"         android:layout_alignparenttop="true" /> 

­­­­­­­­­­­­­­­­­­­­­

for drag listview item on top means 0th position:

getlistview().setselection(0); 

for smooth scroll:

getlistview().smoothscrolltoposition(0); 

use property. hope help...


Comments

Popular posts from this blog

html - How to set bootstrap input responsive width? -

javascript - Highchart x and y axes data from json -

javascript - Get js console.log as python variable in QWebView pyqt -