summaryrefslogtreecommitdiff
path: root/src/selection.cc
diff options
context:
space:
mode:
authorMaxime Coste <mawww@kakoune.org>2017-08-18 08:49:37 +0700
committerMaxime Coste <mawww@kakoune.org>2017-08-18 08:49:37 +0700
commit609a8ee8c793856b8c1e6b7c553ee3475ca8308f (patch)
tree53f6af2681235b4bb56e72d8387be6361d5d9a43 /src/selection.cc
parent1688332d1205c57b5d18b930819f52a9c04e4c04 (diff)
Change selection extension code to be simpler
Selection extension now just keeps the anchor in place insead of trying to be smart depending on the direction of selections.
Diffstat (limited to 'src/selection.cc')
-rw-r--r--src/selection.cc4
1 files changed, 0 insertions, 4 deletions
diff --git a/src/selection.cc b/src/selection.cc
index a2c53b59..43f47090 100644
--- a/src/selection.cc
+++ b/src/selection.cc
@@ -10,10 +10,6 @@ namespace Kakoune
void Selection::merge_with(const Selection& other)
{
m_cursor = other.m_cursor;
- if (m_anchor < m_cursor)
- m_anchor = std::min(m_anchor, other.m_anchor);
- if (m_anchor > m_cursor)
- m_anchor = std::max(m_anchor, other.m_anchor);
}
SelectionList::SelectionList(Buffer& buffer, Selection s, size_t timestamp)