diff options
author | nyamatongwe <devnull@localhost> | 2011-08-10 19:53:34 +1000 |
---|---|---|
committer | nyamatongwe <devnull@localhost> | 2011-08-10 19:53:34 +1000 |
commit | c5e6a869158ea5357780e809f36fa555783e9a45 (patch) | |
tree | 993f9f7aef8be7da651b38ba1fff39a08f0d6bd9 /src | |
parent | fa13e9dbdbaf92a5e68e3669ed71cc830c759aa0 (diff) | |
download | scintilla-mirror-c5e6a869158ea5357780e809f36fa555783e9a45.tar.gz |
Fix for wrong cursor near selection ends when scrolled horizontally. Bug #3389055.
Diffstat (limited to 'src')
-rw-r--r-- | src/Editor.cxx | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/Editor.cxx b/src/Editor.cxx index 452666be7..f6b1ea308 100644 --- a/src/Editor.cxx +++ b/src/Editor.cxx @@ -6020,20 +6020,20 @@ bool Editor::PositionInSelection(int pos) { bool Editor::PointInSelection(Point pt) { SelectionPosition pos = SPositionFromLocation(pt, false, true); - int xPos = XFromPosition(pos); + Point ptPos = LocationFromPosition(pos); for (size_t r=0; r<sel.Count(); r++) { SelectionRange range = sel.Range(r); if (range.Contains(pos)) { bool hit = true; if (pos == range.Start()) { // see if just before selection - if (pt.x < xPos) { + if (pt.x < ptPos.x) { hit = false; } } if (pos == range.End()) { // see if just after selection - if (pt.x > xPos) { + if (pt.x > ptPos.x) { hit = false; } } |