protected override bool ProcessCmdKey(ref Message msg, Keys keyData) { if (_editor.FlyMode && !_editor.Configuration.UI_Hotkeys["ToggleFlyMode"].Contains(keyData)) { return(base.ProcessCmdKey(ref msg, keyData)); } // Don't process reserved camera keys if (Hotkey.ReservedCameraKeys.Contains(keyData)) { return(base.ProcessCmdKey(ref msg, keyData)); } // Don't process one-key and shift hotkeys if we're focused on control which allows text input if (WinFormsUtils.CurrentControlSupportsInput(this, keyData)) { return(base.ProcessCmdKey(ref msg, keyData)); } CommandHandler.ExecuteHotkey(new CommandArgs { Editor = _editor, KeyData = keyData, Window = this }); // Don't open menus with the alt key if (keyData.HasFlag(Keys.Alt)) { return(true); } return(base.ProcessCmdKey(ref msg, keyData)); }