Fix for caret positioning bug when selecting content

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72074 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Julian Smart 2012-07-13 18:11:24 +00:00
parent f30b9eed38
commit 75e50f45c9

View File

@ -1992,7 +1992,7 @@ bool wxRichTextCtrl::MoveRight(int noPositions, int flags)
// we want to adjust the caret position such that it is positioned at the
// start of the next line, rather than jumping past the first character of the
// line.
if (noPositions == 1 && !extendSel)
if (noPositions == 1)
MoveCaretForward(oldPos);
else
SetCaretPosition(newPos);
@ -2019,7 +2019,7 @@ bool wxRichTextCtrl::MoveLeft(int noPositions, int flags)
if (!extendSel)
SelectNone();
if (noPositions == 1 && !extendSel)
if (noPositions == 1)
MoveCaretBack(oldPos);
else
SetCaretPosition(newPos);