use of android.view.inputmethod.BaseInputConnection in project lottie-android by airbnb.
the class LottieFontViewGroup method onCreateInputConnection.
@Override
public InputConnection onCreateInputConnection(EditorInfo outAttrs) {
BaseInputConnection fic = new BaseInputConnection(this, false);
outAttrs.actionLabel = null;
outAttrs.inputType = InputType.TYPE_NULL;
outAttrs.imeOptions = EditorInfo.IME_ACTION_NEXT;
return fic;
}
use of android.view.inputmethod.BaseInputConnection in project platform_frameworks_base by android.
the class AbsListView method onCreateInputConnection.
/**
* Return an InputConnection for editing of the filter text.
*/
@Override
public InputConnection onCreateInputConnection(EditorInfo outAttrs) {
if (isTextFilterEnabled()) {
if (mPublicInputConnection == null) {
mDefInputConnection = new BaseInputConnection(this, false);
mPublicInputConnection = new InputConnectionWrapper(outAttrs);
}
outAttrs.inputType = EditorInfo.TYPE_CLASS_TEXT | EditorInfo.TYPE_TEXT_VARIATION_FILTER;
outAttrs.imeOptions = EditorInfo.IME_ACTION_DONE;
return mPublicInputConnection;
}
return null;
}
use of android.view.inputmethod.BaseInputConnection in project XobotOS by xamarin.
the class AbsListView method onCreateInputConnection.
/**
* Return an InputConnection for editing of the filter text.
*/
@Override
public InputConnection onCreateInputConnection(EditorInfo outAttrs) {
if (isTextFilterEnabled()) {
// XXX we need to have the text filter created, so we can get an
// InputConnection to proxy to. Unfortunately this means we pretty
// much need to make it as soon as a list view gets focus.
createTextFilter(false);
if (mPublicInputConnection == null) {
mDefInputConnection = new BaseInputConnection(this, false);
mPublicInputConnection = new InputConnectionWrapper(mTextFilter.onCreateInputConnection(outAttrs), true) {
@Override
public boolean reportFullscreenMode(boolean enabled) {
// the "real" one the IME is talking with.
return mDefInputConnection.reportFullscreenMode(enabled);
}
@Override
public boolean performEditorAction(int editorAction) {
// the one that does this.
if (editorAction == EditorInfo.IME_ACTION_DONE) {
InputMethodManager imm = (InputMethodManager) getContext().getSystemService(Context.INPUT_METHOD_SERVICE);
if (imm != null) {
imm.hideSoftInputFromWindow(getWindowToken(), 0);
}
return true;
}
return false;
}
@Override
public boolean sendKeyEvent(KeyEvent event) {
// no ViewAncestor to dispatch events with.
return mDefInputConnection.sendKeyEvent(event);
}
};
}
outAttrs.inputType = EditorInfo.TYPE_CLASS_TEXT | EditorInfo.TYPE_TEXT_VARIATION_FILTER;
outAttrs.imeOptions = EditorInfo.IME_ACTION_DONE;
return mPublicInputConnection;
}
return null;
}
use of android.view.inputmethod.BaseInputConnection in project android_frameworks_base by AOSPA.
the class AbsListView method onCreateInputConnection.
/**
* Return an InputConnection for editing of the filter text.
*/
@Override
public InputConnection onCreateInputConnection(EditorInfo outAttrs) {
if (isTextFilterEnabled()) {
if (mPublicInputConnection == null) {
mDefInputConnection = new BaseInputConnection(this, false);
mPublicInputConnection = new InputConnectionWrapper(outAttrs);
}
outAttrs.inputType = EditorInfo.TYPE_CLASS_TEXT | EditorInfo.TYPE_TEXT_VARIATION_FILTER;
outAttrs.imeOptions = EditorInfo.IME_ACTION_DONE;
return mPublicInputConnection;
}
return null;
}
use of android.view.inputmethod.BaseInputConnection in project android_frameworks_base by ResurrectionRemix.
the class AbsListView method onCreateInputConnection.
/**
* Return an InputConnection for editing of the filter text.
*/
@Override
public InputConnection onCreateInputConnection(EditorInfo outAttrs) {
if (isTextFilterEnabled()) {
if (mPublicInputConnection == null) {
mDefInputConnection = new BaseInputConnection(this, false);
mPublicInputConnection = new InputConnectionWrapper(outAttrs);
}
outAttrs.inputType = EditorInfo.TYPE_CLASS_TEXT | EditorInfo.TYPE_TEXT_VARIATION_FILTER;
outAttrs.imeOptions = EditorInfo.IME_ACTION_DONE;
return mPublicInputConnection;
}
return null;
}
Aggregations