summaryrefslogtreecommitdiffstats
path: root/packages
diff options
context:
space:
mode:
authorJoe Onorato <joeo@google.com>2010-11-27 17:24:14 -0800
committerJoe Onorato <joeo@google.com>2010-11-27 17:32:41 -0800
commitaf5e4da2a5766198f533f1ff9e2072d2cd5c63d4 (patch)
treef7a99e743852c1ffa0d78bebe099c68e39061498 /packages
parentdff2e9a4582e400e4935608ef5c744680990c335 (diff)
downloadframeworks_base-af5e4da2a5766198f533f1ff9e2072d2cd5c63d4.zip
frameworks_base-af5e4da2a5766198f533f1ff9e2072d2cd5c63d4.tar.gz
frameworks_base-af5e4da2a5766198f533f1ff9e2072d2cd5c63d4.tar.bz2
Don't crash when there's a flood of tickers.
Tell if the queue is empty, not if there's currently something showing. Change-Id: I6d8530d4c749a7566419741710d588005a698e1a
Diffstat (limited to 'packages')
-rw-r--r--packages/SystemUI/src/com/android/systemui/statusbar/tablet/TabletTicker.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/tablet/TabletTicker.java b/packages/SystemUI/src/com/android/systemui/statusbar/tablet/TabletTicker.java
index 5a464f4..e7537f0 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/tablet/TabletTicker.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/tablet/TabletTicker.java
@@ -76,7 +76,7 @@ public class TabletTicker extends Handler {
mQueue[mQueuePos] = notification;
// If nothing is running now, start the next one
- if (mCurrentNotification == null) {
+ if (mQueuePos == 0) {
sendEmptyMessage(MSG_ADVANCE);
}
@@ -87,7 +87,7 @@ public class TabletTicker extends Handler {
public void halt() {
removeMessages(MSG_ADVANCE);
- if (mCurrentView != null) {
+ if (mCurrentView != null || mQueuePos != 0) {
final int N = mQueue.length;
for (int i=0; i<N; i++) {
mQueue[i] = null;