Commit Graph

14186 Commits

Author SHA1 Message Date
TreeHugger Robot
6b49d62306 Merge "Let insets sources can produce insets on 0-width or 0-height windows" into rvc-dev 2020-03-20 22:30:12 +00:00
Jorim Jaggi
08a45d2445 Merge "Fine tune animation parameters for IME animations" into rvc-dev 2020-03-20 11:11:04 +00:00
Jorim Jaggi
5875cca667 Fine tune animation parameters for IME animations
To match spec as mentioned on the bug.

Bug: 151826721
Test: Visual
Change-Id: I1c2a70916e3a41195f5c003b9023c51ebd93eadb
2020-03-19 23:35:24 +01:00
Menghan Li
b42dfe722c Merge "Refines the javadoc of the ReplacementSpan.getContentDescription" into rvc-dev 2020-03-19 00:06:34 +00:00
Robert Carr
bb7964d645 SurfaceControlViewHost: Call die instead of dispatchDetached
Seems more appropriate as this more mirrors the normal release path.
I think everything gets release eventually either way.

Bug: 149591513
Test: Existing tests pass
Change-Id: I6f21d2723e06dbae4e09421efc352c179115bc40
2020-03-18 14:24:38 -07:00
Robert Carr
5af7d62e27 SurfaceView: Release SurfacePackage when done
We release the SurfaceControl assosciated with a Surface package
when accepting a new SurfacePackage, or at time of detached-from-window
this way we don't rely on the finalize method.

Bug: 149591513
Test: Existing tests pass
Change-Id: Ic0f7259394836ee094ed49db73b5986b778b450f
2020-03-18 12:53:28 -07:00
Rob Carr
4841efcfcd Merge "SurfacePackage: Add release method" into rvc-dev 2020-03-18 17:13:32 +00:00
Adrian Roos
269b162622 Merge "WindowInsetsAnimationController: Add state callback and getters" into rvc-dev 2020-03-18 16:43:10 +00:00
Adrian Roos
5d557edb44 WindowInsetsAnimationController: Add state callback and getters
Adds more comprehensive callbacks and getters for the WindowInsetsAnimationController,
to make it more straight forward to properly use.

Test: atest InsetsControllerTest PendingInsetsControllerTest
Fixes: 151707442
Change-Id: Ida55f609112396c0f6de4c5c4431e0793c2e315e
2020-03-18 12:17:19 +01:00
menghanli
a7d97f7ec5 Refines the javadoc of the ReplacementSpan.getContentDescription
- inconsistent for the doc & API implementation.

Bug: 150472098
Test: Manual test
Change-Id: Idb1e35245487ac161225f1e53c6308541694b481
2020-03-18 18:06:36 +08:00
Wei Wang
540c37bae3 Merge "Send DEVICE_IDLE and DISPLAY_INACTIVE hint from framework" into rvc-dev 2020-03-18 03:57:41 +00:00
Joanne Chung
6d6ddf4502 Merge "Fix broken tests in TextClassifierServiceTest." into rvc-dev 2020-03-18 02:27:40 +00:00
Wei Wang
80d224621f Send DEVICE_IDLE and DISPLAY_INACTIVE hint from framework
Bug: 140148621
Test: boot device
Change-Id: I34971fde28a80056c51d3c1501467f975c7e82a2
2020-03-17 16:11:42 -07:00
Robert Carr
d9c9c0cc75 SurfacePackage: Add release method
Oversight, the SurfacePackage holds a reference to the SurfaceControl
which is protected by a close-guard. We need a way to close it
explicitly. Going to follow up with a patch to have SurfaceView
manage the lifetime when the SurfacePackage is consumed, but want
to make sure this explicit release gets in ASAP.

