Bug 1104142 - Shift-tab doesn't go back to location bar if there is text in the search field, r=Gijs, ui-r=shorlander.

This commit is contained in:
Florian Quèze 2014-12-18 23:54:26 +01:00
parent 1833ab7d8d
commit d7bef18288

View File

@ -595,7 +595,6 @@
autocompletesearchparam="searchbar-history"
maxrows="10"
completeselectedindex="true"
tabscrolling="true"
xbl:inherits="disabled,disableautocomplete,searchengine,src,newlines">
<!--
Empty <box> to properly position the icon within the autocomplete
@ -1022,15 +1021,12 @@
}
}
else {
// If no selection, select the first or last one-off button.
if (aEvent.shiftKey) {
selectedButton = list.lastChild;
while (selectedButton.classList.contains("dummy"))
selectedButton = selectedButton.previousSibling;
}
else {
selectedButton = list.firstChild;
}
// If no selection, let the focus escape the panel for shift+<tab>
if (aEvent.shiftKey)
return;
// and select the first one-off button for <tab>.
selectedButton = list.firstChild;
}
selectedButton.setAttribute("selected", "true");