Jump to content

ListView se positionner en haut de la liste


loudo

Recommended Posts

ça marche.

C'est vraiment bizarre de devoir réaffecter l'adapter !

Je modifie le contenu, ensuite j'appelle la méthode notifyDataSetChanged et je pensais pas qu'il fallait réaffecter l'adapter ensuite pour initialiser la vue.

Merci

Edited by loudo
Link to comment
Share on other sites

ben c'est toi qui veut te repositionner en haut de la liste, et a part comme ça je ne sais pas :)

Sinon la listview est intelligente, si tu modifies la source de données dans ton adapter et appel notifyDataSetChanged, ça remonte pas en haut de la liste, ça fait que mettre à jour la liste, sans deranger l'utilisateur.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...