Bug: 149591513
Test: Existing tests pass
Change-Id: I7276a2440c38cc6d859b79b4c3ee57bc122ce2a6
2020-03-17 14:12:53 -07:00
Yuncheol Heo
e88d949e0a Merge "Create a general mapping between window types and inset types." into rvc-dev 2020-03-17 18:01:47 +00:00
Rob Carr
7e06b011a0 Merge "Explicitly exclude IME from Task Snapshots" into rvc-dev 2020-03-17 17:56:55 +00:00
Winson Chung
a8a123c1ea Merge "Add WCT call to set container hidden state" into rvc-dev 2020-03-17 16:35:58 +00:00
Tony Mak
a10f2b981a Merge "Remove local text classifier and related tests." into rvc-dev 2020-03-17 11:50:58 +00:00
Joanne Chung
099faf74e6 Fix broken tests in TextClassifierServiceTest.
We introduce SystemTCMetadata in ag/10605740 which centrializes the
needed information for the TCMS to process the requests. Because we
change the getPackageName() logic to return the calling package name
of SystemTCMetadata and the SystemTCMetadata is only created if the
event is from the SystemTC not other TCs. The tests fail because the
SelectionEvent.packageName is not populated.

This cl contains the following changes:
- Return the package name that the SelectionEvent or
TextClassificationContext originated from
- Fix incorrect javadoc of TextClassificationContext.getPackageName
- Always verify the calling package name for onSelectionEvent and
onTextClassifierEvent

Bug: 151614815
Test: atest TextClassifierServiceTest
Test: atest FrameworksCoreTests:android.view.textclassifier
Test: atest FrameworksCoreTests:android.widget.TextViewActivityTest
Test: atest CtsTextClassifierTestCases
Change-Id: Iabe1691d63e3ec6ac834984cf79b60faf9c0e765
2020-03-17 19:20:14 +08:00
TreeHugger Robot
f931471bf4 Merge "Run codegen v15 on inline suggestion data classes" into rvc-dev 2020-03-17 03:13:25 +00:00
Feng Cao
1ee5afacb9 Run codegen v15 on inline suggestion data classes
Test: atest InlineSuggestionsRequestTest
Bug: 151265975

Change-Id: I2e7ce699cc212e6b4e3dd2a7901d5695227990a4
2020-03-16 17:44:56 -07:00
Tony Mak
293bdf360a Remove local text classifier and related tests.
1. libtextclassifier and libtextclassifier-java are no longer built
   into framework/base.
2. Removed local text classifier code
3. Removed local text classifier test code.
   All of them should be already moved to libtextclassifier/tcs side.
4. Unify all the TC related log tags to "androidtc".

BUG: 147412216

Test: mts-tradefed run mts-extservices
Test: atest frameworks/base/core/java/android/view/textclassifier
Test: Sanity test: Smart selection

Change-Id: Icb1076153f51d5674c8a6c58681ffed5aa772149
2020-03-16 20:16:17 +00:00
Adrian Roos
146db0e46b Merge "Revert "Revert "WindowInsetsController: Address API feedback""" into rvc-dev 2020-03-16 17:03:31 +00:00
Yuncheol Heo
13a6eb6f7b Create a general mapping between window types and inset types.
Bug: 145242835
Test: atest WmTests:DisplayPolicyLayoutTests
Change-Id: I2f3a34cfb9f1ed9e2e205ea5a0917f75414bfcff
2020-03-16 15:45:26 +00:00
TreeHugger Robot
1660402a5c Merge "SurfaceControlViewHost: Respond to API feedback" into rvc-dev 2020-03-16 02:24:49 +00:00
Robert Carr
f6878a4316 Add WCT call to set container hidden state
- This can be used for SysUI to control container visibility without
  clobbering the system determined task visibility

