Commit Graph

52 Commits

Author SHA1 Message Date
Sunny Goyal
b1d7de25f8 Adding support for overlay and corresponding plugin to Launcher
Updating various task callbacks to handle overlays

Change-Id: I80077508ad35c31269c873f51f0105302a9e6a5d
2019-09-10 08:08:28 -07:00
Sunny Goyal
e9c6f4cc69 Fixing interactive state for background states and
notifying LauncherCallback accordingly

During quick switch Launcher can get resumed only to be paused again
when launching a new app. Updating the logic for deferred resume to
account for that and moving some additional calls to deferredResume

Bug: 134062513
Change-Id: Ia607f178bc17d45d53fb032a06cd70f9abc6b513
2019-05-30 11:59:29 -07:00
Sunny Goyal
77b3419ad5 Adding support for showing predicted apps as a floating row in all-apps
and overview

Bug: 130053407
Change-Id: Idb93a0ba6cfea8406f75ab86d9e0acde2fc04b3a
2019-04-23 14:26:44 -07:00
Sunny Goyal
8e1fbc5103 Moving some callbacks from LauncherCallbacks to OverviewCallbacks
Bug: 78780639
Change-Id: I90f868c741834efbe542367bdc3539f6d14f1939
2018-05-01 16:58:52 -07:00
Sunny Goyal
8546213d01 Passing stateHandler information to the callback
Bug: 78478167
Bug: 78478567
Change-Id: Ie3334c4473037c31d87bda950239c628e219dc46
2018-04-24 11:40:38 -07:00
Sunny Goyal
66f2b35320 Adding a utility class to simplify main process initialization.
Change-Id: I796cf758d2a25cf8fd5f9a9b78a7977fd54ca451
2018-02-13 17:08:09 -08:00
Sunny Goyal
3bac2c2b91 Adding callback to notify LauncherCallbacks when quickstep starts
Bug: 73081875
Change-Id: Ieccba6ecb16553ed5211f277b49e9f2ed2d7c745
2018-02-07 14:50:08 -08:00
Sunny Goyal
f4aceab637 Replacing some method definitions with default platform implementations
Change-Id: I32e007ca0edc4a1e12b19fdb8c8c08df4109b0f4
2017-12-06 16:18:28 -08:00
Sunny Goyal
d3864fa630 Fixing double state changes when using an InternalStateHandler
> Removing duplicate state handling on onCreate and onNewInetnt when InternalStateHandler is active
> Changing PinItemDragListener to use IntenalStateHandler

Change-Id: I42dcf82d1180c49430c6cf0b85d47072c4498ecc
2017-11-15 10:24:10 -08:00
Sunny Goyal
00c95b8447 Removing some obsolete callbacks
Change-Id: I3cf19a13ff145923f2973e23c24033f196324aa3
2017-10-06 11:56:01 -07:00
Sunny Goyal
d0d0703399 Removing predicted apps reset on every onResume
Predicted apps should be pushed by the called whenever they change
instead of Launcher polling them on every UI update.

Bug: 67305604
Change-Id: Ibd3d809b09b7d8fd39036f69367e8580fb90dcef
2017-10-04 10:41:43 -07:00
Sunny Goyal
7ce471bdf6 Removing support for CustomContent screen
The supported way to customize Launcher and add a "-1 page" is by
using LauncherOverlays. Custom content screen is no longer supported.

Change-Id: I3f8a2734c287d1a69ae0c038ec1de1d45fa1b464
2017-09-08 14:06:30 -07:00
Sunny Goyal
e18d3f537f Updating the all-apps discovery bounce animation
> Animation plays on every onResume
> Updating animation to loop continuously on v23+
> Updating animation spec

Bug: 64331951
Change-Id: Ic6fb8d6975b37f5b010fc585329cba615296f5c7
2017-08-29 10:17:51 -07:00
Mario Bertschler
8ff9e1d679 Integrating suggested app by handling new status flags for shortcut items.
Guarded via feature flag SUGGESTED_APP.

