]> git.saurik.com Git - wxWidgets.git/blobdiff - src/msw/combobox.cpp
make the string properly 0 terminated and allow for one char more on the output buffer
[wxWidgets.git] / src / msw / combobox.cpp
index 8b1841fb2e2075c273a4e6c5955744ed79ff0a8f..512a567e990147283688590328b72afdd22cb3a5 100644 (file)
@@ -199,7 +199,7 @@ LRESULT APIENTRY _EXPORT wxComboEditWndProc(HWND hWnd,
             {
                 wxCHECK_MSG( win, 0, _T("should have a parent") );
 
-                if ( win->GetWindowStyle() & wxPROCESS_ENTER )
+                if ( win->GetWindowStyle() & wxTE_PROCESS_ENTER )
                 {
                     // need to return a custom dlg code or we'll never get it
                     return DLGC_WANTMESSAGE;
@@ -332,7 +332,7 @@ bool wxComboBox::MSWCommand(WXUINT param, WXWORD id)
             // set these variables so that they could be also fixed in
             // CBN_EDITCHANGE below
             sel = GetSelection();
-            value = GetValue();
+            value = GetStringSelection();
             {
                 wxCommandEvent event(wxEVT_COMMAND_COMBOBOX_SELECTED, GetId());
                 event.SetEventObject(this);