Paste on middle click (X primary selection) doesn't work in the JavaScript console
Categories
(DevTools :: Console, defect, P3)
Tracking
(Not tracked)
People
(Reporter: martin, Unassigned)
References
Details
User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:70.0) Gecko/20100101 Firefox/70.0
Steps to reproduce:
Middle-click in the web console on a Linux/Xorg system.
Actual results:
The cursor briefly flashes, but other than that nothing happens: no text is inserted.
Expected results:
Expected the contents of the X primary selection to be inserted.
Using Control+V (X clipboard) does work, but I prefer using the primary selection for many tasks.
Note: it does work in some other places, like pasting in the DOM inspector CSS rules, Storage Editor, and "Filter output" in the console.
It doesn't work in some other places, too like the style editor and scratchpad (scratchpad was fixed 8 years ago in https://bugzilla.mozilla.org/show_bug.cgi?id=695035, but seems to have been broken again?)
Related: https://bugzilla.mozilla.org/show_bug.cgi?id=1200448
| Reporter | ||
Comment 1•6 years ago
|
||
Forgot to mention: this is a long-standing issue and not a recent regression (I was surprised I couldn't find an existing bug report for it; I had always assumed it was a known problem? Hopefully I didn't miss an existing bug report)
Comment 2•6 years ago
|
||
All the places you mention use our "Source Editor" shared component, which is based on top of CodeMirror.
I thought we implemented a fix last year, and we even have a test for that ([1] ), but maybe it is flawed?
Or is this bug only about the primary selection "paste" and doing a selection, then Ctrl+C, then middle-click is working fine?
There's Bug 1593761 to deal with the other way around (get the primary selection from the editor), so maybe we can tackle both at the same time.
| Reporter | ||
Comment 3•6 years ago
|
||
Thank you Nicolas
Or is this bug only about the primary selection "paste" and doing a selection, then Ctrl+C, then middle-click is working fine?
I'm having trouble parsing this sentence 😅, but:
- Paste with control+v after selecting text and pressing control+c always works fine.
- Paste with middle-click after just selecting text (in any application) never works.
I hope this answers your question?
Comment 4•6 years ago
|
||
sorry I was unclear. If you do:
- select text
- press Ctrl+C
- middle-click on the console
Does it paste the copied text to the console?
| Reporter | ||
Comment 5•6 years ago
|
||
No, it doesn't; as far as I can tell middle-click never does anything.
Comment 6•6 years ago
|
||
(In reply to Martin Tournoij from comment #5)
No, it doesn't; as far as I can tell middle-click never does anything.
Okay, thanks for all the info. I'll try to work on that soon.
Updated•6 years ago
|
I can’t reproduce with Firefox 68, Debian GNU/Linux, LXQT:
in web console (Ctrl+Shift+K), I can well use middle-click to paste selected text.
| Reporter | ||
Comment 8•6 years ago
|
||
I downloaded Firefox 68, and it does seem to work there for me too. It's still broken in Firefox 72 though.
| Reporter | ||
Comment 9•5 years ago
|
||
This problem seems fixed in Firefox 73 (I haven't really changed anything on my system, so I assume it was fixed in Firefox?)
| Reporter | ||
Updated•5 years ago
|
Description
•