Bug: 62483883

Change-Id: I7e0c8a9875bc37c435aa4316b44322a628cd4826
2017-08-24 12:23:06 -07:00
Sunny Goyal
60820d796f Adding listener support for color extraction changes
Changing the apps-search layout to use theme attribute instead of hard
coded layout id

Bug: 37616877
Change-Id: Iae601758303f83a2774635f0d88f74d99fc643c3
2017-05-09 12:41:50 -07:00
Sunny Goyal
161f96bc77 Moving apps search related logic into a custom layout file
This will allow derivative projects to easily change the search behavior
by simply overriding the xml file

Bug: 37616877
Change-Id: Ib8d6a2dab06819a52611e9a3d97c70c5a49bbf97
2017-05-08 14:43:32 -07:00
Sunny Goyal
5e7b238a93 Updating color extraction to include wallpaper theme color.
Also adding mathods and callbacks to pass the related data to the callbacks.

Bug: 37616877
Change-Id: I7512cac7a603e8e5a05ec3a360c9eec493344b00
2017-04-26 08:42:05 -07:00
Mario Bertschler
c06af333cb Minor Refactoring only: no functional change
- organizing imports
- remove redundant modifiers on LauncherCallback interface
- fix typos

Change-Id: I61eb985cac7c1379b6b804a67d4f234386d3d1b4
2017-03-28 12:23:22 -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
6f28e71e94 Simplifying the startSearch call in launcher callbacks
Change-Id: I722e110903cced237f05667c4d711468d7cd3daa
2016-09-13 14:22:31 -07:00
Sunny Goyal
65ceb5aa55 Moving the scrim to draglayer
> This causes the scrim to animate with the content on first launch
> Also removing the logic to disable scrim based on state. That
logic was only executing onResume which could lead to an invalid state

Bug: 30972956
Bug: 30576826

Change-Id: Ia8386b303ce260f69e3b3b93041226f409301a01
2016-08-23 19:04:23 -07:00
Hyunyoung Song
c001cf5620 Animate discovery bounce for all apps pull up interaction
b/30221381

> Will not support landscape case. If the user knows how to enable
rotation, it's very unlikely they don't know how to bring up apps drawer
> If unlocked using finger unlock immediately after screen is turned
off, bounce is not shown due to delay in ACTION_SCREEN_OFF broadcast

Change-Id: Ia8b7e572eaa4aeab8b1add1e5660fee3a63ba21c
2016-07-21 17:32:43 -07:00
Sunny Goyal
745bad9da1 Chaning the behavior of settings activity.
> Making all twoState prefs backed by content provider
> Using the stadard intent defined in N for settings
> Using SharedPrefsListener instead of LauncherProvider

Change-Id: I8272f54aa780bc0436e3d0aa89096a4bd2a9194f
2016-05-02 12:00:51 -07:00
Adam Cohen
79d90c558f Define a set of methods on Launcher which can be safely called externally
-> The methods are defined by an interface, LauncherExterns, which Launcher
   implements

Change-Id: I61362761f5d90fbc3011ce000944768d5ab29d43
2016-04-26 11:53:43 -07:00
Hyunyoung Song
aa95365427 Refactor UserEventDispatcher (1/2)
b/28269657

Change-Id: I1083e6f73f42ac1986428a39c6b532050e595ac6
2016-04-19 18:30:24 -07:00
Sunny Goyal
534058492f Removing some deprecated callbacks
Change-Id: I3361383fe19faa64d862bbf879edb8c09937dc6f
2016-04-14 12:30:40 -07:00
Hyunyoung Song
ddec1c739e Refactor UserEventLogging, Add predictedRank, replace Bundle with Proto
b/26494415
- Removed bundle object that became redundant now that we have LauncherEvent proto
- Combined Stats and UserEventLogger as they are effectively doing same thing
- Removed parent field inside Target
- added predictedRank target inside Target

