@Override
 public void handleMessage(Message msg) {
   if (msg.what == 1) {
     Utils.showLayout(layoutImgs, 0, height, Utils.ANIMATION_DURATION);
   } else if (msg.what == 2) {
     Utils.inputMethod(context, true, layoutImgs); // 先隐藏输入法
   }
 }
  /** 点击表情图片的其它地方时隐藏表情 */
  public void hideFaceLayout() {
    if (!isJianPan) {
      isJianPan = true;
      Utils.showLayout(layoutImgs, height, 0, Utils.ANIMATION_DURATION);
      imageView.setImageDrawable(getResources().getDrawable(R.drawable.jianpan));
    }

    Utils.inputMethod(context, false, layoutImgs); // 先隐藏输入法
  }
  private boolean check() {
    if (Utils.stringIsNull(editText1.getText().toString())) {
      Utils.showToast(UpdatePasswordActivity.this, "原密码不能为空");
      return false;
    }

    if (Utils.stringIsNull(editText2.getText().toString())) {
      Utils.showToast(UpdatePasswordActivity.this, "新密码不能为空");
      return false;
    }

    if (editText2.getText().toString().length() < 6
        || editText2.getText().toString().length() > 16) {
      Utils.showToast(mContext, "请填写长度为6-16位的密码");
      return false;
    }

    if (Utils.stringIsNull(editText3.getText().toString())) {
      Utils.showToast(UpdatePasswordActivity.this, "确认密码不能为空");
      return false;
    }

    if (!editText2.getText().toString().trim().equals(editText3.getText().toString().trim())) {
      Utils.showToast(UpdatePasswordActivity.this, "新密码和确认密码不一致");
      return false;
    }

    return true;
  }
  private void sendReply(String uuid, final String replyContent) {
    if (Utils.stringIsNull(replyContent)) {
      Utils.showToast(getActivity(), "请输入内容");
      return;
    }
    hideBottomLayout();
    ((CourseInteractionListActivity) getActivity()).showProgressDialog("发表回复中,请稍候...");
    UserRequest.reply(
        getActivity(),
        uuid,
        replyContent.trim(),
        "",
        ((CourseInteractionListActivity) getActivity()).getType(),
        new RequestResultI() {
          @Override
          public void result(BaseModel domain) {
            try {
              ((CourseInteractionListActivity) getActivity()).hideProgressDialog();
            } catch (Exception e) {
              e.printStackTrace();
            }
            emot2.cleanEditText();
            bottomLayou.setVisibility(View.GONE);
            emot2.hideSoftKeyboard();
            Reply reply = new Reply();
            reply.setContent(replyContent.trim());
            reply.setCreate_user(CGApplication.getInstance().getLogin().getUserinfo().getName());
            courseInteractionAdapter.addReply(replyInteraction, reply);
          }

          @Override
          public void result(List<BaseModel> domains, int total) {}

          @Override
          public void failure(String message) {
            try {
              ((InteractionListActivity) getActivity()).hideProgressDialog();
            } catch (Exception e) {
              e.printStackTrace();
            }
            Utils.showToast(CGApplication.getInstance(), message);
          }
        });
  }
 @Override
 public void onClick(View v) {
   switch (v.getId()) {
     case R.id.layout_biao_qing:
       CGLog.d("H: " + height);
       if (isJianPan) {
         Utils.inputMethod(context, false, layoutImgs); // 先隐藏输入法
         handler.sendEmptyMessageDelayed(1, 300);
         imageView.setImageDrawable(getResources().getDrawable(R.drawable.jianpan));
         isJianPan = false;
       } else {
         Utils.showLayout(layoutImgs, height, 0, Utils.ANIMATION_DURATION);
         handler.sendEmptyMessageDelayed(2, 300);
         imageView.setImageDrawable(getResources().getDrawable(R.drawable.bq));
         isJianPan = true;
       }
       break;
     case R.id.et_message:
       if (!isJianPan) {
         isJianPan = true;
         Utils.showLayout(layoutImgs, height, 0, 100);
         imageView.setImageDrawable(getResources().getDrawable(R.drawable.bq));
       }
       break;
     case R.id.layout_send:
       if (Utils.stringIsNull(etMessage.getText().toString())) {
         Utils.showToast(context, "消息不能为空");
         return;
       } else {
         sendMessage.send(etMessage.getText().toString().trim());
       }
       break;
     default:
       break;
   }
 }
 @Override
 protected void onCreate(Bundle savedInstanceState) {
   super.onCreate(savedInstanceState);
   setContentView(R.layout.bound_tel_dialog);
   bound_tel_confirm_now = (TextView) findViewById(R.id.bound_tel_confirm_now);
   bound_tel_confirm_later = (TextView) findViewById(R.id.bound_tel_confirm_later);
   if (!Utils.stringIsNull(title)) bound_tel_confirm_now.setText("" + title);
   bound_tel_confirm_now.setOnClickListener(
       new View.OnClickListener() {
         @Override
         public void onClick(View v) {
           cancel();
           if (afterListener != null) afterListener.bound();
         }
       });
   bound_tel_confirm_later.setOnClickListener(
       new View.OnClickListener() {
         @Override
         public void onClick(View v) {
           cancel();
           if (afterListener != null) afterListener.igone();
         }
       });
 }
 public void showInput() {
   Utils.inputMethod(context, true, layoutImgs); // 先隐藏输入法
   etMessage.setFocusable(true);
   etMessage.requestFocus();
 }
 public void hideSoftKeyboard() {
   Utils.inputMethod(context, false, etMessage);
 }
 public void showSoftKeyboard() {
   etMessage.requestFocus();
   Utils.inputMethod(context, true, etMessage);
 }