summaryrefslogtreecommitdiff
path: root/tools/aapt2/java/JavaClassGenerator.cpp
diff options
context:
space:
mode:
authorNikita Dubrovsky <dubrovsky@google.com>2021-03-04 16:25:53 -0800
committerNikita Dubrovsky <dubrovsky@google.com>2021-03-25 09:37:21 -0700
commit10646dff7e625aa1de718a692a1bb35c7670a3ca (patch)
treec0f8ed9793942e424d6a88328bcc81f3154a50f6 /tools/aapt2/java/JavaClassGenerator.cpp
parent4b7b90e79182805dd52fb0b779a0b4ab08983ab0 (diff)
OnReceiveContentListener: Handle IME insertion permissions release
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
Diffstat (limited to 'tools/aapt2/java/JavaClassGenerator.cpp')
0 files changed, 0 insertions, 0 deletions