Test: go to overview, dismiss a task, swipe up to go home during the
transition (easier to try with animation duraation scaled up)
Bug: 144170434
Change-Id: I28b846b43260179aeac877351a7069743f66f3ea
Introduces a separate database for minimal device mode.
When minimal device mode is enabled/disabled:
1. WellbeingModel receives onChange event from ContentObserver
2. WellbeingModel called DWB's ContentProvider for latest state in
minimal device mode
3. Based on the state, WellbeingModel calls LauncherProvider to put
launcher into normal/minimal mode.
4. When going from normal -> minimal, Launcher switches to a different
database, namely minimal.db, then proceed to database initialization.
5. If the database hasn't been initialized yet, Launcher will call
ContentResolver#openInputStream with following uri:
content://com.google.android.apps.wellbeing.api/launcher_layout
to get the default layout xml.
6. The default layout is then saved in database, and the database is
considered initialized and doesn't need to go through step 5 again in
the future.
7. In case of minimal -> normal, Launcher switches back to its original
database (e.g. launcher.db if the grid size is 5x5), then reload launcher.
Bug: 161462256
Change-Id: I6bafa66440da23281f63454b698ea56b15960022
Bug: 161594550
TL;DR;;
- draging an item closes the IME
- clearing a searchbox to empty string has no effect on IME
Change-Id: Ic3a91d1b22434dcb78347dd8b12b5ceab14eb928
Test: Scroll to workspace page 2, then swipe up from the nav bar;
ensure that the page indicator fades in and scrolls to page 1
Change-Id: Ie0157c8e67b94509d3817f7e160d26f505185bbb
Introduces PluginSearchPipeline class, a plugin listener for AllAppsSearchPlugin. Coverts from List<Bundle> results from callback to AdapterItems to be rendered in SearchController.
- Moves AdapterItem to AllAppsGridAdapter
Bug: 164699827
Test: Manual
Change-Id: I20ec147e6b3f4707cf69d62b4b4ac70a90196345
Probably a recent change updates the rect when reaching overview, which wasn't happening before. Regardless, we shouldn't have copied the rect by reference since the referenced copy can be changed.
Fixes: 165143463
Test: manual
Change-Id: I9315a20226f0a4b3440ce5ee6cc1f4ed1ddca487
We no longer support the "peeking" model where the shelf would
peek on motion pause from an app and overview would peek on motion
pause from home. Thus, removed/inlined the following:
- FlingAndHoldTouchController (merged into its sole subclass
NoButtonNavbarToOverviewTouchController)
- ShelfPeekAnim
- OverviewPeekState
Change-Id: I066a3ad2636fde4786089c922b896bf1e03361fd
We need to do this before potentially starting another
interaction during the animation, or we could end up in
an inconsistent state.
Fixes: 160759508
Change-Id: Ia28dceddcc258679fc0b968f5a83fae5ef3f5acb
This way we mark the the current state as NORMAL at the start of
the animation, and cancel it as part of other state transitions.
This allows us to interact with launcher (e.g. to go to all apps
or pull down the notification shade) during the animation.
Also use OverviewToHomeAnim from RecentsView#startHome() to
ensure the animation is consistent, e.g. doesn't fade out
RecentsView, scrolls to page 1, etc.
Bug: 144170434
Change-Id: I5348565b9e705d8ffba39818dde9efe82b16bb7a
Merged-In: I5348565b9e705d8ffba39818dde9efe82b16bb7a
This way we mark the the current state as NORMAL at the start of
the animation, and cancel it as part of other state transitions.
This allows us to interact with launcher (e.g. to go to all apps
or pull down the notification shade) during the animation.
Also use OverviewToHomeAnim from RecentsView#startHome() to
ensure the animation is consistent, e.g. doesn't fade out
RecentsView, scrolls to page 1, etc.
Bug: 144170434
Change-Id: I5348565b9e705d8ffba39818dde9efe82b16bb7a
- Switch to screenshot and finish recents animation when an overview action is selected
Fixes: 162564471
Test: Manual
Change-Id: I3db20619435d079bb39ce4cb37b46ea775416336
Basically this removes the inner class MainThreadRenderer, which
was only created and used for its populate() method in the parent's
getRenderedView() method. All methods and members of that subclass
are merged into the parent LauncherPreviewRenderer class, and
getRenderedView() simply inlines the previous populate() code.
Other smaller changes:
- Extracted out shouldShowQsb() and shouldShowRealLauncherPreview()
- Disables search view and its children to prevent interaction
Change-Id: I7d0cce73efbe022c16661a0ad66eefe5cb285641
The loss of precision was causing us to miscalculate the age of
events, and thus not detecting any pause due to denominator = 0.
Test: have a device that hasn't been rebooted for a certain
amount of time such that SystemClock#uptimeMillis can't be
accurately converted to a float, then try to swipe up and hold
Fixes: 160568387
Change-Id: Idef112187f34a18feea7e6a0b77258626f9d0ed4
Make the overlay factory a member of the recents view.
Before the factory was static. The factory has references to activity
objects so was causing leaks.
Bug: 162012217
Tested: local, factory still works
Change-Id: I2283134f3008b630ba2056f07e65ac042957cdbd