summaryrefslogtreecommitdiff
path: root/core/java/android/view/ContentInfo.java
Commit message (Collapse)AuthorAgeFilesLines
* Update ContentInfo to implement ParcelableNikita Dubrovsky2021-04-301-1/+74
| | | | | | Bug: 186683314 Test: atest CtsViewReceiveContentTestCases:ContentInfoTest Change-Id: I59376947cfa8dad5d2021cb1d2f5c121a1f90596
* Expose test APIs on ContentInfo and add CTS coverageNikita Dubrovsky2021-04-281-0/+5
| | | | | | Bug: 183643556 Test: atest CtsViewReceiveContentTestCases:ContentInfoTest Change-Id: I65e8fbab27433584590366292ed79d230c1b95e5
* OnReceiveContentListener: Handle IME insertion permissions releaseNikita Dubrovsky2021-03-251-0/+53
| | | | | | | | | | | | | | | | | | | | | | | | | For content insertion from the IME, the platform currently assumes that it can automatically revoke URI permissions (via InputContentUriTokenHandler.finalize) any time after the InputContentInfo instance is garbage collected and InputContentInfo.releasePermission() has not been called explicitly. This can cause permissions to be revoked before the receiving code has had a chance to read the content when using OnReceiveContentListener, since we did not keep a reference to InputContentInfo. This change does the following: * Sets the InputContentInfo instance in the ContentInfo payload passed to OnReceiveContentListener. * Exposes a hidden API on ContentInfo to allow system features to proactively release permissions for sources that allow this (IME and drag-and-drop). * Updates notifications direct-reply code to proactively release permissions as soon as they are no longer needed. Bug: 183643556 Test: Manual Change-Id: I1cbc55d53804810a3cd4b6b97c197f4dd2d7d8e6
* API: Suppress existing NullableCollections lints (S edition)Adrian Roos2021-02-011-1/+3
| | | | | | | Bug: 152525509 Test: make checkapi Change-Id: Idf96709bf93ef49ca5ad3cdd1f14d06e0d9e09d7 Exempt-From-Owner-Approval: API lint large scale change
* Hide ContentInfo.partition from the public APINikita Dubrovsky2020-12-141-0/+4
| | | | | | | | | | | | Per API Council feedback, this method will not be exposed in the public API. App developers will instead use the support library for this. Rather than removing the method completely, it is marked with @hide so that it can still be used in system code (e.g. RemoteInputView). Bug: 174125311 Test: atest CtsViewTestCases:ContentInfoTest Change-Id: I83b55bea38c0d2b3dc60a16658616e46ebe4cb48
* Update ContentInfo.partition to return a Pair instead of a MapNikita Dubrovsky2020-12-021-29/+30
| | | | | | Bug: 174125311 Test: atest CtsViewTestCases:ContentInfoTest Change-Id: I91908fe3b23fca8e530b2b107c57ba80761f67ac
* Move/rename OnReceiveContentListener.Payload to android.view.ContentInfoNikita Dubrovsky2020-11-271-0/+358
Bug: 174125311 Test: atest CtsViewTestCases:ViewOnReceiveContentTest Test: atest CtsWidgetTestCases:TextViewOnReceiveContentTest Test: atest FrameworksCoreTests:TextViewOnReceiveContentTest Change-Id: If3988dfe9dbed6bcd5e1f1566cb3ecdb111aef3f