Fixing issue where home was triggered on top of other activities being launched. (Bug 16823617)
- Also fixes issue with the Recents hide message being clobbered
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/CommandQueue.java b/packages/SystemUI/src/com/android/systemui/statusbar/CommandQueue.java
index 9107790..63dd1e3 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/CommandQueue.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/CommandQueue.java
@@ -89,7 +89,7 @@
boolean showImeSwitcher);
public void setHardKeyboardStatus(boolean available, boolean enabled);
public void showRecentApps(boolean triggeredFromAltTab);
- public void hideRecentApps(boolean triggeredFromAltTab);
+ public void hideRecentApps(boolean triggeredFromAltTab, boolean triggeredFromHomeKey);
public void toggleRecentApps();
public void preloadRecentApps();
public void cancelPreloadRecentApps();
@@ -191,11 +191,12 @@
}
}
- public void hideRecentApps(boolean triggeredFromAltTab) {
+ public void hideRecentApps(boolean triggeredFromAltTab, boolean triggeredFromHomeKey) {
synchronized (mList) {
mHandler.removeMessages(MSG_HIDE_RECENT_APPS);
mHandler.obtainMessage(MSG_HIDE_RECENT_APPS,
- triggeredFromAltTab ? 1 : 0, 0, null).sendToTarget();
+ triggeredFromAltTab ? 1 : 0, triggeredFromHomeKey ? 1 : 0,
+ null).sendToTarget();
}
}
@@ -306,7 +307,7 @@
mCallbacks.showRecentApps(msg.arg1 != 0);
break;
case MSG_HIDE_RECENT_APPS:
- mCallbacks.hideRecentApps(msg.arg1 != 0);
+ mCallbacks.hideRecentApps(msg.arg1 != 0, msg.arg2 != 0);
break;
case MSG_TOGGLE_RECENT_APPS:
mCallbacks.toggleRecentApps();