Commit Graph

34630 Commits

Author SHA1 Message Date
TreeHugger Robot 0f0a53a35f Merge "Enable support for same page hotseat migration" into ub-launcher3-master 2020-03-04 00:26:20 +00:00
TreeHugger Robot fe41c3af21 Merge "Allow Launcher to automatically restore widgets" into ub-launcher3-master 2020-03-04 00:16:09 +00:00
Samuel Fufa 9151c011b9 Allow Launcher to automatically restore widgets
This replaces PendingAppWidgetHostView with configured widget view when
OPTION_APPWIDGET_RESTORE_COMPLETED is set to True by a widget provider.

Bug: 63667276
Test: Manual
Change-Id: Ide21f5e9a7dac7e3d6a745660a38ad0b951b47d3
2020-03-03 15:35:48 -08:00
Vinit Nayak f9328198e1 Rotate touch events for land/seascape navbars
Previous change removed checking for navbar
location to transpose touch event.

fixes: 150700927
Test: Quickstep TAPL test passes.
Change-Id: I47683f8a75f24c8bfc46437e0eef9172c23cc452
2020-03-03 15:03:04 -08:00
Tracy Zhou 475d160745 Merge "Enable Grid Preview flag" into ub-launcher3-master 2020-03-03 19:16:06 +00:00
vadimt 3d9dad3b9b Saving heap dump immediately as reported by StrictMode
Can do this via API with the exact heap state that triggered the
callback because using API allows to avoid deadlock that we'd have in
main thread if we used shell command.

checkDetectedLeaks() is still needed, as I'll add throwing an
exception there soon.

Bug: 139137636
Change-Id: I3c8670071b058c5c146ac58bb16152c980553065
2020-03-03 18:21:07 +00:00
TreeHugger Robot b83399b46e Merge "Fixing activity being referred after destroying." into ub-launcher3-master 2020-03-03 18:09:11 +00:00
Tony Wickham 294238a2fa Dump GestureState and created overview activity
Bug: 150525635
Change-Id: I6f5bf0f9c917845b6e880323dbba99552a9c43ba
2020-03-02 22:08:31 -08:00
TreeHugger Robot 5dc6060c84 Merge "Fixing activity referred after destroying by PinnedStackAnimationListener" into ub-launcher3-master 2020-03-03 04:04:09 +00:00
Jon Miranda 7edcd7803f Makes spring variable dynamic resources so that they can be changed via plugin
Bug: 147302669
Change-Id: Ia4e74ff46a4d8338a56ea75ed826b69102c42d93
2020-03-02 18:48:23 -08:00
vadimt c4c16e7aeb Fixing activity referred after destroying by PinnedStackAnimationListener
This is perhaps not a leak, but it conflicts with how StrictMode
activity leak detection works.

Bug: 139137636
Change-Id: If7fd0361b8e5ff81a2c0adb2308793ff87349951
2020-03-02 18:44:24 -08:00
vadimt b1eaa1752e Fixing activity being referred after destroying.
This is perhaps not a leak, but it conflicts with how StrictMode
activity leak detection works.

Bug: 139137636
Change-Id: I1608e348d8b238142c42ed81ae125fd07ef6b673
2020-03-02 18:36:01 -08:00
Vinit Nayak acaf0749b3 Adjust target and src rects for swipe to home animation
Floating icon animation runs entirely in portrait
since that's what orienation launcher starts in.
Current app window target rects are in landscape to
be able animate to Overview correctly (which is not
in portrait since the leash from WM is in the same
orientation as that of foreground app).
Invert that rect as the animation from app window
to floating icon progresses.

Fixes: 148528795
Change-Id: Ie1149a1a8904afc80bd1986f8d67b6f2d88c49f2
2020-03-02 18:02:52 -08:00
Vinit Nayak a406f727ad Add vertical layout support for Overview in portrait
WM is making changes which allows apps to maintain
their orientation independent of the orientation of
the foreground app. This allows recents to always start
in portrait even when the app currently running is in
landscape. This means we have to give the illusion of
a landscape oriented overview when user swipes up in
gesterual nav when launcher is started in portrait
configuration.

PagedOrientationHandler abstracts all coordinate specific
logic from Paged/RecentsView primarily, but also all
other dynamic calculations throughout launcher.
PagedViewOrientationState is the single point of exposure
to other classes that depend on those changes. The goal
is to also minimize holding state to allow for default
implementations of PagedOrientationHandler for all the
3p/Fallback classes. PagedViewOrientationState also
holds other data around rotation that isn't
specifically tied to view logic.

The fake landscape overview can be toggled with:
adb shell settings put global forced_rotation [0/1]

