Commit Graph

42 Commits

Author SHA1 Message Date
Sunny Goyal
fa39536570 Removing static reference of deep shortcut manager
Bug: 141376165
Change-Id: Ie60b82be63a8926825598c681d8b2a1b2ace6413
2020-01-02 20:13:12 +00:00
Sunny Goyal
fca20151b0 Removing custom activity dump logic
Change-Id: I37c339be205a4e35227986544d36ca03b1ae4ba4
2019-11-25 11:18:28 -08:00
Sunny Goyal
210e174c9c Subclassing Launcher instead of using UiFactory
Allows us to override only the required methods, instead of providing
a proxy method for everything

Change-Id: I816dcdb2a8d5432496050118ded0f2bbe7122cf7
2019-10-21 11:10:21 -07:00
Winson Chung
ef52876739 Defer listening on widget host until after the state transition ends
Bug: 140246642
Change-Id: I4532e4298f04ff5c6dea04ccda89320995cadb80
2019-09-09 10:24:53 -07:00
Winson Chung
a36c8004ed Reset the overview sysui state when returning to the previous task
- Otherwise, it gets stuck until the next time launcher pauses/task launch

Bug: 135008910
Change-Id: Ia0696d764522e36a4064583cb82003c1e9c0cb7a
2019-06-11 16:53:01 -07:00
Sunny Goyal
5686333117 Adding a utility class to cache views at an activity level
Bug: 122345781
Change-Id: I9a939e0b19c06c1089c1ceb515f8b97fb5dbb49e
2019-05-22 14:23:12 -07:00
Sunny Goyal
8c48d8bea6 Changing min sdk to 25
Change-Id: I0d28069967854357ca755bf25dec19d4979bdecf
2019-01-29 11:29:52 -08:00
Kevin
c4ad03b9ef Split LauncherAppTransitionManagerImpl for Go
Split LauncherAppTransitionManagerImpl common functionality into a base
quickstep app transition class and subclass for recents-specific
implementation. In addition, override the app transition manager to the
appropriate manager depending on the build.

Bug: 114136250
Test: Manual test NexusLauncher, Launcher3GoWithQuickstep
Test: Build Launcher3GoIconRecents
Change-Id: Iab1b5ae0c75af276879d5e12df95f62a514bf571
2019-01-23 14:59:19 -08:00
Sunny Goyal
fe8e4a90be Moving some methods from various activities to the base interface
This allows creating some custom views in the absence of
activity context

Bug: 118758696
Change-Id: I23999290e972a2a8cbd725a521a4e0c7c2e5023e
2018-11-19 13:04:35 -08:00
Hyunyoung Song
fc00747909 Add StatsLog*Manager for logging.
Bug: 113043444

Verification: (19) is our event classifier number
11-05 11:24:28.188   932   994 I statsd  : { 1541445868000000000 766293363001 (19)0x10000->1[I] 0x20000->0[I] 0x30000->0[I] 0x40000->[S] 0x50000->1[I]  }

Change-Id: I75403837f9fa8e51efa012fb708bce7efc9c4488
2018-11-05 11:41:38 -08:00
Tony Wickham
6a71a5bd77 Add undo snackbar for deleting items
- Add methods to ModelWriter to prepareForUndoDelete, then
  enqueueDeleteRunnable, followed by commitDelete or abortDelete.
- Add Snackbar floating view
- Show Undo snackbar when dropping or flinging to delete target; if the
  undo action is clicked, we abort the delete, otherwise we commit it.

Bug: 24238108
Change-Id: I9997235e1f8525cbb8b1fa2338099609e7358426
2018-08-30 16:22:25 -07:00
Sunny Goyal
d230307a95 Migrating to android-x
Change-Id: I9a774152d13a541e8496dd84f2469bfed407f86d
2018-08-14 15:22:12 -07:00
Sunny Goyal
0a40a187b5 Merge "Exposing some private methods to easily customize arrow popup" into ub-launcher3-master 2018-07-12 18:45:27 +00:00
Hyunyoung Song
956ec4b0e5 Remove device profile dependency from UserEventDispatcher
Bug: 110122682

Change-Id: I31ba61e60e31f1cc84e6d0cf115193e45d9fcfdb
2018-07-11 23:31:01 -07:00
Sunny Goyal
87b5eb689b Exposing some private methods to easily customize arrow popup
Change-Id: I6f6dc0604a616f26c0879732a0237767ddbfdccc
2018-07-11 14:35:51 -07:00
Sunny Goyal
1c63c72c1a Adding a pending invisibility flag, which is used to indicate that the launcher
is not really invisible, but consider it invisible for window transitions

When a recents animation is cancelled, the callback can be received before or after the
wallpaper animation. To ensure that wallpaper animaiton runs properly, we keep the launcher
forceInvisible=true, only for that particular animaiton and false everywhere

