Loading api/current.txt +3 −0 Original line number Diff line number Diff line Loading @@ -44648,6 +44648,7 @@ package android.view.inputmethod { ctor public BaseInputConnection(android.view.View, boolean); method public boolean beginBatchEdit(); method public boolean clearMetaKeyStates(int); method public void closeConnection(); method public boolean commitCompletion(android.view.inputmethod.CompletionInfo); method public boolean commitCorrection(android.view.inputmethod.CorrectionInfo); method public boolean commitText(java.lang.CharSequence, int); Loading Loading @@ -44815,6 +44816,7 @@ package android.view.inputmethod { public abstract interface InputConnection { method public abstract boolean beginBatchEdit(); method public abstract boolean clearMetaKeyStates(int); method public abstract void closeConnection(); method public abstract boolean commitCompletion(android.view.inputmethod.CompletionInfo); method public abstract boolean commitCorrection(android.view.inputmethod.CorrectionInfo); method public abstract boolean commitText(java.lang.CharSequence, int); Loading Loading @@ -44847,6 +44849,7 @@ package android.view.inputmethod { ctor public InputConnectionWrapper(android.view.inputmethod.InputConnection, boolean); method public boolean beginBatchEdit(); method public boolean clearMetaKeyStates(int); method public void closeConnection(); method public boolean commitCompletion(android.view.inputmethod.CompletionInfo); method public boolean commitCorrection(android.view.inputmethod.CorrectionInfo); method public boolean commitText(java.lang.CharSequence, int); api/system-current.txt +3 −0 Original line number Diff line number Diff line Loading @@ -47379,6 +47379,7 @@ package android.view.inputmethod { ctor public BaseInputConnection(android.view.View, boolean); method public boolean beginBatchEdit(); method public boolean clearMetaKeyStates(int); method public void closeConnection(); method public boolean commitCompletion(android.view.inputmethod.CompletionInfo); method public boolean commitCorrection(android.view.inputmethod.CorrectionInfo); method public boolean commitText(java.lang.CharSequence, int); Loading Loading @@ -47546,6 +47547,7 @@ package android.view.inputmethod { public abstract interface InputConnection { method public abstract boolean beginBatchEdit(); method public abstract boolean clearMetaKeyStates(int); method public abstract void closeConnection(); method public abstract boolean commitCompletion(android.view.inputmethod.CompletionInfo); method public abstract boolean commitCorrection(android.view.inputmethod.CorrectionInfo); method public abstract boolean commitText(java.lang.CharSequence, int); Loading Loading @@ -47578,6 +47580,7 @@ package android.view.inputmethod { ctor public InputConnectionWrapper(android.view.inputmethod.InputConnection, boolean); method public boolean beginBatchEdit(); method public boolean clearMetaKeyStates(int); method public void closeConnection(); method public boolean commitCompletion(android.view.inputmethod.CompletionInfo); method public boolean commitCorrection(android.view.inputmethod.CorrectionInfo); method public boolean commitText(java.lang.CharSequence, int); api/test-current.txt +3 −0 Original line number Diff line number Diff line Loading @@ -44722,6 +44722,7 @@ package android.view.inputmethod { ctor public BaseInputConnection(android.view.View, boolean); method public boolean beginBatchEdit(); method public boolean clearMetaKeyStates(int); method public void closeConnection(); method public boolean commitCompletion(android.view.inputmethod.CompletionInfo); method public boolean commitCorrection(android.view.inputmethod.CorrectionInfo); method public boolean commitText(java.lang.CharSequence, int); Loading Loading @@ -44889,6 +44890,7 @@ package android.view.inputmethod { public abstract interface InputConnection { method public abstract boolean beginBatchEdit(); method public abstract boolean clearMetaKeyStates(int); method public abstract void closeConnection(); method public abstract boolean commitCompletion(android.view.inputmethod.CompletionInfo); method public abstract boolean commitCorrection(android.view.inputmethod.CorrectionInfo); method public abstract boolean commitText(java.lang.CharSequence, int); Loading Loading @@ -44921,6 +44923,7 @@ package android.view.inputmethod { ctor public InputConnectionWrapper(android.view.inputmethod.InputConnection, boolean); method public boolean beginBatchEdit(); method public boolean clearMetaKeyStates(int); method public void closeConnection(); method public boolean commitCompletion(android.view.inputmethod.CompletionInfo); method public boolean commitCorrection(android.view.inputmethod.CorrectionInfo); method public boolean commitText(java.lang.CharSequence, int); core/java/android/view/inputmethod/BaseInputConnection.java +5 −5 Original line number Diff line number Diff line Loading @@ -16,6 +16,7 @@ package android.view.inputmethod; import android.annotation.CallSuper; import android.content.Context; import android.content.res.TypedArray; import android.os.Bundle; Loading Loading @@ -154,12 +155,11 @@ public class BaseInputConnection implements InputConnection { } /** * Called when this InputConnection is no longer used by the InputMethodManager. * * @hide * Default implementation calls {@link #finishComposingText()}. */ public void reportFinish() { // Intentionally empty @CallSuper public void closeConnection() { finishComposingText(); } /** Loading core/java/android/view/inputmethod/InputConnection.java +16 −0 Original line number Diff line number Diff line Loading @@ -45,6 +45,8 @@ import android.view.KeyEvent; * was introduced in {@link android.os.Build.VERSION_CODES#N}.</li> * <li>{@link #getHandler()}}, which was introduced in * {@link android.os.Build.VERSION_CODES#N}.</li> * <li>{@link #closeConnection()}}, which was introduced in * {@link android.os.Build.VERSION_CODES#N}.</li> * </ul> * * <h3>Implementing an IME or an editor</h3> Loading Loading @@ -820,4 +822,18 @@ public interface InputConnection { * @return {@code null} to use the default {@link Handler}. */ public Handler getHandler(); /** * Called by the system up to only once to notify that the system is about to invalidate * connection between the input method and the application. * * <p><strong>Editor authors</strong>: You can clear all the nested batch edit right now and * you no longer need to handle subsequent callbacks on this connection, including * {@link #beginBatchEdit()}}. Note that although the system tries to call this method whenever * possible, there may be a chance that this method is not called in some exceptional * situations.</p> * * <p>Note: This does nothing when called from input methods.</p> */ public void closeConnection(); } Loading
api/current.txt +3 −0 Original line number Diff line number Diff line Loading @@ -44648,6 +44648,7 @@ package android.view.inputmethod { ctor public BaseInputConnection(android.view.View, boolean); method public boolean beginBatchEdit(); method public boolean clearMetaKeyStates(int); method public void closeConnection(); method public boolean commitCompletion(android.view.inputmethod.CompletionInfo); method public boolean commitCorrection(android.view.inputmethod.CorrectionInfo); method public boolean commitText(java.lang.CharSequence, int); Loading Loading @@ -44815,6 +44816,7 @@ package android.view.inputmethod { public abstract interface InputConnection { method public abstract boolean beginBatchEdit(); method public abstract boolean clearMetaKeyStates(int); method public abstract void closeConnection(); method public abstract boolean commitCompletion(android.view.inputmethod.CompletionInfo); method public abstract boolean commitCorrection(android.view.inputmethod.CorrectionInfo); method public abstract boolean commitText(java.lang.CharSequence, int); Loading Loading @@ -44847,6 +44849,7 @@ package android.view.inputmethod { ctor public InputConnectionWrapper(android.view.inputmethod.InputConnection, boolean); method public boolean beginBatchEdit(); method public boolean clearMetaKeyStates(int); method public void closeConnection(); method public boolean commitCompletion(android.view.inputmethod.CompletionInfo); method public boolean commitCorrection(android.view.inputmethod.CorrectionInfo); method public boolean commitText(java.lang.CharSequence, int);
api/system-current.txt +3 −0 Original line number Diff line number Diff line Loading @@ -47379,6 +47379,7 @@ package android.view.inputmethod { ctor public BaseInputConnection(android.view.View, boolean); method public boolean beginBatchEdit(); method public boolean clearMetaKeyStates(int); method public void closeConnection(); method public boolean commitCompletion(android.view.inputmethod.CompletionInfo); method public boolean commitCorrection(android.view.inputmethod.CorrectionInfo); method public boolean commitText(java.lang.CharSequence, int); Loading Loading @@ -47546,6 +47547,7 @@ package android.view.inputmethod { public abstract interface InputConnection { method public abstract boolean beginBatchEdit(); method public abstract boolean clearMetaKeyStates(int); method public abstract void closeConnection(); method public abstract boolean commitCompletion(android.view.inputmethod.CompletionInfo); method public abstract boolean commitCorrection(android.view.inputmethod.CorrectionInfo); method public abstract boolean commitText(java.lang.CharSequence, int); Loading Loading @@ -47578,6 +47580,7 @@ package android.view.inputmethod { ctor public InputConnectionWrapper(android.view.inputmethod.InputConnection, boolean); method public boolean beginBatchEdit(); method public boolean clearMetaKeyStates(int); method public void closeConnection(); method public boolean commitCompletion(android.view.inputmethod.CompletionInfo); method public boolean commitCorrection(android.view.inputmethod.CorrectionInfo); method public boolean commitText(java.lang.CharSequence, int);
api/test-current.txt +3 −0 Original line number Diff line number Diff line Loading @@ -44722,6 +44722,7 @@ package android.view.inputmethod { ctor public BaseInputConnection(android.view.View, boolean); method public boolean beginBatchEdit(); method public boolean clearMetaKeyStates(int); method public void closeConnection(); method public boolean commitCompletion(android.view.inputmethod.CompletionInfo); method public boolean commitCorrection(android.view.inputmethod.CorrectionInfo); method public boolean commitText(java.lang.CharSequence, int); Loading Loading @@ -44889,6 +44890,7 @@ package android.view.inputmethod { public abstract interface InputConnection { method public abstract boolean beginBatchEdit(); method public abstract boolean clearMetaKeyStates(int); method public abstract void closeConnection(); method public abstract boolean commitCompletion(android.view.inputmethod.CompletionInfo); method public abstract boolean commitCorrection(android.view.inputmethod.CorrectionInfo); method public abstract boolean commitText(java.lang.CharSequence, int); Loading Loading @@ -44921,6 +44923,7 @@ package android.view.inputmethod { ctor public InputConnectionWrapper(android.view.inputmethod.InputConnection, boolean); method public boolean beginBatchEdit(); method public boolean clearMetaKeyStates(int); method public void closeConnection(); method public boolean commitCompletion(android.view.inputmethod.CompletionInfo); method public boolean commitCorrection(android.view.inputmethod.CorrectionInfo); method public boolean commitText(java.lang.CharSequence, int);
core/java/android/view/inputmethod/BaseInputConnection.java +5 −5 Original line number Diff line number Diff line Loading @@ -16,6 +16,7 @@ package android.view.inputmethod; import android.annotation.CallSuper; import android.content.Context; import android.content.res.TypedArray; import android.os.Bundle; Loading Loading @@ -154,12 +155,11 @@ public class BaseInputConnection implements InputConnection { } /** * Called when this InputConnection is no longer used by the InputMethodManager. * * @hide * Default implementation calls {@link #finishComposingText()}. */ public void reportFinish() { // Intentionally empty @CallSuper public void closeConnection() { finishComposingText(); } /** Loading
core/java/android/view/inputmethod/InputConnection.java +16 −0 Original line number Diff line number Diff line Loading @@ -45,6 +45,8 @@ import android.view.KeyEvent; * was introduced in {@link android.os.Build.VERSION_CODES#N}.</li> * <li>{@link #getHandler()}}, which was introduced in * {@link android.os.Build.VERSION_CODES#N}.</li> * <li>{@link #closeConnection()}}, which was introduced in * {@link android.os.Build.VERSION_CODES#N}.</li> * </ul> * * <h3>Implementing an IME or an editor</h3> Loading Loading @@ -820,4 +822,18 @@ public interface InputConnection { * @return {@code null} to use the default {@link Handler}. */ public Handler getHandler(); /** * Called by the system up to only once to notify that the system is about to invalidate * connection between the input method and the application. * * <p><strong>Editor authors</strong>: You can clear all the nested batch edit right now and * you no longer need to handle subsequent callbacks on this connection, including * {@link #beginBatchEdit()}}. Note that although the system tries to call this method whenever * possible, there may be a chance that this method is not called in some exceptional * situations.</p> * * <p>Note: This does nothing when called from input methods.</p> */ public void closeConnection(); }