From 0755366cb15674da50162cf37848d94773fd36ac Mon Sep 17 00:00:00 2001 From: Maxime Coste Date: Sun, 23 Aug 2015 15:18:18 +0100 Subject: Rework resize handling Fixes #383 --- src/input_handler.cc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/input_handler.cc') diff --git a/src/input_handler.cc b/src/input_handler.cc index 8ef17af9..4fd118b2 100644 --- a/src/input_handler.cc +++ b/src/input_handler.cc @@ -78,7 +78,7 @@ struct MouseHandler { case Key::Modifiers::MousePress: m_dragging = true; - m_anchor = context.window().buffer_coord(key.mouse_coord()); + m_anchor = context.window().buffer_coord(key.coord()); context.selections_write_only() = SelectionList{ buffer, m_anchor }; return true; @@ -86,7 +86,7 @@ struct MouseHandler if (not m_dragging) return true; m_dragging = false; - cursor = context.window().buffer_coord(key.mouse_coord()); + cursor = context.window().buffer_coord(key.coord()); context.selections_write_only() = SelectionList{ buffer, Selection{buffer.clamp(m_anchor), cursor} }; return true; @@ -94,7 +94,7 @@ struct MouseHandler case Key::Modifiers::MousePos: if (not m_dragging) return true; - cursor = context.window().buffer_coord(key.mouse_coord()); + cursor = context.window().buffer_coord(key.coord()); context.selections_write_only() = SelectionList{ buffer, Selection{buffer.clamp(m_anchor), cursor} }; return true; -- cgit v1.2.3