b/27967359
- make com.android.launcher3.action.LAUNCH broadcast explicit
Later CL: finish packageName/intent/componentHash/predictedRank fields

Change-Id: I441fb46c834f73e58a4d2324e8da7971e8713ec8
2016-04-13 10:58:33 -07:00
Sunny Goyal
6f866095c0 Removing dependency on wallpaper size settings from launcher
> Moving wallpaper desired width calculation to xml

Bug: 14470153
Change-Id: I8803af158861507a40e5d55e9aa6d515be47eefa
2016-03-17 17:04:37 -07:00
Hyunyoung Song
8fd5e938d3 Add getUserEventLogger to LauncherCallbacks
b/26494415

Change-Id: I8abaaf1269c12435a523e31bf769991018ea5c02
2016-03-08 16:55:47 -08:00
Sunny Goyal
c86df470ab Adding overlay interaction support
> Sending unboundX to the overlay which is the total untranslated X and not just deltaX from last frame
> Handling overlay callback and translating workspace accordingly

Change-Id: I3bd8d9efac738e9ce131758f0e5ff1b9c1d6a8fc
2016-02-25 10:01:13 -08:00
Sunny Goyal
32554d1c61 Cleaning up the overlay interface
Removing some unnecessary and unused methods

Bug: 25993953
Change-Id: I4d715cdee04eb7b0ebef673d885a4258c521ff1f
2016-02-23 12:06:16 -08:00
Hyunyoung Song
fbf19cccd2 <UserEventLogging> Log app launches
b/26494415

1) Current Logger can capture taps from
- homescreen
- folder inside homescreen
- apps prediction
- all apps a-z
- tap from hotseat
2) Deprecate LauncherCallback methods that is no longer needed

Future CL.
3) Stats and Logger will be merged. Bundle used for Stats can be
replaced with LauncherLogProto
4) Logging anything else other than app launches

Change-Id: Id52eb615f66142017b5c490a220ce6654d325681
2016-02-19 12:55:53 -08:00
Sunny Goyal
c42ac0a5a6 Removing LauncherCallbacks control over app search
Change-Id: Icb199607dea3f169055e44946272aa9f1e758d1d
2016-02-18 15:32:27 -08:00
Tony Wickham
775455c4a8 Add LauncherCallbacks method to add additional search widget options.
Bug: 25000458
Change-Id: I5e8d48617568569bc6e4f284749c3ed9fb20a68f
2015-10-16 10:15:36 -07:00
Tony Wickham
55616cd363 Added launcher callback to specify search bar height.
The search bar can now be be normal or tall. When it is set to tall,
the hotseat and page indicators move down so that the workspace isn't
compressed quite as much.

Change-Id: Id92a946eab3a93524999f92efd847a501a95f002
2015-10-08 16:58:05 -07:00
Winson Chung
bedf9232eb Adding market search.
Change-Id: Id41615653cd4fa76213add4595418ad0cc6e7852
2015-08-06 12:22:38 -07:00
Dave Hawkey
cb5f619770 am 79f25bed: Merge "Add LauncherCallbacks for requesting permissions on MNC" into ub-launcher3-almonte
* commit '79f25bedd2ed13613323b085b46b9b42aee21696':
  Add LauncherCallbacks for requesting permissions on MNC
2015-06-29 17:41:14 +00:00
Dave Hawkey
3a43ed61cb Add LauncherCallbacks for requesting permissions on MNC
Change-Id: Ia8f704590e03e16db04c2f7acee1e79ce7334749
2015-06-26 10:27:47 -06:00
Winson Chung
b1777447d9 Refactoring fast scroller.
- Fixing issue with fast scroller not fitting name width.
- Refactoring fast scrolling/scroll bar code out of base recycler view
- Adding animations to fast scroller to match design
- Smooth scrolling when jumping between app rows
- Fixing issue with fast scroller jumping when you first pick it up
- Fixing issue with wrong background paddings being used

