Fix quickswitch flickers/ignored swipes

- Don't set current page to running task when applying load plan,
  if we are already settling on a new task to launch.
- When starting a new task, finish to the running app if that's
  the task being started (should not happen with above change)
- When disabling free scroll mode, don't snap to a page if we're
  already on it. This was setting mNextPage so the first check
  was falsing.

Bug: 142068081
Change-Id: I5b392d9726a81c51718d2f94eee6cd4f78b61f69
diff --git a/src/com/android/launcher3/PagedView.java b/src/com/android/launcher3/PagedView.java
index 5c790f3..ff2b400 100644
--- a/src/com/android/launcher3/PagedView.java
+++ b/src/com/android/launcher3/PagedView.java
@@ -1088,7 +1088,9 @@
         if (mFreeScroll) {
             setCurrentPage(getNextPage());
         } else if (wasFreeScroll) {
-            snapToPage(getNextPage());
+            if (getScrollForPage(getNextPage()) != getScrollX()) {
+                snapToPage(getNextPage());
+            }
         }
     }