Improvement - do not call notifyDataSetChanged when selection state is unchanged
This commit is contained in:
parent
bef966bdfe
commit
70342c8c6c
@ -70,6 +70,8 @@ class HabitCardListAdapter @Inject constructor(
|
||||
* Sets all items as not selected.
|
||||
*/
|
||||
override fun clearSelection() {
|
||||
if (selected.isEmpty()) return
|
||||
|
||||
selected.clear()
|
||||
notifyDataSetChanged()
|
||||
observable.notifyListeners()
|
||||
|
||||
Loading…
Reference in New Issue
Block a user