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

[Execute SQL tab] Double-clicking a previous command deselects the selection #195

Open
chrisjlocke opened this issue Apr 30, 2023 · 9 comments

Comments

@chrisjlocke
Copy link
Member

chrisjlocke commented Apr 30, 2023

image

Double-clicking 'select' to select the previous command doesn't work as expected - it sometimes cancels the selection. Triple-clicking does work, or double-clicking 'sqlite_version'. It does seem slightly intermittent .. Justin also experienced this on his system (so wasn't just me going nuts...)

@MKleusberg
Copy link
Member

Pretty sure the issue here is mouse movement. If you double click but the mouse moves ever so slightly between the two clicks it's counted as a single click and for single clicks there's a handler which focuses the input area. I won't have the time to fix this the next couple of days but I think adding some tolerance for mouse movement shouldn't be too hard but should solve the issue 😄

@chrisjlocke
Copy link
Member Author

Its a minor thing as single-clicking and dragging works just fine. :)

@chrisjlocke
Copy link
Member Author

chrisjlocke commented Apr 30, 2023

Ooh, quick brain fart. If you click the 'sql >' prompt, it could select the whole line in one click.
Triple-clicking selects the whole line, including the 'sql >' prompt. Maybe when pasting this could be filtered out.

@MKleusberg
Copy link
Member

Ooh, quick brain fart. If you click the 'sql >' prompt, it could select the whole line in one click.

Excellent idea! Will add that next weekend!

@justinclift
Copy link
Member

As a data point, the thing that's unselecting the double-clicked-on-term doesn't seem to be mouse movement based.

Saying that because if I hold the mouse super, super still (!) and double click (successfully, still only occasional)... I can then move the mouse all over the screen without the selection being lost.

So, it seems like something (JS?) is killing the selection, but not sure what. The "click on sql> prompt is a really good idea though. 😄

@MKleusberg
Copy link
Member

So, it seems like something (JS?) is killing the selection, but not sure what. The "click on sql> prompt is a really good idea though. smile

This bit should be responsible. I'll try to improve it soon. For the time being I'd just leave it because without it it feels very strange to use 😄

@justinclift
Copy link
Member

No worries at all. 😄

@chrisjlocke
Copy link
Member Author

The "click on sql> prompt is a really good idea though. smile

Just an 'enhancement' to this .. set the tooltip to prod the user that this feature is there. While its useful and I'll do 465327 blog posts advertising it, you just know people will never know its there...

@chrisjlocke
Copy link
Member Author

If the 'click >sql prompt' is do-able, would it also be possible to link this to the F2 key? F2 is commonly used to go into edit mode (at least in Windows), and seems a nice keyboard shortcut.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants