From d3e7833a909f32ffe55e8ab1e872822905562f38 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Thu, 19 Nov 2015 00:25:26 +0100 Subject: [PATCH] No changes, just replace a useless comment with a more helpful one Don't describe in English what the next line of code does, which is useless, but rather explain why do we do this. --- src/msw/textctrl.cpp | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/msw/textctrl.cpp b/src/msw/textctrl.cpp index 4359c26d0a..64bda4e190 100644 --- a/src/msw/textctrl.cpp +++ b/src/msw/textctrl.cpp @@ -2113,9 +2113,15 @@ wxTextCtrl::MSWHandleMessage(WXLRESULT *rc, // live with it. *rc = lDlgCode; } - if (IsMultiLine()) - // Clear the DLGC_HASSETSEL bit from the return value + + if ( IsMultiLine() ) + { + // The presence of this style, coming from the default EDIT + // WndProc, indicates that the control contents should be + // selected when it gets focus, but we don't want this to + // happen for the multiline controls, so clear it. *rc &= ~DLGC_HASSETSEL; + } } break;