Bug: 21874346
Bug: 22031923
Change-Id: I9f011b1f375751f437604b900e95a2942d3f4601
2015-06-23 14:24:15 -07:00
Winson Chung
6b1c73f50a Moving predicted apps callbacks to use ComponentKey.
Bug: 21270185

Change-Id: If2d9dd77235e7a96de96a1a5441a589ef8a72a7f
2015-06-18 12:39:24 -07:00
Winson Chung
ef7f874a88 Refactoring all apps search to support external search bar.
- Adding support for an external search bar that can be used
  to search a container view.  This adds a new interface
  AllAppsSearchController which manages the external search
  bar.  Each controller will have its own search implementation
  which means that we no longer need a common AppSearchManager
  interface.
- Removing elevation controller as we no longer have a builtin
  search bar in all apps
- Refactoring container view insets so that they behave
  the same in all containers.
- Refactoring apps view to ensure that we only update the number
  of columns with the available width
- Cleaning up LauncherCallbacks interface

Bug: 20127840
Bug: 21494973

Change-Id: I710b8e18196961d77d8a29f0c345531d480936fe
2015-06-15 14:22:47 -07:00
Winson Chung
8f1eff7b6c Adding context for app launches.
Bug: 21492784
Change-Id: I1b28ac8f44498e1d9770e770b074f19c721c3f10
2015-06-02 16:58:30 -07:00
Jun Mukai
8af0cd808e Introduce LauncherSearchCallback to handle search overlay status.
Bug: 20011047
Change-Id: I93cab4e0614b9658b4b657dd98dca68d42580e63
2015-05-12 14:34:35 -07:00
Winson Chung
4ac3006873 Initial changes to support predicted apps.
Change-Id: I80117d51074fe3dbdbb8d81cae886b1dffdfb86a
2015-05-11 21:59:39 +00:00
Winson Chung
cd99cd3ed6 Launcher-side changes to support prediction bar.
Change-Id: Ib9974ad8888ad87137c774f9f531fae9d56b899a
2015-05-04 14:45:54 -07:00
Winson Chung
0f78572066 Initial changes to support a fixed all-apps layout.
- Dynamically update padding and background depending on fixed bounds and searchbar
- Fixes issue with drag layer bg getting clobbered when rotating launcher
- Tapping outside the bounds of all apps should close all apps
- Fixing typo causing widgets to not show in sw720dp devices

Bug: 20127840

Change-Id: I29c3f905bdee940f938ffe054f58434887073092
2015-04-09 13:18:31 -07:00
Robert Kozikowski
67c3086163 Adding Launcher3 callbacks for trimming memory.
It will help reduce memory footprint of Launcher, when in background.
It is required to help deallocate images, when Google Now Launcher
goes into the background. See cl/83222937/ .

Plan after this CL:
- Generate drop CL with launcher3_drop.sh. Add empty metods to
 make code compile.
- Sync the cl/83222937 and hide the code behind the feature flag.

It was previously submitted in ag/628070 and reverted in ag/630423
due to GSA release schedule.

Change-Id: I56eee618b86d518d0afc362b6cf44c3bbec1f19c
2015-03-30 23:57:46 +01:00
Adam Cohen
e2d4ee1b21 Revert "Adding Launcher3 callbacks for trimming memory."
This reverts commit 42f3b9e028.

Change-Id: I65a7c893576c0901b231bab9abe6937f99415f1e
2015-02-06 23:28:49 +00:00
Robert Kozikowski
42f3b9e028 Adding Launcher3 callbacks for trimming memory.
It will help reduce memory footprint of Launcher, when in background.
It is required to help deallocate images, when Google Now Launcher
goes into the background. See cl/83222937/ .

Change-Id: I6d3d4d1f0457c67abcad3ba4516c87abcf666b05
2015-02-04 15:06:54 +00:00
Adam Cohen
a6d0492e5f Allow LauncherOverlay to access and manage insets
Change-Id: Ib9faf37eb22ad2a0b18c076978ec9f2fd8864c0c
2014-10-24 11:47:30 -07:00