Only associate shortcut keys with menu items (to prevent conflicts)

This commit is contained in:
Michael Becker 2014-07-18 15:20:52 -04:00
parent 6722c9c7e0
commit f6bdb168a4

View File

@ -140,7 +140,6 @@ namespace UniversalEditor.UserInterface.WindowsForms
else
{
ToolStripMenuItem tsmi = new ToolStripMenuItem();
tsmi.ShortcutKeys = ShortcutKeyToWinFormsKeys(cmd.ShortcutKey);
tsi = tsmi;
}
@ -168,7 +167,6 @@ namespace UniversalEditor.UserInterface.WindowsForms
else
{
tsi = new ToolStripMenuItem();
(tsi as ToolStripMenuItem).ShortcutKeys = ShortcutKeyToWinFormsKeys(cmd.ShortcutKey);
}
tsi.Tag = cmd;
tsi.Text = cmd.Title.Replace("_", "&");
@ -253,6 +251,7 @@ namespace UniversalEditor.UserInterface.WindowsForms
tsmi.Click += tsmiCommand_Click;
tsmi.Tag = cmd;
tsmi.Text = cmd.Title.Replace("_", "&");
tsmi.ShortcutKeys = ShortcutKeyToWinFormsKeys(cmd.ShortcutKey);
foreach (CommandItem item1 in cmd.Items)
{
LoadCommandBarMenuItem(item1, tsmi);