Commit Graph

12757 Commits

Author SHA1 Message Date
Chavi Weingarten
6ce572ec6c Merge "Added direct call to syncInputTransactions" into qt-dev 2019-04-25 16:27:37 +00:00
chaviw
84dec9f7c6 Added direct call to syncInputTransactions
Previously, there was only a way to inject input after syncing inputs.
However, some tests require a direct call to sync inputs since we need
to ensure the info was propagated to InputManager native before
continuing with the test. This exposes a method just to
syncInputTransactions.

Bug: 130695122
Test: ActivityLifecycleTopResumedStateTests
Test: MultiDisplayPolicyTests
Change-Id: Ie3115741a20d04c743fd854ac421dc3705332488
2019-04-24 17:01:31 -07:00
Tarandeep Singh
c63ff2d590 Merge "Register Ime consumer only when insets are enabled." into qt-dev 2019-04-24 19:34:20 +00:00
Tarandeep Singh
7928f7cd4d Register Ime consumer only when insets are enabled.
As of today we register Ime consumer in IMM onWindowGainedFocus().
However, it does nothing functionally when ViewRootImpl#sNewInsetsMode is disabled.
This CL adds a check to not register consumer at the first place.

This may also be causing a leak. Added a TODO to revisit that before we
enable the flag.

Bug: 131181940
Test: atest ViewRootImpl
Test: atest InsetsController
Change-Id: I6b2b62d10670d63edafeb1b24c25b26c7721f3ad
2019-04-24 06:29:35 +00:00
Jackal Guo
efc894eeec Merge "Race condition while injecting ACTION_OUTSIDE" into qt-dev 2019-04-24 05:47:11 +00:00
Jackal Guo
8bcc0a9846 Race condition while injecting ACTION_OUTSIDE
In order to dismiss dialog in accessibility, we would also send
ACTION_OUTSIDE while performing ACTION_CLICK. However, the result
of performing ACTION_CLICK in AccessibilityInteractionClient may
be overwritten by the result of performing ACTION_OUTSIDE. This
causes that TouchExplorer may get incorrect result and follow-up
behavior is different.

Bug: 127902192
Test: a11y CTS & unit tests
Test: After enabling Talkback, manually test on 'View Terms' page
      in ManagedProvisioning to check if the section heading can
      be expanded/collapsed by double tap.

Change-Id: Id6b1f63ea87418c66bf1aebdea829f656581e8ed
2019-04-23 03:29:47 +00:00
Sara Kato
9498153dfd Merge "Add @Nullable annotation to getAccessibilityWindowId" into qt-dev 2019-04-23 01:28:23 +00:00
TreeHugger Robot
845d5ee587 Merge "Fixed content capture whitelist for specific activities." into qt-dev 2019-04-22 22:34:09 +00:00
TreeHugger Robot
4354101749 Merge "Move locale from LanguageDetectionEvent to base class" into qt-dev 2019-04-21 09:02:26 +00:00
Felipe Leme
cbf7f26baa Fixed content capture whitelist for specific activities.
Test: manual verification (it cannot be fully verified using the current CTS setup)
Test: atest CtsContentCaptureServiceTestCases:android.contentcaptureservice.cts.WhitelistTest
Test: atest FrameworksCoreTests:android.content.ContentCaptureOptionsTest
Test: atest CtsContentCaptureServiceTestCases # sanity check
Test: m update-api

Fixes: 130573023
Merged-In: I2c76a01bd98c4154c4c59099f1368232d2dba80d
Change-Id: I2c76a01bd98c4154c4c59099f1368232d2dba80d
2019-04-19 20:25:45 -07:00
Felipe Leme
8c2360b123 DO NOT MERGE - Updated some javadocs.
Test: make ds-docs

Bug: 130726495
Fixes: 130737893

Change-Id: Idaf50cb17b0668f3052d86f256d5428ba4e06a3c
2019-04-19 16:08:48 -07:00
Sara Kato
0fdbae3c46 Add @Nullable annotation to getAccessibilityWindowId
Bug: 126701062
Test: None
Change-Id: I7d13d56f5ffb303431f7e82418134d6f17275ef5
2019-04-19 12:04:51 +00:00
Daichi Hirono
3e9d510586 Add a flag to cancelDragAndDrop to skip animation
When running cancel animation for drag shadow image, the system cannot
start another drag operation, which is problematic when the system would
start the other drag operation quickly.

Bug: 130313958
Test: Cancel drag operation by calling cancelDragAndDrop
Change-Id: I5d6650a0ce9a4cd80bbdb1beabc9e514349ccadc
2019-04-19 02:30:06 +00:00
Nader Jawad
5c5ffcbd7a Merge "Added BlendMode equivalent APIs to replace deprecated PorterDuff variants" into qt-dev 2019-04-18 21:18:32 +00:00
Tony Mak
c30a91702d Move locale from LanguageDetectionEvent to base class
A follow up change of ag/7058048.

Also fixed a wrong nullability annotation, ConversationActions.getHints
should be @NonNull.

Bug: 129344540
Test: atest cts/tests/tests/view/src/android/view/textclassifier/cts/