Bug: 139371701
Test: atest WmTests:TaskOrganizerTests
Change-Id: I8f54b2c18dd99ab8de5184e27ca4698417a6701e
2020-03-13 20:28:52 -07:00
TreeHugger Robot
62748d0a66 Merge "Set mNextServedView as null only when current served view lost focus" into rvc-dev 2020-03-14 00:26:57 +00:00
Mihir Patel
a5efb2c838 Merge "Notifying the on-device intelligence service when view window insets have changed" into rvc-dev 2020-03-13 21:02:15 +00:00
Selim Cinek
5f003f4e10 Merge changes I69b33b0c,If904c85e,I28444df4,I3bfa4580,I88d9667d, ... into rvc-dev
* changes:
  Decrease avatar and sender name sizes in MessagingStyle
  Fixed various conversation layout appearences
  Implemented FacePile if no group icon is present
  Fixed the behavior of headers in conversation groups
  Ensured correct coloring of badge in dark mode
  Fixed an issue where the bubble badge was visible independent of the icon
  Improved transitions for expanding messaging notifications
  Adjusted single line representation to include a colon
  Made the expand button positioning conditional on expanded state
  Ensured that the sender of the first message is hidden
  Baseline for the new ConversationLayout
2020-03-13 21:01:24 +00:00
Rob Carr
6e2a98a1f8 Merge "InsetAnimationControlImpl: Copy SurfaceControl" into rvc-dev 2020-03-13 20:18:09 +00:00
Mihir Patel
b73c421753 Notifying the on-device intelligence service when view window insets have changed
bug:137800469

Test: manual
Change-Id: Ia69e273a6646fc15e289f75084a81193e71e1eef
2020-03-13 20:04:25 +00:00
Adrian Roos
5ad8cd2586 Revert "Revert "WindowInsetsController: Address API feedback""
This reverts commit 5e7097b21e
and relands Id4cb53fddcecac17b7926068046760df5130dc39

Change-Id: I348141f27efcf7c22736778fbcdde4a110e95982
Fixes: 150472709
Test: atest InsetsControllerTest
2020-03-13 19:40:34 +00:00
Joanne Chung
031fe36d35 Merge "Refine TC request classes." into rvc-dev 2020-03-13 19:35:33 +00:00
Adam He
640c3b4f92 Merge "Hide autofill highlight if filling only the focused field." into rvc-dev 2020-03-13 18:52:57 +00:00
Feng Cao
f0e7d48fec Merge "Sends click and long click events from the inline suggestion to host app" into rvc-dev 2020-03-13 18:25:48 +00:00
Rob Carr
3a367c4bab InsetAnimationControlImpl: Copy SurfaceControl
This way the lifetime can be bound to the animation. Otherwise
the InsetController owns the lifetime, and it can be challenging
to synchronize the two (we would need to update all the running
animations when we rebuild the control list).

Bug: 150918857
Test: Existing tests pass
Change-Id: I86017b2eaee29ab0d8174479d187c9b7dd014305
2020-03-13 17:11:52 +00:00
lumark
ec78f00fe9 Set mNextServedView as null only when current served view lost focus
mNextServedView is set to null when the next view focus is lost.
but we should not set mNextServedView as null when received the
next view focus is lost but the view is not the current served view.

It can happen when received next view focused but input connection will
disconnect when mNextServidedView is null.

The issue is found when the Activity has ListView which added SearchView
as a list item.

When the Activity is launched, input connection will be started when
activity window focused and served view will be SearchView since search
view request focus by default, then when user taps SearchView,

several view focus in/out events comes out quickly that may cause
mNextServedView set to null when the conteiner View lost focus, so input
connection will be disconnected since ImeFocusController#checkFocus checked
there is no next served view.

The fix is to set mNextServedView as null only when the current served view
loses focus.

Fix: 148974380
Test: atest FocusHandlingTests
Change-Id: I9e90428387fcf43fbf86a8407de7535913202872
2020-03-13 19:22:49 +08:00
Tiger Huang
a24aab5686 Let insets sources can produce insets on 0-width or 0-height windows
Window Manager allows the client to add 0-width or 0-height windows.
These windows can get insets in the legacy insets mode even they only
intersect with the insets source window on the edges. This CL make this
behavior compatible with the legacy insets mode.

