Commit Graph

9800 Commits

Author SHA1 Message Date
vadimt
252d012ed0 TAPL: Verifying some interactions with system
Investigation of TAPL failures, especially flakes is complex, partially
because it’s hard to tell whether it’s Launcher who is wrong or the
system.

We need to introduce a framework that looks at Launcher interaction with
the system and reports when interactions deviate from the expected
course, and who made the first wrong step.

This is first, proof-of-concept CL.

It analyzes long-press events. We had multiple cases when long-presses
didn’t happen or happened unexpectedly.

Launcher registers the events, TAPL retrieves and compares against the
sequence of expected regular expressions. This diagnostic is used when
something fails and at the end of public methods.

Change-Id: I07aa3a027267c03422c99c73ccd8808445c55fe8
2020-01-15 13:31:18 -08:00
vadimt
9675452c2f Better diags and a small correction for scrolling in AllApps
Change-Id: I48dbba26139f42350831fb707bea847b7c76129f
2020-01-14 19:39:35 -08:00
TreeHugger Robot
e16a2ba379 Merge "Add null check before updating NotificationItemView" into ub-launcher3-master 2020-01-15 02:44:08 +00:00
Hyunyoung Song
54d1f88ae6 Show suggestion when user taps on folder's edit text
Also, enabled preloading of the folder name db
Bug: 147523650
Bug: 147359653

Change-Id: Ia77e12d2b2bc428263c2b2821a96894a6004d82e
2020-01-11 23:39:02 -08:00
Sunny Goyal
a7a5bf3101 Adding support for multiple Model clients
Bug: 137568159
Change-Id: Ia4db800b19cc80c695fcb9ea28e07709dfd08c6a
2020-01-10 12:23:27 -08:00
Tony Wickham
3f330429a3 Fix BaseSwipeDetector#setState() called inside another setState()
Clients of BaseSwipeDetector are required to call finishedScrolling(),
which calls setState(IDLE). An obvious place to call this is in
onDragEnd(), which itself is called from a setState(SETTLING). If the
client does this, then the SETTLING state actually clobbers the IDLE
state, leading to undefined behavior. The reason we don't see this in
practice is because we usually call finishedScrolling() after an
animation from onDragEnd() instead of calling it immediately.

To fix this, we add a simple queue such that any calls to setState()
while one is in progress have to wait and are executed in turn. This
ensures we get all the proper state callbacks and end in the correct
one.

Also fix an incorrect call in AbstractStateChangeTouchController which
was masked by this bug. We were calling setState(IDLE) in onDragStart(),
which only worked because the original setState(DRAGGING) incorrectly
clobbered this. Now we only setState(IDLE) (via finishedScrolling())
when we fully clear the state, i.e. when the interaction is finished.

Test: added testInterleavedSetState

Bug: 141939911
Change-Id: Iae630ee7101921b57a85d40646468cf19f59b674
2020-01-09 15:39:38 -08:00
Hyunyoung Song
ced004fb71 Merge "Change the load logic of FolderNameProvider Work profile apps are suggested as "Work" folder name" into ub-launcher3-master 2020-01-09 17:38:37 +00:00
Hyunyoung Song
97253ec3ab Change the load logic of FolderNameProvider
Work profile apps are suggested as "Work" folder name

Bug: 147359653
Bug: 147359733

Change-Id: Idb2438de9c71c85cfeca6a6b0e116174ea2f3b62
2020-01-08 23:31:58 -08:00
TreeHugger Robot
d068f1cf66 Merge "integration test for open settings menu from workspace." into ub-launcher3-master 2020-01-09 04:17:03 +00:00
Pinyao Ting
654adf657e integration test for open settings menu from workspace.
compare pid of launcher process after test execution to verify launcher isn't crashed when running in oop test.

Bug: 147235759
Change-Id: Id13c47f5c4e388cc8e95b19d099e94a2e540bf3f
Test: fun flake locally
2020-01-08 17:01:39 -08:00
Tracy Zhou
4d7b244f3f Render user's actual workspace in ThemePicker preview (Part 2)
With this change, we can also render folders in preview. It's built on top of part 1.

Test: Go to grid options, choose a different grid option, and see user's workspace rendered in the preview
Bug: 144052839
Change-Id: Iaf6d8af6b909ece4147ea250d95dec3d2c0019d3
2020-01-08 15:42:58 -08:00
TreeHugger Robot
290f2cb028 Merge "Fixes duplicate "TAP" launcher event when new smart folder is created by drag and drop event." into ub-launcher3-master 2020-01-08 23:14:53 +00:00
Jonathan Miranda
1b4ed6dd9b Merge "Enable working springs. Move unstable springs to a seperate feature flag." into ub-launcher3-master 2020-01-08 21:17:49 +00:00
Thiru Ramasamy
652385d2ea Fixes duplicate "TAP" launcher event when new smart folder is created by drag and drop event.
Bug:147305113

