项目:Beem
文件:AccountConfigureFragment.java
@Override
public View onCreateView(LayoutInflater inflater,ViewGroup container,Bundle savedInstanceState) {
View v = inflater.inflate(R.layout.wizard_account_configure,container,false);
mManualConfigButton = (Button) v.findViewById(R.id.manual_setup);
mManualConfigButton.setOnClickListener(this);
mNextButton = (Button) v.findViewById(R.id.next);
mNextButton.setOnClickListener(this);
mSelectAccountButton = (Button) v.findViewById(R.id.select_account_btn);
mSelectAccountButton.setOnClickListener(this);
mErrorLabel = (TextView) v.findViewById(R.id.error_label);
mSettingsWarningLabel = (TextView) v.findViewById(R.id.settings_warn_label);
mAccountJID = (EditText) v.findViewById(R.id.account_username);
mAccountPassword = (EditText) v.findViewById(R.id.account_password);
InputFilter[] orgFilters = mAccountJID.getFilters();
InputFilter[] newFilters = new InputFilter[orgFilters.length + 1];
int i;
for (i = 0; i < orgFilters.length; i++)
newFilters[i] = orgFilters[i];
newFilters[i] = new LoginFilter.UsernameFilterGeneric();
mAccountJID.setFilters(newFilters);
mAccountJID.addTextChangedListener(mJidTextWatcher);
mAccountPassword.addTextChangedListener(mPasswordTextWatcher);
if (Build.VERSION.SDK_INT < Build.VERSION_CODES.ICE_CREAM_SANDWICH) // true to disable the feature until ready
v.findViewById(R.id.account_layout).setVisibility(View.GONE);
return v;
}
项目:beem-fork-xmpp
文件:AccountConfigureFragment.java
@Override
public View onCreateView(LayoutInflater inflater,false);
mManualConfigButton = (Button) v.findViewById(R.id.manual_setup);
mManualConfigButton.setOnClickListener(this);
mNextButton = (Button) v.findViewById(R.id.next);
mNextButton.setOnClickListener(this);
mSelectAccountButton = (Button) v.findViewById(R.id.select_account_btn);
mSelectAccountButton.setOnClickListener(this);
mErrorLabel = (TextView) v.findViewById(R.id.error_label);
mSettingsWarningLabel = (TextView) v.findViewById(R.id.settings_warn_label);
mAccountJID = (EditText) v.findViewById(R.id.account_username);
mAccountPassword = (EditText) v.findViewById(R.id.account_password);
InputFilter[] orgFilters = mAccountJID.getFilters();
InputFilter[] newFilters = new InputFilter[orgFilters.length + 1];
int i;
for (i = 0; i < orgFilters.length; i++)
newFilters[i] = orgFilters[i];
newFilters[i] = new LoginFilter.UsernameFilterGeneric();
mAccountJID.setFilters(newFilters);
mAccountJID.addTextChangedListener(mJidTextWatcher);
mAccountPassword.addTextChangedListener(mPasswordTextWatcher);
if (Build.VERSION.SDK_INT < Build.VERSION_CODES.ICE_CREAM_SANDWICH) // true to disable the feature until ready
v.findViewById(R.id.account_layout).setVisibility(View.GONE);
return v;
}
项目:droid-stealth
文件:MorphingFragment.java
@Override
public View onCreateView(LayoutInflater inflater,Bundle savedInstanceState) {
// Inflate the layout for this fragment
View root = inflater.inflate(R.layout.fragment_morphing,false);
if (root == null) {
return null;
}
View pickApp = root.findViewById(R.id.morph_pick_app);
pickApp.setOnClickListener(this);
View pickIcon = root.findViewById(R.id.morph_pick_icon);
pickIcon.setOnClickListener(this);
View share = root.findViewById(R.id.morph_share);
share.setOnClickListener(this);
View reset = root.findViewById(R.id.morph_reset);
reset.setOnClickListener(this);
View morph = root.findViewById(R.id.morph_execute);
morph.setOnClickListener(this);
//TODO: Figure out way to have real max length. In case we pad with spaces.
InputFilter lengthFilter = new InputFilter.LengthFilter(getString(R.string.morphable_app_name).length());
InputFilter asciiFilter = new LoginFilter.PasswordFilterGMail(); // Encodes ISO-8859-1 (Extended Ascii)
mName = (EditText) root.findViewById(R.id.morph_edit_name);
mName.setFilters(new InputFilter[]{lengthFilter,asciiFilter});
mIcon = (ImageView) root.findViewById(R.id.morph_edit_icon);
FontManager.handleFontTags(root);
return root;
}
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。