-/*
- switch (nMsg)
- {
- case WM_GETDLGCODE:
- {
- if (GetWindowStyleFlag() & wxPROCESS_ENTER)
- return DLGC_WANTALLKEYS;
- break;
- }
- case WM_CHAR: // Always an ASCII character
- {
- if (wParam == VK_RETURN)
- {
- wxCommandEvent event(wxEVENT_TYPE_TEXT_ENTER_COMMAND);
- event.commandString = ((wxTextCtrl *)item)->GetValue();
- event.eventObject = item;
- item->ProcessCommand(event);
- return FALSE;
- }
- break;
- }
- default:
- break;
- }
-*/
+ long lRc = DLGC_WANTCHARS | DLGC_WANTARROWS;
+ if ( m_windowStyle & wxPROCESS_ENTER )
+ lRc |= DLGC_WANTMESSAGE;
+ else if ( m_windowStyle & wxTE_MULTILINE )
+ lRc |= DLGC_WANTMESSAGE;