Change-Id: Iae734b4b27dd3dd8294684330bec198072693a57
2019-04-18 10:25:25 +01:00
Nader Jawad
531db61ac1 Added BlendMode equivalent APIs to replace deprecated PorterDuff
variants

Updated various framework Views to have equivalent BlendMode APIs
to replace the deprecated PorterDuff equivalents.
Updated InspectableProperty annotations to refer to the same
xml attributes as the original tintmode APIs

Bug: 126726419
Test: Added CTS tests to verify new BlendMode APIs
Change-Id: Id9ab36d3d4d29f351250723e9d13d49bc6062c83
Merged-In: Id9ab36d3d4d29f351250723e9d13d49bc6062c83
2019-04-17 21:11:39 +00:00
Adrian Roos
8c7ca4f5c2 Ensure Contrast: Address API feedback
Fixes: 130647853
Test: make checkapi
Test: atest EnsureBarContrastTest NavigationBarColorTest
Change-Id: Iafbdce8476134df56ea5d15155391b10afc9ce94
2019-04-17 21:36:04 +02:00
Charles Chen
5a2e6040c2 Merge "Revert "Unify context in ViewRoot"" into qt-dev 2019-04-17 13:45:23 +00:00
Charles Chen
fd85036cc7 Revert "Unify context in ViewRoot"
This reverts commit 44f5215ee8.

Reason for revert: <Make Ime test in SystemDecorationTest failed>
Bug: 130715649

Change-Id: I9afb1d5ee7e7a4f1e7de6fa4c7c3ec5dcc336f08
2019-04-17 13:39:06 +00:00
TreeHugger Robot
c1a0fbcec5 Merge "Unregister ImeInsetsSourceConsumer when focus lost" into qt-dev 2019-04-17 13:03:28 +00:00
TreeHugger Robot
59ed9a7f27 Merge "Follow-up CL of ag/6935284, add entities to extras in generateLinks" into qt-dev 2019-04-17 10:11:18 +00:00
TreeHugger Robot
143c735ee6 Merge "Doing sublisting after deduplication" into qt-dev 2019-04-17 10:09:38 +00:00
Tony Mak
0bf14e4804 Merge "Split TextClassifierEvent into multiple subclasses" into qt-dev 2019-04-17 10:05:20 +00:00
TreeHugger Robot
2569d579a4 Merge "Unify context in ViewRoot" into qt-dev 2019-04-17 04:11:46 +00:00
Felipe Leme
17203cd88b Merge "Fixed AutofillOptions.isAugmentedAutofillEnabled to use the right client." into qt-dev 2019-04-17 03:43:59 +00:00
TreeHugger Robot
341ea09831 Merge "Gesture exclusion rects for Window" into qt-dev 2019-04-17 03:18:55 +00:00
Jacky Kao
fd9a858a40 Merge "Clarify documentation for View#setScreenReaderFocusable" into qt-dev 2019-04-17 02:11:52 +00:00
Adam Powell
5a40b71cd9 Gesture exclusion rects for Window
Property methods to get/set gesture exclusion rects for a window.
This is useful for games or other frameworks that use Window#takeSurface
and do not have a view hierarchy, leaving the associated View methods
unavailable.

Bug: 130572780
Test: cts via "atest SystemGestureExclusionRectsTest"
Change-Id: I2704aef1d1950158fcabf7c91413bedee08b8971
2019-04-16 14:38:55 -07:00
Felipe Leme
e5aa5ebd60 Fixed AutofillOptions.isAugmentedAutofillEnabled to use the right client.
Also removed ContentCaptureClient, which is not used anymore (it probably became obsolete with the
ContentCaptureOptions optimization).

Fixes: 130585342
Test: atest CtsAutoFillServiceTestCases:android.autofillservice.cts.augmented.AugmentedLoginNotImportantForAutofillActivityTest
Test: manual verification with Dialer app

Change-Id: I041922874fac749f1f5d49793f1ad3e26cc345d6
2019-04-16 13:14:41 -07:00
Felipe Leme
dc868e04f9 Merge "Clarified format of ContentCaptureCondition.FLAG_IS_REGEX" into qt-dev 2019-04-16 19:34:37 +00:00
TreeHugger Robot
50a56879e5 Merge "Grant clipboard access to the Augmented Autofill service." into qt-dev 2019-04-16 19:19:37 +00:00
Abodunrinwa Toki
6d06337157 Split TextClassifierEvent into multiple subclasses
As per the suggestion from API council, we now have a subclass for event
of each category.

Bug: 129344540

Test: atest frameworks/base/core/tests/coretests/src/android/view/textclassifier/
Test: atest cts/tests/tests/view/src/android/view/textclassifier/cts/
Test: atest frameworks/base/packages/ExtServices/tests/src/android/ext/services/notification/SmartActionsHelperTest.java

