private void initListener() {
    btn_title_right.setOnClickListener(this);
    btn_title_left.setOnClickListener(this);
    loadingoverlay.addOnCancelListener(
        new LoadingOverlay.OnCancelListener() {

          @Override
          public void onCancel() {

            if (regBiz != null) regBiz.cancel();
            loadingoverlay.setVisibility(View.INVISIBLE);
          }
        });

    findpwd_pwd_ET.addOnValidateListener(
        new ExEditText.OnValidateListener() {

          @Override
          public String onValidate(String text) {
            if (StringUtil.isNull(text)) return "请输入密码!";
            else return "";
          }
        });
    findpwd_pwd1_ET.addOnValidateListener(
        new ExEditText.OnValidateListener() {

          @Override
          public String onValidate(String text) {
            if (StringUtil.isNull(text)) return "请输入密码!";
            return "";
          }
        });
  }
Esempio n. 2
0
  private void registerListener() {

    registerTV.setOnClickListener(this);
    findpwdTV.setOnClickListener(this);

    loginButton.setOnClickListener(this);

    loadingoverlay.addOnCancelListener(
        new LoadingOverlay.OnCancelListener() {

          @Override
          public void onCancel() {

            if (biz != null) biz.cancel();
            loadingoverlay.setVisibility(View.INVISIBLE);
          }
        });

    userNameET.addOnValidateListener(
        new ExEditText.OnValidateListener() {

          @Override
          public String onValidate(String text) {
            if (StringUtil.isNull(text)) return "请输入登录账号!";
            else return "";
          }
        });
    passwordET.addOnValidateListener(
        new ExEditText.OnValidateListener() {

          @Override
          public String onValidate(String text) {
            if (StringUtil.isNull(text)) return "请输入密码!";
            return "";
          }
        });
  }