Change-Id: I5d26df6a594b1d222e0db2e40c039c6661146d3a
2020-01-08 20:10:38 +00:00
TreeHugger Robot
2e0b8e39c7 Merge "Revert "include integration test for open settings menu from workspace"" into ub-launcher3-master 2020-01-08 18:46:01 +00:00
Jonathan Miranda
2684dc5d78 Merge "Add LogConfig.DoodleLogging so doodle logs can be enabled via adb." into ub-launcher3-master 2020-01-08 16:36:00 +00:00
Pinyao Ting
cd1cc0efc1 Revert "include integration test for open settings menu from workspace"
This reverts commit e94baee999.

Reason for revert: Test failing

Change-Id: Icb5d27488618a9b70b83d7ab582082c396578700
2020-01-08 01:15:29 +00:00
Samuel Fufa
aed008de90 Hybrid hotseat user edu
Starts by showing a notification, which will open a dialog
with options for users to keep their hotseat layout or fully
migrate to hybrid hotseat

Bug:142753423
Test:Manual
Change-Id: I178de612837ec8551f6776fa7c6fb6111bc7431d
2020-01-07 12:02:26 -08:00
Jon Miranda
d1589d47d7 Add LogConfig.DoodleLogging so doodle logs can be enabled via adb.
To use: adb shell setprop log.tag.DoodleLogging VERBOSE

Bug: 143720134
Change-Id: I61742564c9451ba084e192f823dbf5264702b3a2
2020-01-07 11:45:18 -08:00
Jon Miranda
40f0eb2188 Enable working springs. Move unstable springs to a seperate feature flag.
Bug: 147302669
Change-Id: I7a1b9b0e68cc68ad943b5af2b8cf7f80b5680eaa
2020-01-07 11:25:22 -08:00
Samuel Fufa
f43a5d32bf Merge "Add dismiss option for hotseat items" into ub-launcher3-master 2020-01-07 18:22:11 +00:00
TreeHugger Robot
1db3be37e4 Merge "Removing tracing for a fixed flake" into ub-launcher3-master 2020-01-07 17:11:59 +00:00
TreeHugger Robot
2f4eff3fd6 Merge "Keep folder notification dot on rotation" into ub-launcher3-master 2020-01-07 17:11:56 +00:00
vadimt
675c877765 Removing tracing for a fixed flake
Presumably, the flake was fixed when I added waiting for model load
before the test body starts.

Bug: 138729456
Change-Id: Ie921ebd40e42a7d73884c19949ca5f0129afc96e
2020-01-06 18:35:37 -08:00
Tony Wickham
a538d2b97a Keep folder notification dot on rotation
FolderIcon#mDotInfo is stored per instance, but not kept up to date
when re-binding on rotation.

Bug: 144369875
Change-Id: Ia429e4b4039eb02fb4587f54e33a0717408e4ac2
2020-01-06 18:08:05 -08:00
Samuel Fufa
a18eb686d0 Add dismiss option for hotseat items
Bug: 145556909
Test:Manual
Change-Id: Ia40d22226b5cf9482f19f82ef08e399d294be6da
2020-01-06 16:40:24 -08:00
TreeHugger Robot
2f3d0566c9 Merge "log number of items deleted even when no item was deleted at all" into ub-launcher3-master 2020-01-07 00:01:32 +00:00
TreeHugger Robot
108cc51e03 Merge "include integration test for open settings menu from workspace" into ub-launcher3-master 2020-01-06 23:22:45 +00:00
Pinyao Ting
fb9b779e9d log number of items deleted even when no item was deleted at all
Bug: 137678815
Change-Id: I1cf23921f863a17433ba803158e489b54c1aa35d
2020-01-06 14:10:35 -08:00
Sunny Goyal
0fd48b51ba Merge "Updating Robolectric tests" into ub-launcher3-master 2020-01-06 20:12:16 +00:00
Pinyao Ting
3c79804f28 include error log to determine root cause of sql statement failure when
restoring work profile

Bug: 147114476
Change-Id: I25e57413faa569a30e27a0cde1fc47233ff8b603
2020-01-06 11:21:41 -08:00
Sunny Goyal
9ae9b60043 Updating Robolectric tests
> Adding multi-thread support
> Simulating actual loader loading flow
> Moving some android tests to robolectic

Change-Id: Ie17a448f20e8a4b1f18ecc33d22054bbf9e18729
2020-01-06 11:05:42 -08:00
TreeHugger Robot
f10903e601 Merge "Removing static reference of deep shortcut manager" into ub-launcher3-master 2020-01-02 20:54:05 +00:00
TreeHugger Robot
1ff53859a1 Merge "Move the cursor to the end after accepting gboard selection Bug: 146909183" into ub-launcher3-master 2020-01-02 20:19:56 +00:00
Sunny Goyal
fa39536570 Removing static reference of deep shortcut manager
Bug: 141376165
Change-Id: Ie60b82be63a8926825598c681d8b2a1b2ace6413
2020-01-02 20:13:12 +00:00
Hyunyoung Song
9153ff7eed Move the cursor to the end after accepting gboard selection
Bug: 146909183