Change-Id: Ic43b33c2176447c40e64bd0e410e906d5fb9c4cc
2019-04-16 13:22:25 +01:00
TreeHugger Robot
786714e526 Merge "Add missing set/getExtras to ConversationActions.Request." into qt-dev 2019-04-16 00:17:10 +00:00
TreeHugger Robot
11141109f4 Merge "DO NOT MERGE - Removed ContentCapture support from standard SDK toolkit." into qt-dev 2019-04-15 23:42:14 +00:00
TreeHugger Robot
472893443d Merge "Fix for unexpected scale factors in ScaleGestureDetector" into qt-dev 2019-04-15 21:02:19 +00:00
Tony Mak
170f35bc59 Add missing set/getExtras to ConversationActions.Request.
All requests / result objects from TextClassifier have get/setRequest,
so ConversationActions.Request should have them as well.

BUG: 130529981

Test: atest cts/tests/tests/view/src/android/view/textclassifier/cts/ConversationActionsTest.java

Change-Id: I19719b009d4f34df8650c669cc24cb304293407a
2019-04-15 20:11:36 +00:00
Felipe Leme
4cb2c3db13 Clarified format of ContentCaptureCondition.FLAG_IS_REGEX
Test: make ds-docs
Fixes: 130313634

Change-Id: I715ba4b7a1e3f3b13fbc521db925f716607763e6
2019-04-15 12:27:26 -07:00
Felipe Leme
ef1c0b36ab DO NOT MERGE - Removed ContentCapture support from standard SDK toolkit.
Test: atest CtsContentCaptureServiceTestCases
Test: m update-api
Test: make ds-docs

Fixes: 129982633

Change-Id: I5a0fa4231d0222638830c1abd8015d9f2635996a
2019-04-15 09:36:25 -07:00
Charles Chen
44f5215ee8 Unify context in ViewRoot
To fix the issue that mContext is not updated when moved to another
display, we previously introduce mDisplayContext as a workaround in [1].
Change to use Context#updateDisplay(int) to unify mDisplayContext to
mContext.

[1]: Ifa0ca24e9cf764caf492ee065606680b6a06751a

Bug: 116349163
Test: atest ActivityManagerMultiDisplayTests
Test: atest CtsInputMethodTestCases CtsInputMethodServiceHostTestCases
Test: atest InputMethodManagerTest
Test: atest InsetsControllerTest
Test: atest InsetsSourceConsumerTest
Test: atest ImeInsetsSourceConsumerTest
Test: atest CtsActivityManagerDeviceTestCases:MultiDisplayClientTests

Change-Id: Ic2010e8b533caf01418e0deb8062b8ff597c5abc
2019-04-15 18:02:14 +08:00
Michael Wright
b0241bd88a Merge "Add class docs for InputMonitor." into qt-dev 2019-04-12 21:39:51 +00:00
Tony Mak
b6afd3c13e Follow-up CL of ag/6935284, add entities to extras in generateLinks
Forgot to add this in generateLinks.

BUG: 129119759

Test: frameworks/base/core/tests/coretests/src/android/view/textclassifier/

Change-Id: I1882ed496b4a8aa04aaced4e9d632b47393dccbf
2019-04-12 17:38:36 +00:00
Abodunrinwa Toki
b7f24a557e Merge "Null annotations in TC APIs." into qt-dev 2019-04-12 17:36:24 +00:00
Peiyong Lin
2a4e6f6e2d Merge "Determine the dataspace of the screenshot buffer based on display color mode." into qt-dev 2019-04-12 16:57:38 +00:00
Felipe Leme
c743634138 Grant clipboard access to the Augmented Autofill service.
Test: atest CtsAutoFillServiceTestCases:android.autofillservice.cts.augmented.ClipboardAccessTest
Fixes: 130166067

Change-Id: I5d55a5921bb961565d6e9cb535927df80c67f79b
2019-04-12 09:22:10 -07:00
Mihai Popa
8621631bf8 Merge "Revert "Stop window redraws for invisible parent children"" into qt-dev 2019-04-12 10:26:10 +00:00
Adrian Roos
76d2f52e3f Merge "System Bars: API to ensure contrast when app requested transparent bar" into qt-dev 2019-04-12 09:43:57 +00:00
Jacky Kao
d55fb27c9d Clarify documentation for View#setScreenReaderFocusable
Modify the document of this method, View#setScreenReaderFocusable,
To make as clear and precise as possible

Bug: 109898645
Test: Java Doc Build PASS
Change-Id: I683d420b6f1a4743d57dad9d06a343b85ec5da00
2019-04-12 16:59:06 +08:00
Louis Chang
3d4a7d1bc9 Unregister ImeInsetsSourceConsumer when focus lost
ImeInsetsSourceConsumer was not unregistered when focus lost, it
was still references by InputMethodManager. So, the last activity
in the process won’t be GCed even though it has been destroyed.

Bug: 130216346
Test: atest ImeInsetsSourceConsumerTest
Change-Id: Ida19411d8361180692e7de7e012d2cd3b431fa9f
2019-04-12 16:18:30 +08:00
TreeHugger Robot
73913e3bf6 Merge "Fixing HardwareBuffer leak when creating a bitmap" into qt-dev 2019-04-11 21:06:40 +00:00
Alison Cichowlas
902e82278a Merge "Add a longpress timeout config for screenshot chord" into qt-dev 2019-04-11 18:33:43 +00:00