Merging ub-launcher3-master, build 6003980
Bug:124967099 P2 Support 5 column layout for all apps (independent of what the workspace layout is) Bug:126596417 P2 [Gesture Nav] Polish quick switch from home screen Bug:136278866 P2 Temporary workarounds to make tests pass on Cuttlefish Bug:136282913 P1 Swipe up from Assistant Fulfillment Card Jank Bug:138473688 P4 Home settings can't be dismissed by swipe up Bug:138944598 P4 Merge TaskIconCache into IconCache Bug:139137636 P2 Create memory tests for Launcher Bug:139661510 P1 Quickswitch over NGA half shelf doesn't work Bug:139663018 P2 A home screen shortcut to the Files app keeps being added without my ok. Bug:140242324 P2 Cache shortcutInfo icons in Launcher Bug:140252765 P2 Audit Gesture Nav tests (including Back and Quick Switch) Bug:140337263 P2 Empty launcher (DecorView visibility==4) Bug:141265005 P4 Overview task should not be tiny if prediction list is shown instead of hotseat Bug:141484300 P4 Re-enable flicker tests Bug:141556707 P1 Non-badged work profile app shortcuts getting created on the launcher. Bug:141568904 P1 Launcher: Unable to add Directions widget Bug:141770616 P2 Flake: Can't find a launcher object; selector: BySelector [RES='\Qcom.google.android.apps.nexuslauncher:id/deep_shortcuts_container\E'] (visible state: AllApps), Bug:141886704 P2 Use app targets to determine input consumer instead of launcher state Bug:141899192 P3 [TalkBack] Page number that TalkBack read doesn't match the current screen on recent apps Bug:142088072 P2 Turning off the display and then back on takes user back to previous app in live tile mode Bug:142498588 P4 Feature req: Automatic folder names / creation Bug:142514365 P1 Failing test AddWidgetTest.testDragIcon Bug:142753423 P4 Prototype predictive hotseat Bug:142803200 P1 Broken binder tests Bug:142828227 P2 Temporary tweaks to make Launcher tests pass in Inproc presubmit Bug:143107728 P4 Crashes on boot, NPE in nexuslauncher Bug:143153963 P1 Launcher crashing while trying to tap and launch apps from home screen multiple times. Bug:143155020 P1 [Failing test] MomoryTests.testAppLaunchFromWorkspace* Bug:143190879 P1 Pop up "Pixel launcher keeps stopping" when both OTA and mainline are updated before restarting device. Bug:143249037 P1 Swipe up gesture does not work on wembley-eng Bug:143285809 P1 [Failing test] TaplTestsQuickstep.testQuickSwitchFromApp Bug:143307786 P1 Fix screenshot not getting cleaned up after recents animation cancelation Bug:143353100 P2 [RVC] Stuck in "All set!" after cable restore Bug:143361207 P3 Can't launch shortcut in live tile mode Bug:143377934 P4 Tapping on QSB leaves user in live tile mode with empty background Bug:143639898 P4 Notification dot should animate into popup on long press Bug:143702640 P2 icon badge is hidden when dragging Bug:143702700 P4 Drag and drop misbehave Bug:143714109 P2 Flashing when swipe up and right to launch the previous task Bug:143773683 P2 [Live tile] App open animation gets cancelled because of screenshot cleanup Bug:143792840 P4 Pixel launcher keeps stopping Bug:143803446 P2 "Files" app has one more icon appearing per day Bug:143857157 P3 Live tile does not follow translationX change of RecentsView Bug:143904998 P2 Launcher crashes when dragging now playing shortcut Bug:143991628 P2 Launcher3 App - system apps must target API level 29 or higher Bug:144081762 P2 Security Vulnerability in AOSP and Pixel Launchers Bug:144180777 P1 Inproc tests in git_master: getting app icon LauncherTestApp on all apps; Unable to scroll to a clickable icon: LauncherTestApp (visible state: AllApps) Bug:144290150 P2 Notification dot popups show the wrong notifications Bug:38268585 P2 Lightning bolt icon missing on recents in Vimeo for OC MR1 and Android P Test: Manual Change-Id: I0e329eea927c49217c0446a9e62ceaf3cf0099f0 (cherry picked from commit fa4ecb35adfcdcaf928572f5f0c089b42bb12218)
This commit is contained in:
1 parent
504b0ba055
commit
3483020c9d
205 files changed
+6496
-4118
No files matched your search
@@ -53,7 +53,7 @@ import com.android.launcher3.util.TouchController;
|
||||
* TouchController for handling state changes
|
||||
*/
|
||||
public abstract class AbstractStateChangeTouchController
|
||||
implements TouchController, SwipeDetector.Listener {
|
||||
implements TouchController, SingleAxisSwipeDetector.Listener {
|
||||
|
||||
// Progress after which the transition is assumed to be a success in case user does not fling
|
||||
public static final float SUCCESS_TRANSITION_PROGRESS = 0.5f;
|
||||
@@ -65,8 +65,8 @@ public abstract class AbstractStateChangeTouchController
|
||||
protected final long ATOMIC_DURATION = getAtomicDuration();
|
||||
|
||||
protected final Launcher mLauncher;
|
||||
protected final SwipeDetector mDetector;
|
||||
protected final SwipeDetector.Direction mSwipeDirection;
|
||||
protected final SingleAxisSwipeDetector mDetector;
|
||||
protected final SingleAxisSwipeDetector.Direction mSwipeDirection;
|
||||
|
||||
private boolean mNoIntercept;
|
||||
private boolean mIsLogContainerSet;
|
||||
@@ -101,9 +101,9 @@ public abstract class AbstractStateChangeTouchController
|
||||
|
||||
private float mAtomicComponentsStartProgress;
|
||||
|
||||
public AbstractStateChangeTouchController(Launcher l, SwipeDetector.Direction dir) {
|
||||
public AbstractStateChangeTouchController(Launcher l, SingleAxisSwipeDetector.Direction dir) {
|
||||
mLauncher = l;
|
||||
mDetector = new SwipeDetector(l, this, dir);
|
||||
mDetector = new SingleAxisSwipeDetector(l, this, dir);
|
||||
mSwipeDirection = dir;
|
||||
}
|
||||
|
||||
@@ -127,7 +127,7 @@ public abstract class AbstractStateChangeTouchController
|
||||
boolean ignoreSlopWhenSettling = false;
|
||||
|
||||
if (mCurrentAnimation != null) {
|
||||
directionsToDetectScroll = SwipeDetector.DIRECTION_BOTH;
|
||||
directionsToDetectScroll = SingleAxisSwipeDetector.DIRECTION_BOTH;
|
||||
ignoreSlopWhenSettling = true;
|
||||
} else {
|
||||
directionsToDetectScroll = getSwipeDirection();
|
||||
@@ -152,10 +152,10 @@ public abstract class AbstractStateChangeTouchController
|
||||
LauncherState fromState = mLauncher.getStateManager().getState();
|
||||
int swipeDirection = 0;
|
||||
if (getTargetState(fromState, true /* isDragTowardPositive */) != fromState) {
|
||||
swipeDirection |= SwipeDetector.DIRECTION_POSITIVE;
|
||||
swipeDirection |= SingleAxisSwipeDetector.DIRECTION_POSITIVE;
|
||||
}
|
||||
if (getTargetState(fromState, false /* isDragTowardPositive */) != fromState) {
|
||||
swipeDirection |= SwipeDetector.DIRECTION_NEGATIVE;
|
||||
swipeDirection |= SingleAxisSwipeDetector.DIRECTION_NEGATIVE;
|
||||
}
|
||||
return swipeDirection;
|
||||
}
|
||||
@@ -369,7 +369,8 @@ public abstract class AbstractStateChangeTouchController
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onDragEnd(float velocity, boolean fling) {
|
||||
public void onDragEnd(float velocity) {
|
||||
boolean fling = mDetector.isFling(velocity);
|
||||
final int logAction = fling ? Touch.FLING : Touch.SWIPE;
|
||||
|
||||
boolean blockedFling = fling && mFlingBlockCheck.isBlocked();
|
||||
@@ -406,7 +407,7 @@ public abstract class AbstractStateChangeTouchController
|
||||
} else {
|
||||
startProgress = Utilities.boundToRange(progress
|
||||
+ velocity * getSingleFrameMs(mLauncher) * mProgressMultiplier, 0f, 1f);
|
||||
duration = SwipeDetector.calculateDuration(velocity,
|
||||
duration = BaseSwipeDetector.calculateDuration(velocity,
|
||||
endProgress - Math.max(progress, 0)) * durationMultiplier;
|
||||
}
|
||||
} else {
|
||||
@@ -424,7 +425,7 @@ public abstract class AbstractStateChangeTouchController
|
||||
} else {
|
||||
startProgress = Utilities.boundToRange(progress
|
||||
+ velocity * getSingleFrameMs(mLauncher) * mProgressMultiplier, 0f, 1f);
|
||||
duration = SwipeDetector.calculateDuration(velocity,
|
||||
duration = BaseSwipeDetector.calculateDuration(velocity,
|
||||
Math.min(progress, 1) - endProgress) * durationMultiplier;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user