summaryrefslogtreecommitdiffstats
path: root/pkg/gui/controllers
diff options
context:
space:
mode:
authorStefan Haller <stefan@haller-berlin.de>2024-01-19 13:27:55 +0100
committerStefan Haller <stefan@haller-berlin.de>2024-01-24 08:22:55 +0100
commite72c759541cb93e11940a32c18660f1358afa47a (patch)
tree58989a61a94ce6d1bf712d428b52c0a25eac3de8 /pkg/gui/controllers
parent9cd69e46df8fda7ba7208e1cfa54b8f1f0c6824b (diff)
Make range selections created with the mouse non-sticky
I prefer this because I almost never use sticky range selections. Also, this fixes the issue that just clicking a line in a diff (without dragging) already creates a range selection. It still does, technically, but it's no longer a problem because a non-sticky one-line range selection behaves the same as a non-range selection.
Diffstat (limited to 'pkg/gui/controllers')
-rw-r--r--pkg/gui/controllers/patch_explorer_controller.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/pkg/gui/controllers/patch_explorer_controller.go b/pkg/gui/controllers/patch_explorer_controller.go
index caac1f51c..957705bd1 100644
--- a/pkg/gui/controllers/patch_explorer_controller.go
+++ b/pkg/gui/controllers/patch_explorer_controller.go
@@ -274,7 +274,7 @@ func (self *PatchExplorerController) HandleMouseDown() error {
}
func (self *PatchExplorerController) HandleMouseDrag() error {
- self.context.GetState().SelectLine(self.context.GetViewTrait().SelectedLineIdx())
+ self.context.GetState().DragSelectLine(self.context.GetViewTrait().SelectedLineIdx())
return nil
}