本文整理了Java中android.widget.AutoCompleteTextView.setOnEditorActionListener()
方法的一些代码示例,展示了AutoCompleteTextView.setOnEditorActionListener()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。AutoCompleteTextView.setOnEditorActionListener()
方法的具体详情如下:
包路径:android.widget.AutoCompleteTextView
类名称:AutoCompleteTextView
方法名:setOnEditorActionListener
暂无
代码示例来源:origin: playerone-id/EosCommander
@Override
protected void setUpView(View view) {
mEtContract = view.findViewById( R.id.et_contract_account );
mEtContract.setOnEditorActionListener( this);
mActionSpinner = view.findViewById( R.id.sp_action_name );
mEtMsg = view.findViewById(R.id.et_message);
mEtPermissionAccount= view.findViewById( R.id.et_permission_account );
mEtPermissionAccount.setOnEditorActionListener( this);
mEtPermissionName = view.findViewById( R.id.et_permission_name );
mEtPermissionName.setOnEditorActionListener( this);
view.findViewById(R.id.btn_get_abi).setOnClickListener( v -> onContractEntered( mEtContract.getText().toString()) );
view.findViewById(R.id.btn_ui_input).setOnClickListener( v -> mPresenter.onRequestInputUi((String)mActionSpinner.getSelectedItem()) );
view.findViewById(R.id.btn_import).setOnClickListener( v -> mPresenter.onImportFileClicked() );
view.findViewById(R.id.btn_ok).setOnClickListener( v -> onPushAction() );
// NEW_ACCOUNT_SUGGEST
setupAccountHistory();
Console.writeLine("Hello Console!");
}
代码示例来源:origin: playerone-id/EosCommander
mEtNewAccount.setOnEditorActionListener( (textView, actionId, keyEvent) -> {
if (EditorInfo.IME_ACTION_DONE == actionId) {
onClickCreate();
代码示例来源:origin: AEFeinstein/mtg-familiar
);
if (null != addCardListener) {
mNameField.setOnEditorActionListener(addCardListener);
代码示例来源:origin: AEFeinstein/mtg-familiar
mNameField.setOnEditorActionListener(doSearchListener);
mTextField.setOnEditorActionListener(doSearchListener);
mSupertypeField.setOnEditorActionListener(doSearchListener);
mManaCostTextView.setOnEditorActionListener(doSearchListener);
mFlavorField.setOnEditorActionListener(doSearchListener);
mArtistField.setOnEditorActionListener(doSearchListener);
mWatermarkField.setOnEditorActionListener(doSearchListener);
mCollectorsNumberField.setOnEditorActionListener(doSearchListener);
代码示例来源:origin: stackoverflow.com
webView.getSettings().setSupportZoom(false);
edtUrl.setOnEditorActionListener(new TextView.OnEditorActionListener() {
@Override
public boolean onEditorAction(TextView textView, int i, KeyEvent keyEvent) {
代码示例来源:origin: wasdennnoch/AndroidN-ify
public AutoCompleteEditTextPreference(Context context, AttributeSet attrs, int defStyleAttr,
int defStyleRes) {
super(context, attrs, defStyleAttr, defStyleRes);
mAutoCompleteTextView = new InstantAutoCompleteTextView(context, attrs);
// Give it an ID so it can be saved/restored
mAutoCompleteTextView.setId(R.id.edit);
/*
* The preference framework and view framework both have an 'enabled'
* attribute. Most likely, the 'enabled' specified in this XML is for
* the preference framework, but it was also given to the view framework.
* We reset the enabled state.
*/
mAutoCompleteTextView.setEnabled(true);
mAutoCompleteTextView.setOnEditorActionListener(new TextView.OnEditorActionListener() {
@Override
public boolean onEditorAction(TextView v, int actionId, KeyEvent event) {
if (actionId == EditorInfo.IME_ACTION_DONE) {
onClick(getDialog(), DialogInterface.BUTTON_POSITIVE);
getDialog().dismiss();
return true;
}
return false;
}
});
setDialogLayoutResource(R.layout.preference_dialog_autocomplete_edittext);
}
代码示例来源:origin: trezor/trezor-android
autocomplete.setOnEditorActionListener(new OnEditorActionListener() {
@Override
public boolean onEditorAction(TextView textView, int actionId, KeyEvent keyEvent) {
代码示例来源:origin: stackoverflow.com
mAutoComp.setOnEditorActionListener(this);
代码示例来源:origin: mitchtabian/Google-Maps-Google-Places
mSearchText.setOnEditorActionListener(new TextView.OnEditorActionListener() {
@Override
public boolean onEditorAction(TextView textView, int actionId, KeyEvent keyEvent) {
代码示例来源:origin: TongmingWu/Manga
etSearch.setOnEditorActionListener(new TextView.OnEditorActionListener() {
@Override
public boolean onEditorAction(TextView v, int actionId, KeyEvent event) {
代码示例来源:origin: andstatus/andstatus
return;
searchText.setOnEditorActionListener(new TextView.OnEditorActionListener() {
@Override
代码示例来源:origin: TUM-Dev/Campus-Android
});
searchView.setOnEditorActionListener((textView, actionId, keyEvent) -> {
if (actionId == EditorInfo.IME_ACTION_SEARCH) {
Utils.log("Search");
代码示例来源:origin: ybonnel/TransportsRennes
adresseArrivee.setAdapter(adapterArrivee);
adresseArrivee.setTextColor(TransportsRennesApplication.getTextColor(this));
adresseArrivee.setOnEditorActionListener(new TextView.OnEditorActionListener() {
代码示例来源:origin: ybonnel/TransportsRennes
adresseArrivee.setAdapter(adapterArrivee);
adresseArrivee.setTextColor(AbstractTransportsApplication.getTextColor(this));
adresseArrivee.setOnEditorActionListener(new TextView.OnEditorActionListener() {
代码示例来源:origin: adolfAn/FBReader_AS
myInputField.setOnEditorActionListener(new TextView.OnEditorActionListener(){
public boolean onEditorAction (TextView v, int actionId, KeyEvent event){
if(actionId == EditorInfo.IME_ACTION_DONE){
代码示例来源:origin: CUTR-at-USF/OpenTripPlanner-for-Android
.setOnEditorActionListener(tbLocationOnEditorActionListener);
mTbEndLocation
.setOnEditorActionListener(tbLocationOnEditorActionListener);
代码示例来源:origin: adolfAn/FBReader_AS
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.edit_tags_dialog);
myResource = ZLResource.resource("dialog").getResource("editTags");
final Intent intent = getIntent();
ArrayList<String> allTagsList = intent.getStringArrayListExtra(EditListDialogActivity.Key.ALL_ITEMS_LIST);
myInputField = (AutoCompleteTextView)findViewById(R.id.edit_tags_input_field);
myInputField.setHint(myResource.getResource("addTag").getValue());
myInputField.setOnEditorActionListener(new TextView.OnEditorActionListener(){
public boolean onEditorAction (TextView v, int actionId, KeyEvent event){
if(actionId == EditorInfo.IME_ACTION_DONE){
addTag(myInputField.getText().toString(), myEditPosition);
myInputField.setText("");
myEditPosition = -1;
return false;
}
return true;
}
});
myInputField.setAdapter(new ArrayAdapter<String>(this, android.R.layout.simple_dropdown_item_1line, allTagsList));
parseUIElements();
final TagsAdapter adapter = new TagsAdapter();
setListAdapter(adapter);
getListView().setOnItemClickListener(adapter);
getListView().setOnItemLongClickListener(adapter);
setResult(RESULT_CANCELED);
}
代码示例来源:origin: LineageOS/android_packages_apps_Jelly
AutoCompleteTextView autoCompleteTextView = findViewById(R.id.url_bar);
autoCompleteTextView.setAdapter(new SuggestionsAdapter(this));
autoCompleteTextView.setOnEditorActionListener((v, actionId, event) -> {
if (actionId == EditorInfo.IME_ACTION_SEARCH) {
UiUtils.hideKeyboard(autoCompleteTextView);
代码示例来源:origin: AmaldevTA/ChipLayout
autoCompleteTextView.setOnEditorActionListener(new ChipEditorActionListener(autoCompleteTextView));
autoCompleteTextView.setAdapter(adapter);
int density = context.getResources().getDisplayMetrics().densityDpi;
代码示例来源:origin: derry/delion
mInput = (AutoCompleteTextView) findViewById(R.id.text_view);
mInput.setText(fieldModel.getValue());
mInput.setOnEditorActionListener(actionlistener);
内容来源于网络,如有侵权,请联系作者删除!