Fixes: 146176182
Change-Id: I65d8d4e9f92b93931cbe0053ccaf0cda8d2ffd6c
2020-03-02 18:02:35 -08:00
Vinit Nayak 1901939be7 Modify input points to register in correct swipe touch regions
While the recents task list is frozen, launcher
will continue to listen for touch regions in
all orientations of apps it has seen while frozen.
Ex. Start w/ portrait app, then quick switch to
90-deg landscape app, touches in the navbars of both
those orientations will be treated as valid.
Once the task list unfreezes, only the orientation
that is currently displayed will have a valid navbar
touch region

fixes: 140116135
Test: tested manually in all 4 orientations with
quickswitch, swipe to recents and swipe to home
Attempted to write unit tests, but only basic ones
since there are some limitations on the MotionEvent
API for mocking

Change-Id: I8d3751571a939497b44e0dd249a0248299ba5ceb
2020-03-02 15:28:38 -08:00
Tracy Zhou 20d2683d92 Enable Grid Preview flag
Bug: 144052839
Test: grid preview with v1 algorithm
Change-Id: Ic788995b899bf25c5420120a95e71e4a565ba22a
2020-03-02 15:21:53 -08:00
Hongwei Wang d7ac763b98 Merge "Indicate PiP animation type from Launcher to SysUI" into ub-launcher3-master 2020-03-02 23:10:28 +00:00
Vadim Tryshev d4fb87e265 Merge "Disabling failing test" into ub-launcher3-master 2020-03-02 21:39:58 +00:00
vadimt c8bae0ab71 Disabling failing test
Change-Id: I5989ce406c66834b77ff4bd073cd3ad92df9fda2
2020-03-02 13:35:55 -08:00
Sunny Goyal 424e7fdf6b Fixing unregistering mOtherHomeAppUpdateReceiver twice
mUpdateRegisteredPackage was not cleared when unregistering
mOtherHomeAppUpdateReceiver

Bug: 150543327
Change-Id: I1058c0262588cbeb1d6c61299cb4d4c38d622d98
2020-03-02 13:33:43 -08:00
Tracy Zhou 6d80cbc1d9 Merge "Render user's actual workspace in ThemePicker preview (Part 6)" into ub-launcher3-master 2020-03-02 21:30:47 +00:00
Vadim Tryshev 1f2182683e Merge "Not failing when getSystemAnomaly fails" into ub-launcher3-master 2020-03-02 19:41:35 +00:00
Tracy Zhou bd22546683 Render user's actual workspace in ThemePicker preview (Part 6)
Didn't test out widgets in Part 5. So in this change,
- Added some widget classes to the PreviewContext WHITELIST
- Manually update widget model after loading workspace since we do not attach widget listeners to the LauncherAppModel for preview.

