This reverts commit 76a1ceb5f2.
Reason for revert: Add flag back to turn it off for further testing
Bug: 270395274
Merged-In: I10b9e99734b14cbbe8d1190300493099a1f28a24
Change-Id: I10b9e99734b14cbbe8d1190300493099a1f28a24
It moves some classes form the Nexus package into the launcher package
so it can be used in both projects.
It also adds more test for foldables and test multiple
grids for each test.
Bug: 289584301
Fix: 291346193
Test: ReorderWidgets
Change-Id: I04db5f685d0344b8a3f3d42b429bbde061b3d8ea
We need to change the result of REQUEST_IS_TWO_PANELS when the
flag is on because now we don't have two panels only 1.
Another of the issues is a rounding error when calling
getUnusedHorizontalSpace().
And lastly updating workspaceToBoards so that it maps the coordinate
of workspace items to their right position.
Bug: 270395274
Test: atest ReorderWidgets
Change-Id: I2620e5bf1ba132f984e00d2a6c21081953d259fd
In some cases when starting to drag you can go to the next
CellLayout wich end in an error. Now the dragging functions
will move the item to the desired CellLayout no matter what
CellLayout you start in.
Fix: 266116487
Test: atest ReorderWidgets
Change-Id: Ie3ad2ff88f734856e2c66d5d51b7578482877b5a
Tests need to be updated to account for the new placement of the
searchbar because it overlapped with touch events for scrolling:
- Scroll back to top: Instead of scrolling from the top of the
container which could overlap status bar in landscape, scroll
from the bottom of the top-most visible app icon.
- Scroll down: swipe up from bottom padding to top of top-most
visible icon.
- Close all apps: swipe down more quickly from top icon insetad
of the search bar (more quickly helps it be detected as a
fling on more cramped devices).
For Launcher3, the floating flag is not fully supported yet, so
there were some layout issues which are now resolved by ignoring
the flag if the searchbar is still at the top.
Fix: 268052768
Test: Ran tests, manual
Change-Id: If54717e2835c7cc4ed1368554bbc493193945c1d
Merged-In: I406fbcbe12acddb1dd4b862a380576a48cabbebc
I needed to change the code so that you can pass the CellX/Y
position to the drag function instead of the pixel coordinates
and we can pass X position bigger than one CellLayout.
Also, I notice that getCellCenter only worked for 1x1 items
so I added the option to specify the widget size.
Fix: 262431878
Test: atest ReorderWidgets#multipleCellLayoutsSimpleReorder
Change-Id: I3b09de770e8f99aa10cae8cea32e7e6bc02c7b8b
scrolling in all apps did not factor in additional top padding in the all apps list recycler. This made it so that apps could occasionally scroll and be obcured by that top padding, making them un-tappable. Added this padding to the scrolling logic to make scrolling less flaky.
Test: TaplTestsTaskbar, TaplTestsLauncher3 and presubmit
Fixes: 248064856
Change-Id: Id76b92b4bc354917f3688ac53673d0ed7a905f02
> Updating the LayoutManager's scroll calculation instead of a separate
implementation to better support recyclerView's calculations
> Caching the view sizes during layout to avoid view-inflation for
unknown types
> Fixing scrollbar jump during scroll when widget list is expanded
> Fixing scrollbar never reaching end when onboarding card is displayed
in work tab
Bug: 240343082
Test: Verified on device that new views are not inflated
Change-Id: Ied11ccf65b053691c5c126c4bf8de306ec24786d
This will help SysUI test team (who uses TAPL) to set up Gradle build for their tests.
Bug: 202567877, 234414088
Test: presubmit
Change-Id: I3d923ea4b54d1a4c3d2b345be09692727d30433e
Some devices in portrait mode have the same symptoms as b/234322284.
Simply return 1/3 of the position like the X axis to solve the problem.
Bug: 238202110
Test: atest Launcher3Tests:TaplTestsLauncher3#testAddDeleteShortcutOnHotseat
Change-Id: Ic7d3756cfbda6673a62b266c6093745b8311e6ac
- Removed TestProtocol.sForcePauseTimeout and
TestProtocol.REQUEST_SET_FORCE_PAUSE_TIMEOUT
- Instead, add MotionPauseDetector.TEST_HARNESS_TRIGGER_TIMEOUT, which
is used when Utilities.IS_RUNNING_IN_TEST_HARNESS.
Test: unbundled/launcher/launcher3_test_platform
Fixes: 232548865
Change-Id: I224e99042b41375cab6bffd555434217518958c5
This reverts commit 6729f0b950.
Reason for revert: This change caused b/230648542.
Please see https://b.corp.google.com/issues/230648542#comment5 for the video after reverting this change.
Bug: 206905515
Bug: 230648542
Change-Id: I85f063c56cad137c05b810204244bba7e8f94ee7
This will help enable transitions between A-Z apps lists and
search results because both can be seen simultaneously and
manipulated independently.
Some high level items of the refactor:
- SearchRecyclerView is added; logic that populated the main
(personal) tab with search results was simply redirected to
this RV instead.
- BaseAllAppsContainerView added isSearching() method. Returns
false, and ActivityAllAppsContainerView overrides (as search
is handled there).
- Renamed BaseRecyclerView to FastScrollRecyclerView to better
describe what it does. SearchRecyclerView extends this, but
returns false for supportsFastScrolling().
- AlphabeticalAppsList#mAllAppsStore is now optional, so the
Search RV doesn't need to store/listen to apps. Note this
doesn't affect the predicted app row which is still updated
if one of the predicted apps is uninstalled (I tested this).
Future work:
- Determine why dispatchRestoreInstanceState is not called for
BaseAllAppsContainerView. Save is called, e.g. on rotation.
Effect of restore not called: rotating while searching goes
back to A-Z list.
- Keep suggested apps in Header while searching. Currently they
are rendered in the SearchRV above search results, as before.
- Potentially extract Personal/Work tabs to move independently of
header.
- AlphabeticalAppsList is a misleading name because it can also
contains search results. However, things are pretty intertwined
between that and BaseAllAppsAdapter (effectively a circular
dependency), so I figured cleaning all that up was out of the
immediate scope of this refactor, which is mainly meant to
unblock transition work.
Bug: 206905515
Test: Manually checked for regressions, ran tests.
Change-Id: I4d3757c8a8f9b774956ca6be541dd4fcdad1de13
These are review comments followup from ag/17399997
Bug: b/218187058
Test: manually test thet Launcher3 features work correctly
Change-Id: I9865a37c1ed663370dc28e7678994f3d961e3cd1
The change updates features listed as follow:
1. Create a new class for folder icon.
2. Implement function to drag a icon to the other.
(create a folder)
3. Find folders in a workspace.
Bug: 199120092
Test: Launcher3Tests:com.android.launcher3.ui.TaplTestsLauncher3#testDragToFolder
Change-Id: I3044025f8297f6e442446d70238f4b56f38a798a
- Override our insets in LauncherRootView to explicitly only care about nav bar size, ignoring any insets due to taskbar.
- Previously we used nonOverlappingTaskbarInsets to belatedly subtract from measurements in e.g. DeviceProfile, but now we can revert most of those calculations since we effectively subtract taskbar insets at the root.
Test: visual in different orientations and navigation modes, and testPressHomeOnAllAppsContextMenu to ensure REQUEST_WINDOW_INSETS still works for automated tests
Fixes: 200607741
Change-Id: I8de5a268c686a1354b4beaa30e101bab6bed5af9
- getTargetInsets will be reverted to its behavior before ag/15431427
- getBottomGestureSize will use the new getWindowInset call uses windowInsets instead of the max of windowInsets/gestureInsets, with the taskbar inset calibration
Bug: 195263971
Test: com.android.launcher3.ui.widget.AddWidgetTest#testDragCustomShortcut
Change-Id: I89368edee5252a404ef490db6540734ec4806f2b
- In cuttlefish occasionally MOTION_MOVE and MOTION_UP takes more than 300ms due to lag, increasing the motion pause timeout to avoid getting false signals in tests
Bug: 194114179
Test: atest NexusLauncherOutOfProcTests:com.android.launcher3.memory.MemoryTests#testAppLaunchFromWorkspace
Change-Id: I0a33f34b5bf96f4f7ae56020c5a27f4ef9a0ff64
- Consider taskbar size for bottom gesture size, by using TargetInsets
- TargetInsets should substract overlapping taskbar size when it's present
- For pressHome, use the same gesture scope when context menu is present as well.
- For pressHome, GestureScope.INSIDE_TO_OUTSIDE should only be used when it's already at home screen on launcher3 tablet.
Bug: 193539246
Test: NexusLauncherTest and Launcher3Test
Change-Id: I4a20522f3b38ef326acae4b189df11a125990411
Changes made:
1. Model: added an abstract class for storing common information for
entries shown in the full page widgets picker.
2. Introduced a ViewHolderBinder interface to split the logic of binding
data to ViewHolder into separate classes.
3. Move the view holder binding of WidgetsListRow from WidgetListAdapter
to its new class.
4. Move some widgets picker classes into a new picker package.
Test: Auto: Run WidgetsListAdapterTest, WidgetsListRowEntryTest and
WidgetsListRowViewHolderBinderTest.
Manual: open the all apps widgets tray and navigate the list.
Bug: 179797520
Change-Id: Iab29557842bb79156cad84d00a4c5d0db0c5aa06
Slight revert of ag/10668129 with adjustment
of disabling it for tests.
Fixes: 151456795
Test: Ran the labtest command for OOP
tests for crosshatch (where this issue
was first detected)
Change-Id: I315d138c2e4a6d4068304e9b5fb2e1b7feb34e63
The flake had disappeared, perhaps because of this logging, or,
hopefully, for some other reason.
Bug: 148313079
Change-Id: I636783d5fc71474dd443c143289c3ff74651835e
Activity tracker is accessed on a non-UI thread, which can cause a non-initialized
Launcher to be treated as initialized
Bug: 149022794
Change-Id: I6634a6aff891592369c16469bbe95a9ea611819c
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
Clicking an icon within its padding area is ignored by Launcher. Hence,
ensuring that the whole icon is visible.
Bug: 141770616
Change-Id: I19e3ba7cfa25de75a47202845d0838bea46af92c