notifyDataSetChanged多个复选框 [英] notifyDataSetChanged for multiple checkboxes
问题描述
在附加的图像,全选复选框
是一个活动present,所有复选框
中的适配器。
如果我检查全选
那么所有复选框在适配器检查,如果我未选中,则所有未被选中。事情发生得很好。
In attached image, SelectAll checkbox
is present with in an activity, and all checkboxes
within adapter.
If i checked SelectAll
then all checkboxes are checked in adapter and if I unchecked then all are unchecked. Its happening nicely.
但我想,如果我检查全选
之后,如果我 uncheked
在临屋适配器一个或多个复选框,然后在全选复选框取消选中应
。
如果不检查,以全选。如果我手动检查所有的复选框适配器则全选复选框选中要
自动。
But I want if I checked SelectAll
and after that if i uncheked
one or more checkbox in tha adapter then the SelectAll checkbox should unchecked
.
and if without check to SelectAll If i manually check all the checkboxes in adapter then SelectAll checkbox should checked
automatically.
我如何能做到这一点。
波纹管是我的code, http://pastebin.com/5pUJJC42
bellow is my code., http://pastebin.com/5pUJJC42
推荐答案
我不喜欢下面,我得到了我需要的输出,
I did like below and I got my required output,
这篇关于notifyDataSetChanged多个复选框的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!