2008-03-06 Jonathan Pobst <monkey@jpobst.com>
authorJonathan Pobst <monkey@jpobst.com>
Thu, 6 Mar 2008 21:19:32 +0000 (21:19 -0000)
committerJonathan Pobst <monkey@jpobst.com>
Thu, 6 Mar 2008 21:19:32 +0000 (21:19 -0000)
* ToolStrip.cs: Enable implicit mnemonics for drop down
menu strips.  [Fixes part of bug #367692]

svn path=/trunk/mcs/; revision=97631

mcs/class/Managed.Windows.Forms/System.Windows.Forms/ChangeLog
mcs/class/Managed.Windows.Forms/System.Windows.Forms/ToolStrip.cs

index a4d8389483c7a5805058da6a0af17895bfe6bd58..c0d7d0da5132fbabf9f2568ac02d9616e1e3d5da 100644 (file)
@@ -1,3 +1,8 @@
+2008-03-06  Jonathan Pobst  <monkey@jpobst.com>
+
+       * ToolStrip.cs: Enable implicit mnemonics for drop down
+       menu strips.  [Fixes part of bug #367692]
+
 2008-03-06  Jonathan Pobst  <monkey@jpobst.com>
 
        corcompare - fix parameter names [stragglers].
index f591cfd9c5997559e2cced60c53c78e2a97cfe5d..6f0fa20f54ea579c77afd67246e322509f312b3e 100644 (file)
@@ -1125,7 +1125,7 @@ namespace System.Windows.Forms
                        string code = Char.ToUpper (charCode).ToString ();
                        
                        // If any item's text starts with our letter, it gets the message
-                       if (this is MenuStrip)
+                       if (this is MenuStrip || this is ToolStripDropDownMenu)
                                foreach (ToolStripItem tsi in this.Items)
                                        if (tsi.Enabled && tsi.Visible && !string.IsNullOrEmpty (tsi.Text) && tsi.Text.ToUpper ().StartsWith (code))
                                                return tsi.ProcessMnemonic (charCode);