Fix: 150696052
Test: atest InsetsSourceTest
Change-Id: I9ed76bb615a0133ad55e1f93b22fbc03ae5cb437
2020-03-13 17:15:09 +08:00
Joanne Chung
97d3a45453 Refine TC request classes.
Centrialize SystemTextClassifier fields into a class, e.g. userId,
useDefault, callingPackageName. Then all the TextClassifer request
should contain this class object. This helps to scalability if we
want to add new fields.

Bug: 149080832
Test: atest FrameworksCoreTests:android.view.textclassifier
Test: atest FrameworksCoreTests:android.widget.TextViewActivityTest
Test: atest CtsTextClassifierTestCases
Test: Manual. Check the parameters are expected when doing smart
selection, smart linkfy.
Change-Id: I224208adac333e2da7b4213f0905f6fb0abb8b2e

Change-Id: Iaef82c1d6ec8893888258820ac103f1b988eecfa
2020-03-13 13:15:39 +08:00
Robert Carr
689a1b0f83 Explicitly exclude IME from Task Snapshots
In Q we built a mechanism for excluding layers from snapshots for
excluding the IME from TaskSnapshots, but somehow we never
ended up using it. I guess instead we were relying on
reparenting or timing. Whatever we were relying on is somehow no longer
working. Seems best to fix it with explicit exclusion so we don't
have some hidden dependency.

Bug: 148953305
Test: Open IME. Enter recents.
Change-Id: Iea2541ba3a1943e9137d6681b2a6f876bb63a392
2020-03-12 16:45:27 -07:00
Feng Cao
deec8f0175 Sends click and long click events from the inline suggestion to host app
Test: manual, atest InlineSuggestionTest
Bug: 151185482

Change-Id: Iafeb4584feca8a1cb1374f81105fa22136eba183
2020-03-12 15:51:22 -07:00
Jorim Jaggi
92fd77548a Merge "Use separate thread if app doesn't listen to animations" into rvc-dev 2020-03-12 20:49:07 +00:00
Adam He
5061db8a34 Hide autofill highlight if filling only the focused field.
Fixes: 150953184
Test: atest CtsAutoFillServiceTestCases
Change-Id: Ifc23a70a41022931d6828ff9a14620bb8fc58604
2020-03-12 13:38:34 -07:00
Robert Carr
271d9c76b6 SurfaceControlViewHost: Respond to API feedback
API Council provided the following feedback:
	1. Rename addView() to setView()
	2. Add getView()

Bug: 151311937
Test: Existing tests pass
Change-Id: I26665c8bb8d0c10c5eb4228feb4ff13ee89f0d7b
2020-03-12 13:14:42 -07:00
Rob Carr
83d02a976a Merge "WindowContainerTransaction: Support PIP Transition" into rvc-dev 2020-03-12 18:39:18 +00:00
Jaineel Mehta
1a18357853 Merge "Revert "WindowInsetsController: Address API feedback"" into rvc-dev 2020-03-12 18:23:14 +00:00
Jaineel Mehta
5e7097b21e Revert "WindowInsetsController: Address API feedback"
This reverts commit c549e19c5e.

Reason for revert: Droidcop: Potential culprit for Bug X - verifying through Forrest before revert submission. This is part of the standard investigation process, and does not mean your CL will be reverted.

Change-Id: I2ab42d96d2599dfcc946fa48b3940e2bd92b22b0
2020-03-12 17:46:17 +00:00
Adrian Roos
3a4be4a7b1 Merge "WindowInsetsController: Address API feedback" into rvc-dev 2020-03-12 16:13:43 +00:00
TreeHugger Robot
507be52dc7 Merge "Properly handle InlineSuggestionsRequest with 0 max suggestion count" into rvc-dev 2020-03-12 13:02:28 +00:00
Selim Cinek
20d1ee2402 Baseline for the new ConversationLayout
Introduced a new Layout for Conversation Notifications.
There are still various open issues that will be
fixed in follow up Cls

Bug: 150905003
Test: Add conversations, obverve visuals
Change-Id: I8ab2e2988d3205a4491006df68ec14235109466f
2020-03-11 21:53:03 -07:00