diff options
| author | Maxime Coste <mawww@kakoune.org> | 2017-03-15 16:51:55 +0000 |
|---|---|---|
| committer | Maxime Coste <mawww@kakoune.org> | 2017-03-15 16:51:55 +0000 |
| commit | a88e58763bd33e021511d2e821703f478afd85bf (patch) | |
| tree | 7c4ddd9006bd8fd51bcb17edb209d44571ebd694 /src/selection.cc | |
| parent | 5705b6c6f938589d3a63a3e632bc93266c78ec17 (diff) | |
Move SelectionList::set implementation out of the header
Diffstat (limited to 'src/selection.cc')
| -rw-r--r-- | src/selection.cc | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/selection.cc b/src/selection.cc index 7424067b..542c44f5 100644 --- a/src/selection.cc +++ b/src/selection.cc @@ -42,6 +42,16 @@ void SelectionList::remove(size_t index) if (index < m_main or m_main == m_selections.size()) --m_main; } +void SelectionList::set(Vector<Selection> list, size_t main) +{ + kak_assert(main < list.size()); + m_selections = std::move(list); + m_main = main; + sort_and_merge_overlapping(); + update_timestamp(); + check_invariant(); +} + namespace { |
