]> git.saurik.com Git - wxWidgets.git/blobdiff - src/msw/tooltip.cpp
Applied patch [ 583922 ] Make generic/wxListCtrl avail. in WIN32
[wxWidgets.git] / src / msw / tooltip.cpp
index 28bafa0c1603b74957d2651fbfa7db7d1f5f4863..930748cdbf1cf5b33ac47d6beaf93417fbf405fa 100644 (file)
@@ -382,9 +382,11 @@ void wxToolTip::SetWindow(wxWindow *win)
     //     something like this where the derived class can do such things
     //     itself instead of wxToolTip "knowing" about them all
     wxComboBox *combo = wxDynamicCast(control, wxComboBox);
-    if ( combo && !(combo->GetWindowStyle() & wxCB_READONLY))
+    if ( combo )
     {
-        WXHWND hwndComboEdit = combo->GetEditHWND();
+        WXHWND hwndComboEdit = combo->GetWindowStyle() & wxCB_READONLY
+                                ? combo->GetHWND()
+                                : combo->GetEditHWND();
         if ( hwndComboEdit )
         {
             Add(hwndComboEdit);