Suppress the context menu if right click has a binding

This commit is contained in:
CasualPokePlayer 2024-08-31 19:06:40 -07:00
parent e22082c6b4
commit 133ff5a77e
1 changed files with 8 additions and 0 deletions

View File

@ -453,6 +453,14 @@ namespace BizHawk.Client.EmuHawk
AutohideCursor(false);
if (Config.ShowContextMenu && e.Button == MouseButtons.Right)
{
// suppress the context menu if right click has a binding
// (unless shift is being pressed, similar to double click fullscreening)
var allowSuppress = ModifierKeys != Keys.Shift;
if (allowSuppress && InputManager.ActiveController.HasBinding("WMouse R"))
{
return;
}
MainFormContextMenu.Show(PointToScreen(new Point(e.X, e.Y + MainformMenu.Height)));
}
}