dragging text from another tab to the "Search Sites" box in about:permissions doesn't trigger it to search

RESOLVED WORKSFORME

Status

()

RESOLVED WORKSFORME
7 years ago
5 years ago

People

(Reporter: mardeg, Unassigned)

Tracking

Trunk
x86
Windows XP
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: [testday-20110603], URL)

(Reporter)

Description

7 years ago
Typing or pasting text into the about:permissions "Search Sites" box triggers it to autosearch on each keypress. This does not happen when text is dragged from another tab (such as a domain in the addressbar or in page content) and dropped into that box. User has to press enter or edit the dropped text to trigger a search. This seems to create an inconsistent UX.
(Reporter)

Comment 1

7 years ago
STR:
1. Have an existing first tab open to any site
2. Open about:permissions in a new tab
3. Switch to the first tab and select any text on the page or in address bar
4. Drag that selection to the about:permissions tab
5. Drop selection into the "Search Sites" box

Expected results:
A search is performed of the dropped text

Actual results:
No search is performed
Isn't that an issue in about:permissions, not in d&d?  It's using oncommand, not the oninput I would have expected it to use if it wanted to react to all input.
Component: Drag and Drop → Preferences
Product: Core → Firefox
QA Contact: drag-drop → preferences

Comment 3

7 years ago
I just tested with oninput instead of oncommand, and that does not change the behavior.
Interesting...  Mounir?
(In reply to comment #3)
> I just tested with oninput instead of oncommand, and that does not change
> the behavior.

Also, we don't want oninput. It's a search textbox with delayed command triggering. The xbl binding already listens to the input event for you.
(In reply to comment #4)
> Interesting...  Mounir?

The input event is caught by the search-textbox binding. With a <html:input> it works perfectly.
(In reply to comment #6)
> The input event is caught by the search-textbox binding.

What does this mean?
It means that on drop we fire an input event on the <input>.  The search-textbox binding then does:


404       <handler event="input">
405         <![CDATA[
406           if (this.searchButton) {
407             this._searchIcons.selectedIndex = 0;
408             return;
409           }
410           if (this._timer)
411             clearTimeout(this._timer);
412           this._timer = this.timeout && setTimeout(this._fireCommand, this.timeout, this);
413           this._searchIcons.selectedIndex = this.value ? 1 : 0;
414         ]]>
415       </handler>

Which sure looks like it should call _fireCommand.  Is that not happening?
Nope, not happening. The event listener doesn't run.
Just tried with Firefox 22, dropping a text from gedit to the about:permissions page and it seems to be working. Please reopen if the steps were wrong.
Status: NEW → RESOLVED
Last Resolved: 5 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.