Change-Id: Ic7868d6d98f0b5a1798178cbaf512be1d347a962
2019-12-27 06:16:26 -08:00
James O'Leary
027cb32a96 Merge "Compose overscroll gesture updates" into ub-launcher3-master 2019-12-26 17:27:24 +00:00
Tony Wickham
74b492cc37 Merge "Increase drag distance threshold when drag starts from deep press" into ub-launcher3-master 2019-12-23 23:00:21 +00:00
Tony Wickham
a7704c09c7 Increase drag distance threshold when drag starts from deep press
Also don't update distance dragged until drag actually starts
(otherwise we add a lot of motion before deep press triggers).

Bug: 146146413
Change-Id: I28bd23707a9be53c709d7a4e779e84b9a0be9ce2
2019-12-23 13:28:58 -08:00
James O'Leary
a9156a05c4 Compose overscroll gesture updates
Two changes for the latest Compose prototype:
1. Pass the identity of the underlying app to the Overscroll plugin.
2. Enable the Compose gesture over an app when there's a Recents extra
card plugin active (otherwise the current app won't count as the
rightmost one).

Some changes to the gesture:
- Angle decreased from 35° to 25° to remove overlap with
Assistant gesture
- Distance increased from 8 to 110 dp. 110 dp is 2x the Assistant
gesture and roughly the same as scrubbing into an app from Home.
- Fling detection added; uses same distance threshold, 110 dp.
- If a touch was recognized as another gesture, the touch will not be
reinterpreted as a Compose gesture, no matter what touch movement occurs
- Fixes issue where Assistant + Compose could both be triggered
- Fixes issue where scrubbing apps to the left, then back to the right,
would bring in Compose. i.e. if a touch down + touch movement starts
bringing in Assistant UI elements, then, the user moves their touch
below the Assistant angle, the Compose gesture will not start
being recognized
- Gesture length required for fling lowered from 110 dp to 40 dp, per
tuning with PM.

Bug: b/146508473
Change-Id: I414573d1a92684d1d992837a5f1df522346ec211
2019-12-23 10:59:30 -05:00
TreeHugger Robot
2f285996dd Merge "Collect app usage data for hybrid hotseat feedback" into ub-launcher3-master 2019-12-21 01:35:21 +00:00
Pinyao Ting
e94baee999 include integration test for open settings menu from workspace
Bug: 146432215
Change-Id: I2d42984dd77506385230744361ae74944cc9b3bd
2019-12-20 15:37:36 -08:00
Becky Qiu
28a287624f [Overview chips] Turn overview chips off.
Change-Id: Ic200fa5e570abae6c41a12eb22bb3b853d02d504
2019-12-20 13:31:09 -08:00
Samuel Fufa
89d100197a Collect app usage data for hybrid hotseat feedback
Bug:145858435
Test:Manual
Change-Id: Ib9cbe0cb87a152a751e6253db42d58d2d0625c52
2019-12-19 15:08:23 -08:00
TreeHugger Robot
c7d601e923 Merge "TAPL: logging incoming intents" into ub-launcher3-master 2019-12-18 02:58:28 +00:00
Automerger Merge Worker
30f232de4c Fix shortcut componentname in workspace layout logging am: b9ba427576
Change-Id: I6ffef9cc9dabb32e1d6b1a16e7011d3c9b6b9c3b
2019-12-17 23:31:48 +00:00
Hyunyoung Song
b9ba427576 Fix shortcut componentname in workspace layout logging
Bug: 146172747
Test: $ adb shell dumpsys activity provider com.google.android.apps.nexuslauncher/com.android.launcher3.LauncherProvider --proto --debug
SHORTCUT, package=com.android.vending, component=VIEW_MY_DOWNLOADS, grid(3,4), span(1,1), pageIdx=0 user=0


Change-Id: Ic8537d499d66675fbe190f137b50fb693d6c21d5
2019-12-17 05:25:35 +00:00
vadimt
baf5fbbe58 TAPL: logging incoming intents
Even though ActivityTaskManager already logs intents, logging this will
simplify flake/error investigations that are considered to be too
time-consuming.

Also, this will make it possible in future to programmatically detect
whether the bug is introduced by the system or Launcher.

Bug: 133010698
Change-Id: I7dcadd95baa23f29bb661d6b42280bd2a2f0e099
2019-12-16 18:56:09 -08:00
TreeHugger Robot
c16667032a Merge "Logging state change events when in test to simplify diagnosing" into ub-launcher3-master 2019-12-16 23:40:40 +00:00
TreeHugger Robot
bdfa251d67 Merge "Add boolean to differentiate icons from workprofile" into ub-launcher3-master 2019-12-16 20:31:33 +00:00