Change-Id: I0a555b2319b2e91432dbd58289ddb66aca1384df
2020-03-02 00:44:55 -08:00
android-build-team Robot 0152f8ff97 Snap for 6250822 from 3210c06687 to rvc-release
Change-Id: Ia123fe883de5788a8cb2b0f240c78f5a2a29b3d4
2020-03-01 00:06:33 +00:00
Automerger Merge Worker c0d2bc6850 Merge "Merge "Merging from ub-launcher3-master @ build 6248758 am: 3210c06687 am: 20aaa198f3" into rvc-d1-dev-plus-aosp am: 35e2d9b343" into rvc-qpr-dev-plus-aosp am: 82875e629e
Change-Id: I3a2466370c872410a4325d4e7c39346ea9f6f610
2020-02-29 04:36:40 +00:00
Automerger Merge Worker b68f0bf271 Merging from ub-launcher3-master @ build 6248758 am: 3210c06687 am: 20aaa198f3 am: eaba9530c9 am: 03351a5ab0
Change-Id: I8a926651bbaca3a678cc360adbc9d4854d2dd76b
2020-02-29 04:36:00 +00:00
Automerger Merge Worker 07f8eab05e Merging from ub-launcher3-master @ build 6248758 am: 3210c06687 am: 9df3490fee am: d3020e1080 am: c1b4a2b823
Change-Id: I57274cd5f6f99ce4c4cbefdc28ed8fc3c7aaa549
2020-02-29 04:35:41 +00:00
Automerger Merge Worker 82875e629e Merge "Merge "Merging from ub-launcher3-master @ build 6248758 am: 3210c06687 am: 20aaa198f3" into rvc-d1-dev-plus-aosp am: 35e2d9b343" into rvc-qpr-dev-plus-aosp 2020-02-29 04:21:29 +00:00
Automerger Merge Worker 177f77a2ed Merge "Merging from ub-launcher3-master @ build 6248758 am: 3210c06687 am: 20aaa198f3" into rvc-d1-dev-plus-aosp am: 35e2d9b343
Change-Id: I6ec9f99b11038e5a53f3863a0a4d588957e1a512
2020-02-29 04:21:21 +00:00
Automerger Merge Worker 03351a5ab0 Merging from ub-launcher3-master @ build 6248758 am: 3210c06687 am: 20aaa198f3 am: eaba9530c9
Change-Id: I8f868910c84e62ab70a70fb2f5f676787198d9d9
2020-02-29 04:21:19 +00:00
Automerger Merge Worker c1b4a2b823 Merging from ub-launcher3-master @ build 6248758 am: 3210c06687 am: 9df3490fee am: d3020e1080
Change-Id: Ie6f535f912f6aa705d9a460fb531d0ab1d4504c6
2020-02-29 04:20:46 +00:00
Automerger Merge Worker 35e2d9b343 Merge "Merging from ub-launcher3-master @ build 6248758 am: 3210c06687 am: 20aaa198f3" into rvc-d1-dev-plus-aosp 2020-02-29 03:58:57 +00:00
Automerger Merge Worker eaba9530c9 Merging from ub-launcher3-master @ build 6248758 am: 3210c06687 am: 20aaa198f3
Change-Id: Id629bef6a92adef4bff2a6022b7b269cb97794eb
2020-02-29 03:58:28 +00:00
Automerger Merge Worker d3020e1080 Merging from ub-launcher3-master @ build 6248758 am: 3210c06687 am: 9df3490fee
Change-Id: I0d231f9992647c707e23e63a4a3093c9e72bad49
2020-02-29 03:58:26 +00:00
Automerger Merge Worker 70f5b2073a Merging from ub-launcher3-master @ build 6248758 am: 3210c06687 am: 20aaa198f3
Change-Id: I870813d3d408bb50a3f2d798cd310016950d57ef
2020-02-29 03:58:06 +00:00
Automerger Merge Worker 9df3490fee Merging from ub-launcher3-master @ build 6248758 am: 3210c06687
Change-Id: I2b510554913b8a5444620b711547d962b5184002
2020-02-29 03:40:56 +00:00
Automerger Merge Worker 20aaa198f3 Merging from ub-launcher3-master @ build 6248758 am: 3210c06687
Change-Id: Iaa41764230c04e85d31a6532ebb16069e17ca547
2020-02-29 03:40:47 +00:00
Vadim Tryshev 2707bdfbed Merge "Fix remaining cause of a leak in SecondaryDropTarget" into ub-launcher3-master 2020-02-29 03:21:52 +00:00
vadimt 908e9bb1cc Fix remaining cause of a leak in SecondaryDropTarget
Bug: 139137636
Change-Id: Ib94c5804616910ee562d63c022579042bb1727f5
2020-02-28 18:02:30 -08:00
Mehdi Alizadeh 3210c06687 Merging from ub-launcher3-master @ build 6248758
Test: manual, presubmit on the source branch
http: //x20/teams/android-launcher/merge/ub-launcher3-master_6248758.html
Change-Id: I1c64ab220493793ba10cbbecf38a4df8381d8a54
Bug: 150504032
2020-02-29 01:52:25 +00:00
Becky Qiu ae28b5e251 Merge "Revert "Revert "[Overview Actions] Disable swiping for TaskView if it's in select mode.""" into ub-launcher3-master 2020-02-28 23:34:46 +00:00
Winson Chung b19403a5ce Merge "Updating owners to include immediate Launcher team" into ub-launcher3-master 2020-02-28 23:21:10 +00:00
Winson Chung 0ac58e375d Updating owners to include immediate Launcher team
Change-Id: I17db2a06fa7bf34216538de0f8ca3771840e7e6f
2020-02-28 14:39:09 -08:00
Vadim Tryshev d8995a6fda Merge "Revert "TAPL: Verifying activity start/stop events"" into ub-launcher3-master 2020-02-28 22:29:47 +00:00
Vadim Tryshev 3dd64ca3a8 Revert "TAPL: Verifying activity start/stop events"
This reverts commit 1186700c9a.

Reason for revert: Fails in the lab

Change-Id: I6715a058c76d96752b904331968b46a07ce93f85
2020-02-28 22:28:16 +00:00
Becky Qiu 5667f6fbd3 Revert "Revert "[Overview Actions] Disable swiping for TaskView if it's in select mode.""
This reverts commit 7ff297a81f.

Reason for revert: Verified this was not the cl broke post submit.

