diff options
author | Jorge Ruesga <jorge@ruesga.com> | 2013-04-07 03:45:13 +0200 |
---|---|---|
committer | Jorge Ruesga <jorge@ruesga.com> | 2013-04-07 03:45:13 +0200 |
commit | f9da888acd294f09ed9604e632b815aa4cfd6c83 (patch) | |
tree | d3990cbe366cab722170e6da469c09ee2289e5ce /src | |
parent | 6d0f70193ad5f674099d3b1de25174eedbcebaff (diff) | |
download | packages_apps_trebuchet-f9da888acd294f09ed9604e632b815aa4cfd6c83.zip packages_apps_trebuchet-f9da888acd294f09ed9604e632b815aa4cfd6c83.tar.gz packages_apps_trebuchet-f9da888acd294f09ed9604e632b815aa4cfd6c83.tar.bz2 |
Trebuchet: Fix NPE
This change fixes a NPE for the overflow menu. Steps:
1.- A device with no physical menu
2.- Install another launcher (xe Launcher2) (overflow menu is only displayed when Trebuchet runs
outside CM or when multiple launchers exists)
3.- Access AllAppDrawer and tap the overflow menu
4.- Tap again the overflow menu or rotate the screen and tap the overflow menu.
5.- NPE
The overflow menu is not recreated in onCreateOptionsMenu when isWorkspaceLocked(). The change
checks if the user is on the AllAppDrawer and forces the recreation of the menu.
Change-Id: Id68dd1f7b0c09a2f62b5f6d4fbef6f217bf98e82
Signed-off-by: Jorge Ruesga <jorge@ruesga.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/com/cyanogenmod/trebuchet/Launcher.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/com/cyanogenmod/trebuchet/Launcher.java b/src/com/cyanogenmod/trebuchet/Launcher.java index b1c1425..b8a3224 100644 --- a/src/com/cyanogenmod/trebuchet/Launcher.java +++ b/src/com/cyanogenmod/trebuchet/Launcher.java @@ -1744,7 +1744,7 @@ public final class Launcher extends Activity @Override public boolean onCreateOptionsMenu(Menu menu) { - if (isWorkspaceLocked()) { + if (!isAllAppsVisible() && isWorkspaceLocked()) { return false; } |