diff options
author | Chet Haase <chet@google.com> | 2016-10-13 15:49:09 -0700 |
---|---|---|
committer | gitbuildkicker <android-build@google.com> | 2016-11-01 11:00:46 -0700 |
commit | b5375056fea6c40a2469f48e2497948fb5927b9b (patch) | |
tree | 653a577c0bdbec60e1501b54b96f8628226eac9d | |
parent | 30b7bd5cafc3462727bfbd5b030a26135fa32893 (diff) | |
download | base-b5375056fea6c40a2469f48e2497948fb5927b9b.tar.gz |
Clean up InputConnection.commitContent() javadocs DO NOT MERGEandroid-7.1.1_r2android-7.1.1_r1
Test: docs only, no test apart from verifying that it builds
Bug: #32158219 clean up InputConnection.commitContent() javadocs
Change-Id: I9b438d6b14aa8bc868fe41f7e0fe22b0e83800fb
(cherry picked from commit 5c0af8876468869f21baa204c498f0c975553bf3)
-rw-r--r-- | core/java/android/view/inputmethod/InputConnection.java | 27 |
1 files changed, 15 insertions, 12 deletions
diff --git a/core/java/android/view/inputmethod/InputConnection.java b/core/java/android/view/inputmethod/InputConnection.java index 8023201bc284..71c1d624976b 100644 --- a/core/java/android/view/inputmethod/InputConnection.java +++ b/core/java/android/view/inputmethod/InputConnection.java @@ -860,32 +860,35 @@ public interface InputConnection { android.content.Intent.FLAG_GRANT_READ_URI_PERMISSION; // 0x00000001 /** - * Called by the input method to commit a content such as PNG image to the editor. + * Called by the input method to commit content such as a PNG image to the editor. * - * <p>In order to avoid variety of compatibility issues, this focuses on a simple use case, - * where we expect editors and IMEs work cooperatively as follows:</p> + * <p>In order to avoid a variety of compatibility issues, this focuses on a simple use case, + * where editors and IMEs are expected to work cooperatively as follows:</p> * <ul> - * <li>Editor must keep {@link EditorInfo#contentMimeTypes} to be {@code null} if it does + * <li>Editor must keep {@link EditorInfo#contentMimeTypes} equal to {@code null} if it does * not support this method at all.</li> * <li>Editor can ignore this request when the MIME type specified in - * {@code inputContentInfo} does not match to any of {@link EditorInfo#contentMimeTypes}. + * {@code inputContentInfo} does not match any of {@link EditorInfo#contentMimeTypes}. * </li> - * <li>Editor can ignore the cursor position when inserting the provided context.</li> + * <li>Editor can ignore the cursor position when inserting the provided content.</li> * <li>Editor can return {@code true} asynchronously, even before it starts loading the * content.</li> - * <li>Editor should provide a way to delete the content inserted by this method, or revert - * the effect caused by this method.</li> + * <li>Editor should provide a way to delete the content inserted by this method or to + * revert the effect caused by this method.</li> * <li>IME should not call this method when there is any composing text, in case calling - * this method causes focus change.</li> + * this method causes a focus change.</li> * <li>IME should grant a permission for the editor to read the content. See * {@link EditorInfo#packageName} about how to obtain the package name of the editor.</li> * </ul> * * @param inputContentInfo Content to be inserted. - * @param flags {@code 0} or {@link #INPUT_CONTENT_GRANT_READ_URI_PERMISSION}. + * @param flags {@link #INPUT_CONTENT_GRANT_READ_URI_PERMISSION} if the content provider + * allows {@link android.R.styleable#AndroidManifestProvider_grantUriPermissions + * grantUriPermissions} or {@code 0} if the application does not need to call + * {@link InputContentInfo#requestPermission()}. * @param opts optional bundle data. This can be {@code null}. - * @return {@code true} if this request is accepted by the application, no matter if the request - * is already handled or still being handled in background. + * @return {@code true} if this request is accepted by the application, whether the request + * is already handled or still being handled in background, {@code false} otherwise. */ public boolean commitContent(@NonNull InputContentInfo inputContentInfo, int flags, @Nullable Bundle opts); |