]> git.saurik.com Git - wxWidgets.git/commitdiff
Better text control non-selection solution
authorJulian Smart <julian@anthemion.co.uk>
Wed, 17 Aug 2011 08:38:00 +0000 (08:38 +0000)
committerJulian Smart <julian@anthemion.co.uk>
Wed, 17 Aug 2011 08:38:00 +0000 (08:38 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68753 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/msw/textctrl.cpp
src/msw/window.cpp

index 850ea6ee9373dcb70428837b26f0064170bbea95..4e2171fbfe363054036f619dd1ce1bf6f349da0a 100644 (file)
@@ -1951,6 +1951,9 @@ WXLRESULT wxTextCtrl::MSWWindowProc(WXUINT nMsg, WXWPARAM wParam, WXLPARAM lPara
                     //     live with it.
                     lRc = lDlgCode;
                 }
+                if (IsMultiLine())
+                    // Clear the DLGC_HASSETSEL bit from the return value
+                    lRc &= ~DLGC_HASSETSEL;
             }
             break;
 
index 3bdd3249315977c6c563c2f2f0f8959a7229427e..5e2e43a438aeb3282ecd2e8adabfc551c7175815 100644 (file)
@@ -3100,13 +3100,6 @@ wxWindowMSW::MSWHandleMessage(WXLRESULT *result,
 
                 processed = true;
             }
-            else if (IsOfStandardClass() && IsKindOf(CLASSINFO(wxTextCtrl)) && ((wxTextCtrl*)this)->IsMultiLine())
-            {
-                rc.result = MSWDefWindowProc(message, wParam, lParam);
-                // Clear the DLGC_HASSETSEL bit from the return value
-                rc.result &= ~DLGC_HASSETSEL;
-                processed = true;
-            }
             //else: get the dlg code from the DefWindowProc()
             break;