]> git.saurik.com Git - wxWidgets.git/commitdiff
fixed bug #976725: "RETURN closes dialog instead of combobox dropdown" (applied fix...
authorDimitri Schoolwerth <dimitri.schoolwerth@gmail.com>
Wed, 23 Jun 2004 22:12:30 +0000 (22:12 +0000)
committerDimitri Schoolwerth <dimitri.schoolwerth@gmail.com>
Wed, 23 Jun 2004 22:12:30 +0000 (22:12 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@27985 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/msw/choice.cpp

index af029bf042dbdf1cc587f20673fa933ce80f810d..6abcdaef9aa6822dfe8841f77ea869411f884a8f 100644 (file)
@@ -179,8 +179,9 @@ bool wxChoice::MSWShouldPreProcessMessage(WXMSG *pMsg)
 {
     MSG *msg = (MSG *) pMsg;
 
-    // don't preprocess "ESC" if combobox is dropped down
-    if ( msg->message == WM_KEYDOWN && msg->wParam == VK_ESCAPE )
+    // if the dropdown list is visible, don't preprocess certain keys
+    if ( msg->message == WM_KEYDOWN
+        && (msg->wParam == VK_ESCAPE || msg->wParam == VK_RETURN) )
     {
         if (::SendMessage(GetHwndOf(this), CB_GETDROPPEDSTATE, 0, 0))
         {