示例#1
0
 protected override void WndProc(ref Message m)
 {
     if (groupBox1 != null && groupBox1.Enabled)
     {
         if (m.Msg == GlobalHotkey.Constants.WM_HOTKEY_MSG_ID)
         {
             if (m.WParam.ToInt32() == hotkey_restart.GetHashCode())
             {
                 changeRoom(0);
             }
             else if (m.WParam.ToInt32() == hotkey_lastRoom.GetHashCode())
             {
                 changeRoom(-1);
             }
             else if (m.WParam.ToInt32() == hotkey_nextRoom.GetHashCode())
             {
                 changeRoom(1);
             }
             else if (m.WParam.ToInt32() == hotkey_setRoom.GetHashCode())
             {
                 setToTextbox();
             }
         }
     }
     base.WndProc(ref m);
 }