From 10e71e014ad730a3960603c4e4706a61168e0b46 Mon Sep 17 00:00:00 2001 From: fisherson_lin Date: Mon, 20 Jan 2014 14:47:27 +0800 Subject: [PATCH] [Navigation bar] Allow "right to left" gesture to launch search panel Symptom: "Bottom to up" gesture can launch search panel in portrait, but "right to left" gesture CANNOT in landscape. Root Cause: Not handled. Solution: Set swapXY to handle this in landscape case. Change-Id: I1793280b3656af6912e6b4583b08e80a0a38e44a --- .../android/systemui/statusbar/phone/NavigationBarView.java | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarView.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarView.java index 839016d7a1de8..9589e8ba2443b 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarView.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarView.java @@ -521,6 +521,11 @@ public class NavigationBarView extends LinearLayout { Log.d(TAG, "reorient(): rot=" + mDisplay.getRotation()); } + // swap to x coordinate if orientation is not in vertical + if (mDelegateHelper != null) { + mDelegateHelper.setSwapXY(!mVertical); + } + setNavigationIconHints(mNavigationIconHints, true); }