Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b922452b authored by Tony Wickham's avatar Tony Wickham
Browse files

Fix NPEs when swiping up from keyguard

- In onRecentsAnimationCanceled
- In applyLoadPlan

Test: Lock screen from home screen, swipe up from bottom of keyguard
Fixes: 197622171
Change-Id: Ibb6b292cb99ad2f08e402c1a6e311b819c5f7d73
parent e55c0feb
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -805,7 +805,9 @@ public abstract class AbsSwipeUpHandler<T extends StatefulActivity<S>,
        mActivityInitListener.unregister();
        mStateCallback.setStateOnUiThread(STATE_GESTURE_CANCELLED | STATE_HANDLER_INVALIDATED);

        if (mRecentsAnimationTargets != null) {
            TaskViewUtils.setDividerBarShown(mRecentsAnimationTargets.nonApps, true);
        }

        // Defer clearing the controller and the targets until after we've updated the state
        mRecentsAnimationController = null;
+3 −1
Original line number Diff line number Diff line
@@ -1351,9 +1351,11 @@ public abstract class RecentsView<ACTIVITY_TYPE extends StatefulActivity<STATE_T
                }
                Log.d(TASK_VIEW_ID_CRASH, "taskViewCount: " + getTaskViewCount()
                        + " " + sb.toString());
            }
                mRunningTaskViewId = -1;
            } else {
                mRunningTaskViewId = newRunningTaskView.getTaskViewId();
            }
        }

        if (mNextPage == INVALID_PAGE) {
            // Set the current page to the running task, but not if settling on new task.