-
Notifications
You must be signed in to change notification settings - Fork 8.3k
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
Fix click-drag selection on an unfocused Terminal #4506
Conversation
Oh no! It looks like the line endings on TerminalControl.cpp got damaged, and github thinks the entire file has changed./ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I love this. Do you have an idea how it'll interact with double-click selection? Can you double-click a word in an unfocused terminal and begin a chunked word selection?
It won't chunk select if you perform a multi-click. It's because the way it's written now is that unless your first click is part of a click-drag selection, it will always only focus. So, even if you did a double click, the first click is a focus click, and the second click would be a single-character selection click. I was actually considering whether to also let double click, triple click, and shift-click successfully select from out of focus, but for now I figured it might be simpler to only let the click-drag scenario through. |
@carlos-zamora did you have any further concerns on this? |
nit: before you merge this (by using the AutoMerge tag), please update the title to..
Pretend the title is the end of the sentence "If merged, this pull request will..." |
(If you use the automerge tag, the bot will take the title and body of the PR as the commit title/body) |
Hello @leonMSFT! Because this pull request has the p.s. you can customize the way I help with merging this pull request, such as holding this pull request until a specific person approves. Simply @mention me (
|
🎉 Handy links: |
Summary of the Pull Request
This PR tries to address some of the weird interactions with pointer pressed events when the Terminal isn't in focus. Here's the four things that have changed as part of this PR;
I've made sure that we still have the existing functionality where a single click on an unfocused tab/pane does not make a single-cell selection and just focuses the tab/pane.
PR Checklist
Validation Steps Performed
Played around with all sorts of selection when in-focus and out of focus with multiple panes and tabs.
Unit tests still pass as well.