Sunday, January 30, 2011

[android-developers] Re: Couldn't refresh list

Tnx for helping Kostya.


I have changed it to:


PersonalNoteData pn = saveNote(n);
if(pn != null){
ia.add(pn);
}
ia.notifyDataSetChanged();


And saveNote returns null if object exist and saves and returns object
if it's new.

Now it works.


How do you mean to use convertView?.


On Jan 30, 9:42 am, Kostya Vasilyev <kmans...@gmail.com> wrote:
> Make sure that the two lines below actually update data that's
> referenced by getView.
>
> Also, your getView ignores "convertView" and so prevents item view
> recycling. For better performance and memory usage, might be a good idea
> to fix that.
>
> -- Kostya
>
> 30.01.2011 11:14, vnv пишет:
>
> >                            saveNote(etNote.getText().toString());
> >                            notes = getNotes();
>
> --
> Kostya Vasilyev -- WiFi Manager + pretty widget --http://kmansoft.wordpress.com

--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscribe@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

No comments:

Post a Comment