There is one: call getFirstVisiblePosition / getLastVisiblePosition,
iterate over the currently visible children, and update them, matching
each to the model data.
There are some gotchas, like the ListView potentially being out of sync
with the model data (in the middle of a layout), but nothing that can't
be dealt with.
This avoids having to call notifyDataSetChanged, which rebinds all
currently visible item layouts, so can be a lot faster in cases where it
counts.
Don't know if you would consider it a "good" way.... well, I do, for
those special cases.
-- Kostya
29.09.2011 0:01, Studio LFP пишет:
There's not a good way that I know of to directly access the view in
the ListView and update them directly. I've seen a couple of ways
posted, but you have to jump through a ton of hoops and it can get
ugly and unreliable.
--
Kostya Vasilyev
--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en