Bug: 109735443
Change-Id: I5b22cc3327c8cd53a836d10e09fc88ae103becfc
2018-06-05 16:47:54 -07:00
Hyunyoung Song
46d07f7cb0 Log the parent of the PREDICTION container type (ALLAPPS OR TASKSWITCHER)
Bug: 79423536

Change-Id: I23ff0d4d0aa3fec781e9b6c8792d2d7a738ca6c8
2018-05-23 11:35:02 -07:00
Sunny Goyal
55eb556a4b Dumping the excoded view hierarchy instead of the default activity dump
> Encoded hierarchy is smaller is size and has a lot more information about the views

Bug: 79861035
Change-Id: I84316b1b0031282b0579f3aaac22d8d8f00d8bcb
2018-05-16 10:55:21 -07:00
Sunny Goyal
e43d00db40 Adding some activity state information in dump
Bug: 79216829
Change-Id: I3e1a5f5508f09b9ce2737c13d917fbab531c2572
2018-05-14 14:23:42 -07:00
Winson Chung
a0f09f94b5 Revert "Revert "Update sysui flags on swipe, skip task backgrounds on opaque apps""
This reverts commit f5d5b6f00f.

Reason for revert: Can be submitted once a build with ag/4040557 is available for flashing

Change-Id: Id94440a1dc9b765bb9758af81b0567628befa283
2018-05-11 21:55:21 +00:00
Winson Chung
f5d5b6f00f Revert "Update sysui flags on swipe, skip task backgrounds on opaque apps"
This reverts commit 5dd46d51ed.

Reason for revert: Temporary revert until ag/4040557 goes in

Change-Id: Iab2c747a99e1fb1cc5a91787dbf185df77f791b4
2018-05-11 06:50:21 +00:00
Winson Chung
5dd46d51ed Update sysui flags on swipe, skip task backgrounds on opaque apps
Bug: 79228291
Bug: 77984778
Bug: 78659249
Bug: 73714156
Change-Id: I3bb9ce5b4d5d16bc229a1caba99891cb87775136
2018-05-10 15:36:44 -07:00
Sunny Goyal
59d086c3ce Using surface rotation instead of insets to determine seascape configuration
Insets may not correctly indicate seascape configuration in multi-window or
when the presence of device-cutouts

Bug: 79376298
Change-Id: I8268efca0001fe527a0ffefe48cc71e774fad01c
2018-05-07 17:32:46 -07:00
Jon Miranda
717127186a Fix bug where launcher closing animation isn't run.
In some cases, we prematurely clear the force invisible flag before composing
the launcher animation, causing us to skip the animation.

Bug: 77205145
Change-Id: I4224741649a4fef34e255abac7b66bcf919c042f
2018-05-07 11:46:33 -07:00
Winson Chung
f23931f915 Reset the force-invisible flag after the animation into launcher completes.
- In the case where an app auto-enters into PiP, we don't run the
  predefined remote animation, which means that the force-invisible flag
  is never reset. With ag/3876550, we can rely on enter animation complete
  to be called after the transition, and we can reset the flag here as well.

Bug: 77730018
Change-Id: Ifa4cbe518047eed7ab327721ff6d17db1a2b8cd5
2018-04-20 16:12:37 -07:00
Tracy Zhou
b67e35337b Reset PIP position when canceling swipe up
onStop() is a confirmed signal of user leaving Launcher. In most use
cases, we use onUserLeaveHint() to move PIP. However, in some cases,
onUserLeaveHint() does not get triggered. It's still a good signal for
those use cases because it happens sooner than onStop() and is not
interrupted by focus change. In order to address cases that
onUserLeaveHint() is not triggered (e.g. cancelling swipe up), onStop()
pushes PIP to the right position. In other cases, we simply set it
twice, which does not hurt.

Change-Id: Ia206590d10d673b16196bbab927a24aaae3ba46b
Fixes: 77648293
Test: manual test
2018-04-17 23:45:47 -07:00
Sunny Goyal
3483c52e6b Waiting until onResume before creating the wallpaper-open animation.
Bug: 77853906
Change-Id: I5126855492da59c9dbfef0ce2a97f94662a6522b
2018-04-16 13:01:57 -07:00
Sunny Goyal
7eff40ff2d Several app transition fixes:
> If launcher already started, creating the state transition only after threshold crossed, so that previous animations are not cancelled
> Not posting animaiton callbacks at the front of the queue, as that sometimes causes it get executed before onNewIntent
> Farking the activity as forceInvisible while launching an opaque app, so that quickly pressing home/back runs the reverse animation
> Not running state animations when force-invisible is true

Bug: 77830325
Bug: 77898806
Change-Id: I50a7e915ca35fd6aeb284c8f321ecca74396fe98
2018-04-11 17:08:31 -07:00
Winson Chung
1a77c3dce1 Reload the task list when multiwindow mode changes
Bug: 73097187
Change-Id: I05d8635f78451600cbb8a9c03515e60d3c32e1ae
2018-04-11 13:26:21 -07:00
Winson Chung
9800e730a2 Fix animations home
- To prevent surface thrashing, we no longer hide the home activity before
  starting the transition home. This prevents the launcher from being added
  to the remote animation target list, which means that we default to
  skipping the launcher animation. As a workaround, we special case the
  flow and force the animation to run when starting the recents animation.

