summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorGabriele M <moto.falcon.git@gmail.com>2016-01-16 00:10:32 +0100
committerTom Powell <zifnab@zifnab06.net>2017-03-26 16:14:44 -0700
commitec9e531a63e193af4e90048f7faee3ef5904c6b7 (patch)
treec337b85ee07d9a5bb7ca0b27cb57858479aa3bf9 /src
parentfead876334da6f5d8c67d2a0a6788896d524a87b (diff)
downloadandroid_packages_apps_Trebuchet-ec9e531a63e193af4e90048f7faee3ef5904c6b7.tar.gz
android_packages_apps_Trebuchet-ec9e531a63e193af4e90048f7faee3ef5904c6b7.tar.bz2
android_packages_apps_Trebuchet-ec9e531a63e193af4e90048f7faee3ef5904c6b7.zip
Trebuchet: Fix NPE when app search controller is off
Change-Id: Ia6a9322e0aee3e16d4dd864fbc5a341e3f0501a8
Diffstat (limited to 'src')
-rw-r--r--src/com/android/launcher3/allapps/AllAppsContainerView.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/com/android/launcher3/allapps/AllAppsContainerView.java b/src/com/android/launcher3/allapps/AllAppsContainerView.java
index 18030b451..0e3cba83e 100644
--- a/src/com/android/launcher3/allapps/AllAppsContainerView.java
+++ b/src/com/android/launcher3/allapps/AllAppsContainerView.java
@@ -502,7 +502,8 @@ public class AllAppsContainerView extends BaseContainerView implements DragSourc
public boolean dispatchKeyEvent(KeyEvent event) {
// Determine if the key event was actual text, if so, focus the search bar and then dispatch
// the key normally so that it can process this key event
- if (!mSearchBarController.isSearchFieldFocused() &&
+ if (mSearchBarController != null &&
+ !mSearchBarController.isSearchFieldFocused() &&
event.getAction() == KeyEvent.ACTION_DOWN) {
final int unicodeChar = event.getUnicodeChar();
final boolean isKeyNotWhitespace = unicodeChar > 0 &&