private void TxtPas_IconClick(object sender, EventArgs e) { TxtPas.IsSystemPasswordChar = true; var xx = new CCWin.SkinControl.SkinWaterTextBox(); xx.UseSystemPasswordChar = true; xx.PasswordChar = '*'; xx.TextChanged += delegate(object senderx, EventArgs ex) { TxtPas.Text = xx.Text; };//new EventHandler(textBox2_TextChanged) ;} PassKey pass = new PassKey(this.Left + TxtPas.Left - 25, this.Top + TxtPas.Bottom, xx); pass.Show(); }
private void textBoxPwd_IconClick(object sender, EventArgs e) { PassKey pass = new PassKey(this.Left + this.textBoxPwd.Left - 25, this.Top + this.textBoxPwd.Bottom, this.textBoxPwd.SkinTxt); pass.Show(this); }
private void txtPwd_IconClick(object sender, EventArgs e) { PassKey pass = new PassKey(this.Left + txtPwd.Left - 25, this.Top + txtPwd.Bottom, txtPwd); pass.Show(); }
private void password_IconClick(object sender, EventArgs e) //软键盘 { PassKey pass = new PassKey(this.Left + password.Left - 25, this.Top + password.Bottom, password.SkinTxt); pass.Show(this); }
private void btnKeyBoard_Click(object sender, EventArgs e) { PassKey pk = new PassKey(this.Left + btnKeyBoard.Left - 110, this.Top + btnKeyBoard.Bottom+50 + pnlBase.Top, txtPwd); pk.Show(this); }
private void btnJpPwd_Click(object sender, EventArgs e) { PassKey pass = new PassKey(this.Left + tbox_password.Left - 25, this.Top + tbox_password.Bottom + 1, tbox_password.SkinTxt); pass.Show(this); }
private void BtnJpPwd_Click(object sender, EventArgs e) { PassKey pass = new PassKey(this.Left + TextPwd.Left - 25, this.Top + TextPwd.Bottom + 1, TextPwd.SkinTxt); pass.Show(this); }
void InitEvents() { stbPassword.IconClick += delegate { PassKey passKey = new PassKey( Left + stbPassword.Left, Top + stbPassword.Bottom, stbPassword.SkinTxt); passKey.Show(this); }; checkBoxRememberPwd.CheckedChanged += (sender, e) => { if (!checkBoxRememberPwd.Checked) { checkBoxAutoLogin.Checked = false; } }; checkBoxAutoLogin.CheckedChanged += (sender, e) => { if (checkBoxAutoLogin.Checked) { checkBoxRememberPwd.Checked = true; } }; EventHandler btnMouseEnter = (sender, e) => { var control = sender as Control; control.ForeColor = Color.FromArgb(98, 180, 247); }; EventHandler btnMouseLeave = (sender, e) => { var control = sender as Control; control.ForeColor = Color.FromArgb(39, 134, 228); }; EventHandler tbFocus = (sender, e) => { var control = sender as Control; errorProvider.SetError(control.Parent, string.Empty); }; btnRegister.MouseEnter += btnMouseEnter; btnForgotPassword.MouseEnter += btnMouseEnter; btnRegister.MouseLeave += btnMouseLeave; btnForgotPassword.MouseLeave += btnMouseLeave; stbAccount.SkinTxt.GotFocus += tbFocus; stbPassword.SkinTxt.GotFocus += tbFocus; btnLogin.Click += btnLogin_Click; btnRegister.Click += (sender, e) => { var view = _viewFactory.GetView <ViewRegister>(); view.ShowDialog(this); }; btnForgotPassword.Click += (sender, e) => { MessageBoxEx.Show(this, "请联系管理员!", "忘记密码", MessageBoxButtons.OK, MessageBoxIcon.Information); }; }