Code example for InputConnection

Methods: finishComposingText

0
        if (mDeadKeyComposing != 0 && (newSelStart != candidatesEnd
                || newSelEnd != candidatesEnd)) {
            mDeadKeyComposing = 0;
            InputConnection ic = getCurrentInputConnection();
            if (ic != null) {
                ic.finishComposingText();
            } 
        } 
    } 
 
    /** 
     * This tells us about completions that the editor has determined based 
     * on the current text in it.  We want to use this in fullscreen mode 
     * to show the completions ourself, since the editor can not be seen 
     * in that situation. 
     */ 
    @Override public void onDisplayCompletions(CompletionInfo[] completions) {
        if (mCompletionOn) {
            mCompletions = completions;
            if (completions == null) {
                setSuggestions(null, false, false);