Bug: 74405472
Test: Go home from an app, ensure there is an animation.
Change-Id: Ifd2b39444fdeab323ee79a368b580a6264c3e5b9
2018-04-04 14:36:40 -07:00
Tracy Zhou
a706f00d78 Move default pip position to right above the shelf (Pt. Launcher)
SysUI change: ag/3721784, ag/3793664

- Track LauncherState and launcher activity state through callbacks.
- Devise logic to send shelf visibility and height signal to SysUI based
on LauncherState and Launcher activity state.

Bug: 73961893
Test:
- By default, pip shows up right above the shelf.
- Transitioning to all apps moves the pip down as the shelf becomes
invisible.
- Going to any specific app moves pip down. Hitting home moves pip
right above the shelf again.
- Dismissing IME should push PIP down but above the shelf on home
screen, bottom if not.

Change-Id: I1ab6ceb8007a5a7b5d932a456efa0a07f586ea4c
2018-03-28 14:40:49 -07:00
Winson Chung
8a968fab72 Fix black flash when splitting task
- Draw the thumbnail view and align with the thumbnail bounds instead of
  the whole task bounds with the icon
- Defer animating the task list until after the animation completes

Bug: 73118672
Test: Enter split screen
Change-Id: Ie10c079cb22ae82f3c5974296462abae335ef5a8
2018-03-15 18:00:50 -07:00
Sunny Goyal
f633ef5f43 Adding fallback recents activity
> Refactoring RecentsView to a common base class
> Moving some dependency form Launcher to BaseActivity
> Using the Recents view in RecentsActivity

Change-Id: Ie0e6741d356291e77420798c140c999121de3a0d
2018-03-13 17:22:52 -07:00
Sunny Goyal
d70e75a514 Removing launcher dependency when logging quickstep interaction
as Launcher may not be ready when the touch gesture completes.

Change-Id: Ia69eb7bfb0340f7b7ce9b6c67be8851e5429f867
2018-02-22 10:21:41 -08:00
Sunny Goyal
fde5505d02 Handling configuration changes
> Adding a listener for device profile changes
> Updating various controllers instead of recreating them
> Clearing all-apps icon

Bug: 71709920
Change-Id: Ief7db199eb7494ebd8fb433198f333cd2e8e661d
2018-02-01 14:47:08 -08:00
Sunny Goyal
cc96aa1fd4 Running state animations if launcher is visible
Change-Id: Ibc522edec4f86375ea75ac645b748fec43fceb31
2018-01-11 09:56:23 -08:00
Sunny Goyal
64a75aa305 Adding A feature flag to disable widgets and a corresponding build
target Launcher3Go without widgets support

Bug: 62353159
Change-Id: Ia03d2235a9bcf75f9ef191924f81630e63a2c684
2017-07-21 14:10:13 -07:00
Sunny Goyal
8392c823a9 Fixing various system UI flags not getting updated properly on theme changes.
SystemUiController manages various system UI flags in priorty order and merges
all the states before applying the syste flags.
Fixing WallpaperColors when it was not handing wallpaper change properly in
some cases

Change-Id: I915442818e7888c97c81f63c8ea9f3c13053eb2c
2017-06-20 10:55:27 -07:00
Hyunyoung Song
d5a9b57713 Log whether an event happened during landscape mode or not
b/38211234

<sample log>
  action:TAP
  Source child:APP_ICON, packageHash=-1046965711, componentHash=-371608779, intentHash=208792422, grid(4,4), span(1,1), pageIdx=0	parent:WORKSPACE id=0
  Elapsed container 3071 ms session 3071 ms action 0 ms
  isInLandscapeMode true
  isInMultiWindowMode false
</sample log>

Change-Id: I44dfe4e7ee2a41c56a50cc2b507bbbeedc458018
2017-05-16 11:12:43 -07:00
Jon Miranda
fe96432b43 Add isInMultiWindowMode bool to all logs.
Example output:
D/UserEvent: action:LONGPRESS
       Source child:WORKSPACE id=0
       Elapsed container 1850 ms session 1850 ms action 0 ms
       isInMultiWindowMode true

Bug: 34250955

Change-Id: If21484e8bbb0f4f311c2eb6e94b7dcea6d2431af
2017-03-22 13:08:50 -07:00
Sunny Goyal
a535ae423b Moving Event dispatcher definition from LAuncher to BaseActivity so that
it can be used in other activities as well.

Bug: 34766840
Change-Id: Ie4b723483792bee93fb75e63146ebea7dfeebeda
2017-02-27 10:09:09 -08:00
Sunny Goyal
278359539c Adding support for requesting addition of shortcut/widget
on the workspace.

Bug: 33584624
Change-Id: I664366822fe8088742faff2cce006239ab0771bc
2017-01-18 18:38:34 -08:00