private void LockApp() { string cct = Properties.Settings.Default.currentCounter; if (cct == "null") { lockHolder.Controls.Clear(); visibleCounter.lockMode = true; lockHolder.Controls.Add(visibleCounter.control); } else { ActiveCounter.lockMode = true; lockHolder.Controls.Add(ActiveCounter.control); } LockPanel.BringToFront(); txtLockPass.Focus(); }
private void txtLockPass_TextChanged(object sender, EventArgs e) { String hash = getHash(txtLockPass.Text); if (Properties.Settings.Default.isDefaultPass == true) { if (hash == getHash("unlock")) { txtLockPass.Text = ""; LockPanel.SendToBack(); unLockControl(); } } else { if (hash == Properties.Settings.Default.pass) { txtLockPass.Text = ""; LockPanel.SendToBack(); unLockControl(); } } }