Change-Id: Id992c6937a4230b945436ddb868204366ffd045e
2020-02-28 14:13:36 -08:00
Vadim Tryshev 3be0443d37 Merge "Revert "Enabling flaky tests per our new flaky test policy"" into ub-launcher3-master 2020-02-28 21:34:25 +00:00
Vadim Tryshev f450b2500c Revert "Enabling flaky tests per our new flaky test policy"
This reverts commit 983145c594.

Reason for revert: Too flaky

Change-Id: Ifabb638d6ce0a539518bc0b6b667a9783b6ca29d
2020-02-28 21:33:16 +00:00
Zak Cohen 23ceafe3d5 Merge "TAPL tests - make all apps in overview checks less fragile." into ub-launcher3-master 2020-02-28 21:21:36 +00:00
vadimt 18b9f396d6 Not failing when getSystemAnomaly fails
It's a supplemental method, and mysterious glitches that happen during
its work shouldn't cause the whole test to crash.

Example:
java.lang.NullPointerException: Attempt to read from field 'com.android.server.appwidget.AppWidgetServiceImpl$ProviderId com.android.server.appwidget.AppWidgetServiceImpl$Provider.id' on a null object reference
	at android.os.Parcel.createExceptionOrNull(Parcel.java:2291)
	at android.os.Parcel.createException(Parcel.java:2269)
	at android.os.Parcel.readException(Parcel.java:2252)
	at android.os.Parcel.readException(Parcel.java:2194)
	at android.accessibilityservice.IAccessibilityServiceConnection$Stub$Proxy.findAccessibilityNodeInfoByAccessibilityId(IAccessibilityServiceConnection.java:875)
	at android.view.accessibility.AccessibilityInteractionClient.findAccessibilityNodeInfoByAccessibilityId(AccessibilityInteractionClient.java:430)
	at android.view.accessibility.AccessibilityInteractionClient.getRootInActiveWindow(AccessibilityInteractionClient.java:214)
	at android.app.UiAutomation.getRootInActiveWindow(UiAutomation.java:607)
	at androidx.test.uiautomator.UiDevice.getWindowRoots(UiDevice.java:1102)
	at androidx.test.uiautomator.UiDevice.findObject(UiDevice.java:150)
	at com.android.launcher3.tapl.LauncherInstrumentation.getSystemAnomalyMessage(LauncherInstrumentation.java:334)
	at com.android.launcher3.tapl.LauncherInstrumentation.getAnomalyMessage(LauncherInstrumentation.java:359)
	at com.android.launcher3.tapl.LauncherInstrumentation.checkForAnomaly(LauncherInstrumentation.java:369)
	at com.android.launcher3.tapl.LauncherInstrumentation.lambda$eventsCheck$11(LauncherInstrumentation.java:1269)
	at com.android.launcher3.tapl.LauncherInstrumentation.lambda$eventsCheck$11$LauncherInstrumentation(Unknown Source:0)
	at com.android.launcher3.tapl.-$$Lambda$LauncherInstrumentation$3iFY1gd72Tm3mPf31PMij-eBaBk.close(Unknown Source:2)
	at com.android.launcher3.tapl.AddToHomeScreenPrompt.addAutomatically(AddToHomeScreenPrompt.java:53)
	at com.android.launcher3.ui.widget.RequestPinItemTest.runTest(RequestPinItemTest.java:163)
	at com.android.launcher3.ui.widget.RequestPinItemTest.testPinWidgetNoConfig_customPreview(RequestPinItemTest.java:95)
	at java.lang.reflect.Method.invoke(Native Method)
	at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50)
	at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
	at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:52)
	at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
	at org.junit.internal.runners.statements.FailOnTimeout$CallableStatement.call(FailOnTimeout.java:148)
	at org.junit.internal.runners.statements.FailOnTimeout$CallableStatement.call(FailOnTimeout.java:142)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at java.lang.Thread.run(Thread.java:923)
Caused by: android.os.RemoteException: Remote stack trace:
	at com.android.server.appwidget.AppWidgetServiceImpl$AppWidgetManagerLocal.getHostedWidgetPackages(AppWidgetServiceImpl.java:4887)
	at com.android.server.accessibility.AccessibilitySecurityPolicy.computeValidReportedPackages(AccessibilitySecurityPolicy.java:229)
	at com.android.server.accessibility.AbstractAccessibilityServiceConnection.findAccessibilityNodeInfoByAccessibilityId(AbstractAccessibilityServiceConnection.java:621)
	at android.accessibilityservice.IAccessibilityServiceConnection$Stub.onTransact(IAccessibilityServiceConnection.java:372)
	at android.os.Binder.execTransactInternal(Binder.java:1138)

Change-Id: If7ae23d07b69d524c3f300607f0866cce6405416
2020-02-28 12:08:19 -08:00