OSDN Git Service

Fix non responding slice toggling
authorYi-Ling Chuang <emilychuang@google.com>
Mon, 7 Oct 2019 02:24:27 +0000 (10:24 +0800)
committerYi-Ling Chuang <emilychuang@google.com>
Mon, 14 Oct 2019 01:31:50 +0000 (09:31 +0800)
commitddf6cefcaccf669150bb4d61e37c1d78ccbe91b0
tree622247935a451724b073867e8c5699a18a477e95
parent764115ca4e1dbb594f4ff5eac5cc606cff7c9dd9
Fix non responding slice toggling

The issue happens when users are toggling slices. Sometimes the toggle
doesn't work as expected because the pending intent of the toggle action
seems to be canceled for some reasons.

Hence, we replace FLAG_CANCEL_CURRENT with FLAG_UPDATE_CURRENT to
prevent from getting PendingIntent.CancelExcpetion from SliceActionView
when toggling slices.

This change only applies on those auto converted Slices.

Bug: 142107748
Test: toggle slices in Settings Search and NGA
Change-Id: Iff724ce5f6a1e6a7d9ca85b8ce76539a72e72964
src/com/android/settings/slices/SliceBuilderUtils.java