diff options
author | Joe Onorato <joeo@android.com> | 2010-03-23 14:04:42 -0700 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2010-03-23 14:04:42 -0700 |
commit | da6759fba8879e8fe3cf9548f4a48029eb18a1fb (patch) | |
tree | 8ede3be77b4a5015b8a71d7337724002a49b8af1 /src | |
parent | 693599f27be9f3f2d59d3205283133b5b504d3c8 (diff) | |
parent | c5210eb3845e14cdef8de6df625060778e974f1d (diff) | |
download | android_packages_apps_Trebuchet-da6759fba8879e8fe3cf9548f4a48029eb18a1fb.tar.gz android_packages_apps_Trebuchet-da6759fba8879e8fe3cf9548f4a48029eb18a1fb.tar.bz2 android_packages_apps_Trebuchet-da6759fba8879e8fe3cf9548f4a48029eb18a1fb.zip |
Merge "Fix 2519335 - Caused by NPE. Here's another place where it needs to be ok for sRS to be null."
Diffstat (limited to 'src')
-rw-r--r-- | src/com/android/launcher2/AllApps3D.java | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/src/com/android/launcher2/AllApps3D.java b/src/com/android/launcher2/AllApps3D.java index 8467b3953..d81b44297 100644 --- a/src/com/android/launcher2/AllApps3D.java +++ b/src/com/android/launcher2/AllApps3D.java @@ -194,8 +194,10 @@ public class AllApps3D extends RSSurfaceView } public void surrender() { - sRS.contextSetSurface(0, 0, null); - sRS.mMessageCallback = null; + if (sRS != null) { + sRS.contextSetSurface(0, 0, null); + sRS.mMessageCallback = null; + } mSurrendered = true; } @@ -1022,11 +1024,15 @@ public class AllApps3D extends RSSurfaceView } void pause() { - sRS.contextBindRootScript(null); + if (sRS != null) { + sRS.contextBindRootScript(null); + } } void resume() { - sRS.contextBindRootScript(mScript); + if (sRS != null) { + sRS.contextBindRootScript(mScript); + } } class Params extends BaseAlloc { |