Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't reset selection on mouse clicks, but only on mouse drags #2530

Open
mc-butler opened this issue Apr 4, 2011 · 10 comments
Open

Don't reset selection on mouse clicks, but only on mouse drags #2530

mc-butler opened this issue Apr 4, 2011 · 10 comments
Labels
area: core Issues not related to a specific subsystem prio: medium Has the potential to affect progress ver: 4.7.5 Reproducible in version 4.7.5

Comments

@mc-butler
Copy link

Important

This issue was migrated from Trac:

Origin https://midnight-commander.org/ticket/2530
Reporter vitalif (vitalif@….ru)
Mentions gotar@….pl

By now, mc resets selection on every mouse click. That's very inconvenient as selecting with mouse is usually needed when the you don't want to navigate far away with key presses, and you'll probably not want to navigate back with keys again. But you can't navigate back with mouse as it will reset the selection you've just made.

I think mc must reset selection only if the user starts new one, i.e. drags the mouse. See attached patch please :)


BTW, there was a change in Ctrl-Ins behaviour somewhere between 4.7 and 4.8 - in 4.7 Ctrl-Ins resetted the selection, but now it doesn't. I think it was more convenient when it resetted the selection. Are there any principal arguments? Maybe the behaviour could be restored to original, or selected with an option?

Note

Original attachments:

@mc-butler
Copy link
Author

Changed by vitalif (vitalif@….ru) on Apr 4, 2011 at 22:07 UTC

Reset selection only on GPM_DRAG

@mc-butler
Copy link
Author

Changed by andrew_b (@aborodin) on Apr 5, 2011 at 4:56 UTC

Replying to vitalif (#2530):

mc resets selection on every mouse click.

And what other editors don't do that?

@mc-butler
Copy link
Author

Changed by vitalif (vitalif@….ru) on Apr 5, 2011 at 11:09 UTC (comment 2)

Hmm... :) this is an argument.

The patch is probably only useful when you use F3 F5 etc... select copy move commands and not clipboard. And yes, I'm really using it :)) But, I think the patch does not add any inconvenience?

@mc-butler
Copy link
Author

Changed by victor-homyakov (vkhomyackov@….com) on Apr 28, 2011 at 12:20 UTC (comment 3)

Other text editors (FAR editor, for example) have explicit option ("Persistent blocks"). Persistent block isn't deselected on cursor keys and mouse clicks, while not persistent block is deselected. This behavior is internally consistent.
MC editor keeps selection on cursor keys, but clears selection on mouse clicks - this is inconsistent, I think.

@mc-butler
Copy link
Author

Changed by angel_il (@ilia-maslakov) on Jul 18, 2011 at 7:42 UTC (comment 4)

  • Status changed from new to closed
  • Branch state set to no branch
  • Resolution set to wontfix

@mc-butler
Copy link
Author

Changed by gotar (gotar@….pl) on Sep 14, 2011 at 22:28 UTC (comment 5)

  • Cc set to gotar@….pl

@mc-butler
Copy link
Author

Changed by vitalif (vitalif@….ru) on Feb 17, 2012 at 12:54 UTC (comment 6)

  • Status changed from closed to reopened
  • Resolution wontfix deleted

Why wontfix?

@mc-butler
Copy link
Author

Changed by vitalif (vitalif@….ru) on Feb 17, 2012 at 12:54 UTC

Reset selection after copying it to the clipboard patch

@mc-butler
Copy link
Author

Changed by sknaumov (sknaumov@….com) on Apr 5, 2013 at 15:33 UTC (comment 7)

I've come up to the same patch (reset-after-store) for 4.8.7 and 4.8.8 (what a pity I haven't seen this ticket before). I can confirm that this patch works as it should and I patched my mc about 6 mounths ago without any issues. But this patch drops selection after Ctrl+Ins even if editor_persistent_selections=1. I don't know whether it is a desired behavior - I always use editor_persistent_selections=0.

@mc-butler
Copy link
Author

Changed by andrew_b (@aborodin) on Jun 18, 2015 at 18:35 UTC (comment 8)

  • Milestone changed from 4.8 to Future Releases

@mc-butler mc-butler reopened this Feb 27, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: core Issues not related to a specific subsystem prio: medium Has the potential to affect progress ver: 4.7.5 Reproducible in version 4.7.5
Development

No branches or pull requests

1 participant