private void textBoxHotKey_LeaveFocus(object sender, EventArgs e) { if (hkRecorder != null) { hkRecorder.Stop(); if (hkServer == null) { return; } foreach (Server s in Server_farm.server_list.Values) { if (!s.Name.Equals(txtName.Text)) { if (s.HotKey.HasSameKeysSequence(hkServer)) { txtHotKey.ForeColor = System.Drawing.Color.Red; } } } } }
private void button2_Click(object sender, EventArgs e) { hkRecorder.Stop(); }