Closed
Bug 483914
Opened 17 years ago
Closed 16 years ago
middle-mouse paste fails if the input value is cleared on focus
Categories
(Core :: DOM: Editor, defect)
Core
DOM: Editor
Tracking
()
RESOLVED
WORKSFORME
People
(Reporter: karlt, Assigned: khuey)
References
(
URL
)
Details
(Keywords: polish, testcase, Whiteboard: [polish-hard][polish-interactive][polish-p4])
STR:
1. Open a new window and, if necessary, erase any contents of the location bar.
2. Put some text into the X selection. (e.g. select some text somewhere.)
3. Click on the search bar to move focus away from the location bar.
"Search Bookmarks and History" is shown in the location bar.
4. Try to paste into the location bar.
5. If paste was successful then delete the pasted text and repeat from 3,
leaving a couple of seconds before 4.
6. If paste was not successful then repeat 3 and 4 quickly until paste succeeds.
Expected results after 4:
Location bar receives focus and displays pasted text. This is what happens with most text input boxes and is what happened with the location bar in Firefox 3.0.
Actual results:
Location bar only receives focus.
This is a regression for the location bar, but Firefox 3 had the same bug with the search bar, which makes me suspect something to do with the "Search Bookmarks and History" text and perhaps the order of processing events to remove this text.
| Reporter | ||
Updated•17 years ago
|
Summary: Pasting text selection from mouse usually fails when location bar doesn't have focus → Pasting text selection from mouse into location bar without focus usually fails
Comment 1•17 years ago
|
||
Looks like pasting the selection over the emptyText ("Search Bookmarks and History", "Google" etc.) fails. This also affects other input fields that use emptyText, like searching add-ons and downloads.
Comment 2•17 years ago
|
||
Dao could know something about this, he worked recently on emptytext iirc
Comment 3•17 years ago
|
||
t and
Component: Location Bar and Autocomplete → XUL Widgets
Keywords: regression
Product: Firefox → Toolkit
QA Contact: location.bar → xul.widgets
Comment 4•17 years ago
|
||
(In reply to comment #3)
> t and
Interesting. I guess I pasted something accidentally...
Whiteboard: [polish-hard][polish-interactive]
Comment 5•17 years ago
|
||
Testcase:
data:text/html,<input onfocus="this.value=''" value="xxxxxxxxxx">
If you paste with the mouse over the text, it fails. It works if you paste with the mouse after the text, over the empty area.
URL: data:text/html,<input onfocus="this.v...
Component: XUL Widgets → Editor
Product: Toolkit → Core
QA Contact: xul.widgets → editor
Comment 6•17 years ago
|
||
Also happens on Windows with middlemouse.paste set to true.
Keywords: testcase
OS: Linux → All
Hardware: x86 → All
Summary: Pasting text selection from mouse into location bar without focus usually fails → middle-mouse paste fails if the input value is cleared on focus
Comment 7•17 years ago
|
||
This bug's priority relative to the set of other polish bugs is:
P4 - Polish issue that is rarely encountered, and is easily identifiable.
Easy to notice when it happens, but sounds like it is rare and the only effected user segment is people who actively use the X selection.
Whiteboard: [polish-hard][polish-interactive] → [polish-hard][polish-interactive][polish-p4]
| Assignee | ||
Comment 8•16 years ago
|
||
I was doing some debugging on this. Didn't learn too much but I don't think the problem is in libeditor. When the paste fails the middlemouse event never gets close to nsTextEditorMouseListener::MouseClick. I'm going to keep messing with it in my spare time and see if I can get anywhere.
Comment 9•16 years ago
|
||
This seems to WFM now in a current Linux trunk build, though I don't know why.
Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.3a2pre) Gecko/20100227 Minefield/3.7a2pre ID:20100227031019
| Reporter | ||
Comment 10•16 years ago
|
||
Yes, WFM with 11c913d25658. Thanks!
Status: NEW → RESOLVED
Closed: 16 years ago
Resolution: --- → WORKSFORME
| Assignee | ||
Comment 11•16 years ago
|
||
This would probably be worth writing unit tests for to make sure it doesn't magically stop working. Assigning to myself but feel free to steal if you have time.
Assignee: nobody → me
Flags: in-testsuite?
You need to log in
before you can comment on or make changes to this bug.
Description
•