У меня есть ListView с анимацией. Анимация хорошо воспроизводится при первой загрузке ListView. Я хочу, чтобы анимация воспроизводилась при смене курсора.
<ListView
android:id="@android:id/list"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:cacheColorHint="@android:color/transparent"
android:divider="@drawable/gradienthorizontal"
android:dividerHeight="1px"
android:layoutAnimation="@anim/layout_cascade"
android:listSelector="@drawable/selector" >
</ListView>
Я меняю курсор здесь:
private void majCurseurListe(long id, boolean choixvente) {
Cursor curseurPtVente = null;
if (choixvente) {
curseurPtVente = mDbHelper
.listePtsVentes(DBhelper.TYPE_PTVENTE, id);
} else {
curseurPtVente = mDbHelper.listePtsVentes(DBhelper.TYPE_PTSERVICE,
id);
}
// Android s'occupe du cycle de vie du curseur
startManagingCursor(curseurPtVente);
((CursorAdapter) getListAdapter()).changeCursor(curseurPtVente);
}