Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 5f931ece authored by Wilson Wu's avatar Wilson Wu Committed by Android (Google) Code Review
Browse files

Merge "Deprecate InputMethodInterface methods"

parents 8a8c52ff 08995525
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -18919,8 +18919,8 @@ package android.inputmethodservice {
    method public android.view.View onCreateCandidatesView();
    method public android.view.View onCreateExtractTextView();
    method @Nullable public android.view.inputmethod.InlineSuggestionsRequest onCreateInlineSuggestionsRequest(@NonNull android.os.Bundle);
    method public android.inputmethodservice.AbstractInputMethodService.AbstractInputMethodImpl onCreateInputMethodInterface();
    method public android.inputmethodservice.AbstractInputMethodService.AbstractInputMethodSessionImpl onCreateInputMethodSessionInterface();
    method @Deprecated public android.inputmethodservice.AbstractInputMethodService.AbstractInputMethodImpl onCreateInputMethodInterface();
    method @Deprecated public android.inputmethodservice.AbstractInputMethodService.AbstractInputMethodSessionImpl onCreateInputMethodSessionInterface();
    method public android.view.View onCreateInputView();
    method protected void onCurrentInputMethodSubtypeChanged(android.view.inputmethod.InputMethodSubtype);
    method public void onDisplayCompletions(android.view.inputmethod.CompletionInfo[]);
+17 −0
Original line number Diff line number Diff line
@@ -1749,7 +1749,16 @@ public class InputMethodService extends AbstractInputMethodService {
    /**
     * Implement to return our standard {@link InputMethodImpl}.  Subclasses
     * can override to provide their own customized version.
     *
     * @deprecated IME developers don't need to override this method to get callbacks information.
     * Most methods in {@link InputMethodImpl} have corresponding callbacks.
     * Use {@link InputMethodService#onBindInput()}, {@link InputMethodService#onUnbindInput()},
     * {@link InputMethodService#onWindowShown()}, {@link InputMethodService#onWindowHidden()}, etc.
     *
     * <p>Starting from Android U and later, override this method won't guarantee that IME works
     * as previous platform behavior.</p>
     */
    @Deprecated
    @Override
    public AbstractInputMethodImpl onCreateInputMethodInterface() {
        return new InputMethodImpl();
@@ -1758,7 +1767,15 @@ public class InputMethodService extends AbstractInputMethodService {
    /**
     * Implement to return our standard {@link InputMethodSessionImpl}.  Subclasses
     * can override to provide their own customized version.
     *
     * @deprecated IME developers don't need to override this method to get callbacks information.
     * Most methods in {@link InputMethodSessionImpl} have corresponding callbacks.
     * Use {@link InputMethodService#onFinishInput()},
     * {@link InputMethodService#onDisplayCompletions(CompletionInfo[])},
     * {@link InputMethodService#onUpdateExtractedText(int, ExtractedText)},
     * {@link InputMethodService#onUpdateSelection(int, int, int, int, int, int)} instead.
     */
    @Deprecated
    @Override
    public AbstractInputMethodSessionImpl onCreateInputMethodSessionInterface() {
        return new InputMethodSessionImpl();