[android-developers] Re: How to force to update a view?
Try to call the method View.invalidate(). The view must also be active to work. On May 22, 7:34 pm, Max Salley wrote: > I'm having a similar issue with an ImageView based class that uses > Matrix transformations. I update the Matrix with setImageMatrix, but > the view does not update. how can I get the view to update? > > On May 22, 5:31 am, Gavin wrote: > > > Hello, > > I have a List activity which use cursor adapter. When an item of > > database is changed, I hope the corresponding view of this list can > > update and get new data from database. > > > I know the time when database is changed, but how to update view? > > > thanks. > > --~--~-~--~~~---~--~~ 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-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: How to force to update a view?
It can work. thanks. On May 25, 11:13 am, Christine wrote: > A call to notifyDatasetChanged lets the list adapter know that the > dataset has changed and it should update the view. > > On May 24, 7:16 pm, Gavin wrote: > > > But I insert an item to database from an activity, the list activity > > cannot update data.I guess it cannot get notification. > > > On May 23, 1:10 am, Marco Nelissen wrote: > > > > This should normally happen automatically: when the database changes, the > > > cursor adapter is notified, which causes the cursor to be requeried and > > > the > > > the listview to be updated. > > > > On Fri, May 22, 2009 at 2:31 AM, Gavin wrote: > > > > > Hello, > > > > I have a List activity which use cursor adapter. When an item of > > > > database is changed, I hope the corresponding view of this list can > > > > update and get new data from database. > > > > > I know the time when database is changed, but how to update view? > > > > > thanks.- Hide quoted text - > > > - Show quoted text - --~--~-~--~~~---~--~~ 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-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: How to force to update a view?
A call to notifyDatasetChanged lets the list adapter know that the dataset has changed and it should update the view. On May 24, 7:16 pm, Gavin wrote: > But I insert an item to database from an activity, the list activity > cannot update data.I guess it cannot get notification. > > On May 23, 1:10 am, Marco Nelissen wrote: > > > > > This should normally happen automatically: when the database changes, the > > cursor adapter is notified, which causes the cursor to be requeried and the > > the listview to be updated. > > > On Fri, May 22, 2009 at 2:31 AM, Gavin wrote: > > > > Hello, > > > I have a List activity which use cursor adapter. When an item of > > > database is changed, I hope the corresponding view of this list can > > > update and get new data from database. > > > > I know the time when database is changed, but how to update view? > > > > thanks.- Hide quoted text - > > - Show quoted text - --~--~-~--~~~---~--~~ 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-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: How to force to update a view?
a call to notifyDatasetChanged updates the view. On May 24, 7:16 pm, Gavin wrote: > But I insert an item to database from an activity, the list activity > cannot update data.I guess it cannot get notification. > > On May 23, 1:10 am, Marco Nelissen wrote: > > > > > This should normally happen automatically: when the database changes, the > > cursor adapter is notified, which causes the cursor to be requeried and the > > the listview to be updated. > > > On Fri, May 22, 2009 at 2:31 AM, Gavin wrote: > > > > Hello, > > > I have a List activity which use cursor adapter. When an item of > > > database is changed, I hope the corresponding view of this list can > > > update and get new data from database. > > > > I know the time when database is changed, but how to update view? > > > > thanks.- Hide quoted text - > > - Show quoted text - --~--~-~--~~~---~--~~ 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-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: How to force to update a view?
But I insert an item to database from an activity, the list activity cannot update data.I guess it cannot get notification. On May 23, 1:10 am, Marco Nelissen wrote: > This should normally happen automatically: when the database changes, the > cursor adapter is notified, which causes the cursor to be requeried and the > the listview to be updated. > > On Fri, May 22, 2009 at 2:31 AM, Gavin wrote: > > > Hello, > > I have a List activity which use cursor adapter. When an item of > > database is changed, I hope the corresponding view of this list can > > update and get new data from database. > > > I know the time when database is changed, but how to update view? > > > thanks. --~--~-~--~~~---~--~~ 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-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: How to force to update a view?
I'm having a similar issue with an ImageView based class that uses Matrix transformations. I update the Matrix with setImageMatrix, but the view does not update. how can I get the view to update? On May 22, 5:31 am, Gavin wrote: > Hello, > I have a List activity which use cursor adapter. When an item of > database is changed, I hope the corresponding view of this list can > update and get new data from database. > > I know the time when database is changed, but how to update view? > > thanks. --~--~-~--~~~---~--~~ 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-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: How to force to update a view?
This should normally happen automatically: when the database changes, the cursor adapter is notified, which causes the cursor to be requeried and the the listview to be updated. On Fri, May 22, 2009 at 2:31 AM, Gavin wrote: > > Hello, > I have a List activity which use cursor adapter. When an item of > database is changed, I hope the corresponding view of this list can > update and get new data from database. > > I know the time when database is changed, but how to update view? > > thanks. > > > --~--~-~--~~~---~--~~ 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-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---