summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJason Monk <jmonk@google.com>2015-01-30 13:02:27 -0500
committerJason Monk <jmonk@google.com>2015-01-30 13:02:27 -0500
commit8ba572a3277f0c729a7fcce67bbf6e101667d5f9 (patch)
treee8c8b0350c74574a10a8830a1935994acd5b4255
parentd38cc749215c0e41bcb06703066c379de83d91e4 (diff)
downloadframeworks_base-8ba572a3277f0c729a7fcce67bbf6e101667d5f9.zip
frameworks_base-8ba572a3277f0c729a7fcce67bbf6e101667d5f9.tar.gz
frameworks_base-8ba572a3277f0c729a7fcce67bbf6e101667d5f9.tar.bz2
Fix QS bluetooth tile accessibility issue
Bluetooth tile was not announcing its state when the top half was clicked. This is because if handleUpdateState was triggered on the view before it became dual then it would not get all of the dual accessibility information. So if the dual state changes on a tile make sure to call handleUpdateState so it can be handled appropriately. Bug: 19155633 Change-Id: Ifd053c67d8ddd3230086517c9d479069556e8b56
-rw-r--r--packages/SystemUI/src/com/android/systemui/qs/QSPanel.java4
-rw-r--r--packages/SystemUI/src/com/android/systemui/qs/QSTileView.java3
2 files changed, 5 insertions, 2 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/qs/QSPanel.java b/packages/SystemUI/src/com/android/systemui/qs/QSPanel.java
index 974235e..4dacacf 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/QSPanel.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/QSPanel.java
@@ -423,7 +423,9 @@ public class QSPanel extends ViewGroup {
}
for (TileRecord record : mRecords) {
- record.tileView.setDual(record.tile.supportsDualTargets());
+ if (record.tileView.setDual(record.tile.supportsDualTargets())) {
+ record.tileView.handleStateChanged(record.tile.getState());
+ }
if (record.tileView.getVisibility() == GONE) continue;
final int cw = record.row == 0 ? mLargeCellWidth : mCellWidth;
final int ch = record.row == 0 ? mLargeCellHeight : mCellHeight;
diff --git a/packages/SystemUI/src/com/android/systemui/qs/QSTileView.java b/packages/SystemUI/src/com/android/systemui/qs/QSTileView.java
index bb353d5..16ae6b4 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/QSTileView.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/QSTileView.java
@@ -172,7 +172,7 @@ public class QSTileView extends ViewGroup {
}
}
- public void setDual(boolean dual) {
+ public boolean setDual(boolean dual) {
final boolean changed = dual != mDual;
mDual = dual;
if (changed) {
@@ -199,6 +199,7 @@ public class QSTileView extends ViewGroup {
setFocusable(!dual);
mDivider.setVisibility(dual ? VISIBLE : GONE);
postInvalidate();
+ return changed;
}
private void setRipple(RippleDrawable tileBackground) {