X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/ef0368834fd9f80de27e1449cfdb767d59410a65..c57c2993ecaa4acf32585f18e0185ea00bb34981:/src/msw/choice.cpp?ds=sidebyside diff --git a/src/msw/choice.cpp b/src/msw/choice.cpp index 9e9cde38ca..6abcdaef9a 100644 --- a/src/msw/choice.cpp +++ b/src/msw/choice.cpp @@ -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)) { @@ -503,6 +504,8 @@ void wxChoice::DoSetSize(int x, int y, SendMessage(GetHwnd(), CB_SETITEMHEIGHT, (WPARAM)-1, h + delta); } } +#else + wxUnusedVar(heightOrig); #endif }