Merge "Minor tweak to initial paging state."
diff --git a/packages/SystemUI/src/com/android/systemui/recents/RecentsConfiguration.java b/packages/SystemUI/src/com/android/systemui/recents/RecentsConfiguration.java
index cdfad18..53c10b7 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/RecentsConfiguration.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/RecentsConfiguration.java
@@ -115,8 +115,8 @@
         // Recompute some values based on the given state, since we can not rely on the resource
         // system to get certain values.
         boolean isLandscape = windowRect.width() > windowRect.height();
-        hasTransposedNavBar = isLandscape && isLargeScreen && !isXLargeScreen;
-        hasTransposedSearchBar = isLandscape && isLargeScreen && !isXLargeScreen;
+        hasTransposedNavBar = isLandscape && !isXLargeScreen;
+        hasTransposedSearchBar = isLandscape && !isXLargeScreen;
     }
 
     /**
diff --git a/packages/SystemUI/src/com/android/systemui/recents/model/TaskStack.java b/packages/SystemUI/src/com/android/systemui/recents/model/TaskStack.java
index e313fd2..7a98393 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/model/TaskStack.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/model/TaskStack.java
@@ -137,7 +137,7 @@
 
     /** Returns the index of this task in the list of filtered tasks */
     int indexOf(Task t) {
-        if (mTaskIndices.containsKey(t.key)) {
+        if (t != null && mTaskIndices.containsKey(t.key)) {
             return mTaskIndices.get(t.key);
         }
         return -1;
diff --git a/packages/SystemUI/src/com/android/systemui/recents/views/RecentsView.java b/packages/SystemUI/src/com/android/systemui/recents/views/RecentsView.java
index a9f570e..a0a1bac 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/views/RecentsView.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/views/RecentsView.java
@@ -521,7 +521,7 @@
 
     public final void onBusEvent(DraggingInRecentsEndedEvent event) {
         ViewPropertyAnimator animator = animate();
-        if (event.velocity > ViewConfiguration.get(getContext()).getScaledMinimumFlingVelocity()) {
+        if (event.velocity > mFlingAnimationUtils.getMinVelocityPxPerSecond()) {
             animator.translationY(getHeight());
             animator.withEndAction(new Runnable() {
                 @Override