3 Commits

Author SHA1 Message Date
haodong
f91a1eba99 Revert "[ChipGroup] Fix ChipGroup.getCheckedChipIds() returns wrong state"
This reverts commit 0356d7c391c4aa64e54a5aa398d58def673d0114.
2022-05-25 13:04:44 -07:00
conradchen
0356d7c391 [ChipGroup] Fix ChipGroup.getCheckedChipIds() returns wrong state
In the Chip implementation, onCheckedChangeListener was called before onCheckedChangeListenerInternal. This causes an issue that in onCheckedChangeListener's callback, the checkable group's checked state is not updated yet, therefore ChipGroup.getCheckedChipIds() will return the outdated checked state.

Fixes this by overriding Chip.setOnCheckedChangeListener to get full control of the execution order between onCheckedChangeListener and onCheckedChangeListenerInternal.

Resolves https://github.com/material-components/material-components-android/issues/2691

PiperOrigin-RevId: 449100861
(cherry picked from commit 413a0479574b66be74f42bf9e8a11e1245c72a09)
2022-05-25 10:55:56 -07:00
cketcham
077fce370c Add support for robolectric tests with resources in gradle
PiperOrigin-RevId: 215221262
2018-10-01 12:28:30 -04:00