зеркало из https://github.com/mozilla/gecko-dev.git
Fix opening the search dropdown with F4 or alt+up/down (bug 337720) Patch by pamg, r=gavin, sr/b181=me
This commit is contained in:
Родитель
96ecd2ccd7
Коммит
37d554b5c4
|
@ -2930,7 +2930,7 @@ const BrowserSearch = {
|
||||||
const targetDoc = target.ownerDocument;
|
const targetDoc = target.ownerDocument;
|
||||||
// Set the attribute of the (first) search button.
|
// Set the attribute of the (first) search button.
|
||||||
var searchButton = document.getAnonymousElementByAttribute(this.getSearchBar(),
|
var searchButton = document.getAnonymousElementByAttribute(this.getSearchBar(),
|
||||||
"anonid", "searchbar-dropmarker");
|
"anonid", "search-go-button");
|
||||||
if (searchButton) {
|
if (searchButton) {
|
||||||
var browser = gBrowser.getBrowserForDocument(targetDoc);
|
var browser = gBrowser.getBrowserForDocument(targetDoc);
|
||||||
// Append the URI and an appropriate title to the browser data.
|
// Append the URI and an appropriate title to the browser data.
|
||||||
|
@ -2960,7 +2960,7 @@ const BrowserSearch = {
|
||||||
*/
|
*/
|
||||||
updateSearchButton: function() {
|
updateSearchButton: function() {
|
||||||
var searchButton = document.getAnonymousElementByAttribute(this.getSearchBar(),
|
var searchButton = document.getAnonymousElementByAttribute(this.getSearchBar(),
|
||||||
"anonid", "searchbar-dropmarker");
|
"anonid", "search-go-button");
|
||||||
if (!searchButton)
|
if (!searchButton)
|
||||||
return;
|
return;
|
||||||
var engines = gBrowser.mCurrentBrowser.engines;
|
var engines = gBrowser.mCurrentBrowser.engines;
|
||||||
|
|
|
@ -47,15 +47,12 @@
|
||||||
xmlns:xul="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
|
xmlns:xul="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
|
||||||
xmlns:xbl="http://www.mozilla.org/xbl">
|
xmlns:xbl="http://www.mozilla.org/xbl">
|
||||||
|
|
||||||
<binding id="searchbar-base">
|
<binding id="searchbar">
|
||||||
<resources>
|
<resources>
|
||||||
<stylesheet src="chrome://browser/content/search/searchbarBindings.css"/>
|
<stylesheet src="chrome://browser/content/search/searchbarBindings.css"/>
|
||||||
<stylesheet src="chrome://browser/skin/searchbar.css"/>
|
<stylesheet src="chrome://browser/skin/searchbar.css"/>
|
||||||
</resources>
|
</resources>
|
||||||
</binding>
|
|
||||||
|
|
||||||
<binding id="searchbar"
|
|
||||||
extends="chrome://browser/content/search/search.xml#searchbar-base">
|
|
||||||
<content>
|
<content>
|
||||||
<xul:stringbundle src="chrome://browser/locale/search.properties"
|
<xul:stringbundle src="chrome://browser/locale/search.properties"
|
||||||
anonid="searchbar-stringbundle"/>
|
anonid="searchbar-stringbundle"/>
|
||||||
|
@ -83,11 +80,11 @@
|
||||||
# engine icons line up, but that's prevented by inconsistent behavior of the
|
# engine icons line up, but that's prevented by inconsistent behavior of the
|
||||||
# popup position within a toolbarbutton. See bug 336868.
|
# popup position within a toolbarbutton. See bug 336868.
|
||||||
<xul:toolbarbutton class="search-go-button"
|
<xul:toolbarbutton class="search-go-button"
|
||||||
|
anonid="search-go-button"
|
||||||
type="menu-button"
|
type="menu-button"
|
||||||
anonid="searchbar-dropmarker"
|
|
||||||
xbl:inherits="src">
|
xbl:inherits="src">
|
||||||
<xul:menupopup anonid="searchbar-popup"
|
<xul:menupopup class="searchbar-popup"
|
||||||
class="searchbar-popup"
|
anonid="searchbar-popup"
|
||||||
position="after_start">
|
position="after_start">
|
||||||
<xul:menuseparator/>
|
<xul:menuseparator/>
|
||||||
<xul:menuitem anonid="open-engine-manager"
|
<xul:menuitem anonid="open-engine-manager"
|
||||||
|
@ -520,8 +517,8 @@
|
||||||
<![CDATA[
|
<![CDATA[
|
||||||
// Don't open search popup if history popup is open
|
// Don't open search popup if history popup is open
|
||||||
if (!this.popupOpen) {
|
if (!this.popupOpen) {
|
||||||
document.getAnonymousElementByAttribute(this,
|
document.getAnonymousElementByAttribute(this._getParentSearchbar(),
|
||||||
"anonid", "searchbar-popup").click();
|
"anonid", "search-go-button").open = true;
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
|
@ -668,13 +665,4 @@
|
||||||
|
|
||||||
</handlers>
|
</handlers>
|
||||||
</binding>
|
</binding>
|
||||||
|
|
||||||
<binding id="searchbar-dropmarker"
|
|
||||||
extends="chrome://browser/content/search/search.xml#searchbar-base">
|
|
||||||
<content>
|
|
||||||
<xul:image class="searchbar-dropmarker-image"/>
|
|
||||||
<children/>
|
|
||||||
</content>
|
|
||||||
</binding>
|
|
||||||
|
|
||||||
</bindings>
|
</bindings>
|
||||||
|
|
|
@ -3,8 +3,3 @@
|
||||||
.searchbar-textbox {
|
.searchbar-textbox {
|
||||||
-moz-binding: url("chrome://browser/content/search/search.xml#searchbar-textbox");
|
-moz-binding: url("chrome://browser/content/search/search.xml#searchbar-textbox");
|
||||||
}
|
}
|
||||||
|
|
||||||
.searchbar-dropmarker {
|
|
||||||
-moz-binding: url("chrome://browser/content/search/search.xml#searchbar-dropmarker");
|
|
||||||
-moz-user-focus: none;
|
|
||||||
}
|
|
||||||
|
|
|
@ -26,10 +26,6 @@
|
||||||
list-style-image: url("chrome://browser/skin/Search-bar.png");
|
list-style-image: url("chrome://browser/skin/Search-bar.png");
|
||||||
}
|
}
|
||||||
|
|
||||||
.searchbar-dropmarker-image {
|
|
||||||
list-style-image: url("chrome://global/skin/arrow/arrow-dn.png");
|
|
||||||
}
|
|
||||||
|
|
||||||
.autocomplete-textbox-container {
|
.autocomplete-textbox-container {
|
||||||
border: none;
|
border: none;
|
||||||
padding-right: 0px;
|
padding-right: 0px;
|
||||||
|
|
|
@ -11,7 +11,6 @@ classic.jar:
|
||||||
skin/classic/browser/livemark-item.png
|
skin/classic/browser/livemark-item.png
|
||||||
skin/classic/browser/livemark-item-rtl.png
|
skin/classic/browser/livemark-item-rtl.png
|
||||||
skin/classic/browser/searchbar.css
|
skin/classic/browser/searchbar.css
|
||||||
skin/classic/browser/search-arrow.gif
|
|
||||||
skin/classic/browser/Search-bar.png
|
skin/classic/browser/Search-bar.png
|
||||||
skin/classic/browser/Search.png
|
skin/classic/browser/Search.png
|
||||||
skin/classic/browser/Search-add-engines.png
|
skin/classic/browser/Search-add-engines.png
|
||||||
|
|
Двоичные данные
browser/themes/winstripe/browser/search-arrow.gif
Двоичные данные
browser/themes/winstripe/browser/search-arrow.gif
Двоичный файл не отображается.
До Ширина: | Высота: | Размер: 67 B |
|
@ -2,22 +2,11 @@
|
||||||
width: 15em;
|
width: 15em;
|
||||||
}
|
}
|
||||||
|
|
||||||
.searchbar-dropmarker {
|
|
||||||
margin-top: 2px;
|
|
||||||
margin-bottom: 1px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.searchbar-engine-image {
|
.searchbar-engine-image {
|
||||||
margin: 0px 0px 0px 2px;
|
margin: 0px 0px 0px 2px;
|
||||||
list-style-image: url("chrome://browser/skin/Search-bar.png");
|
list-style-image: url("chrome://browser/skin/Search-bar.png");
|
||||||
}
|
}
|
||||||
|
|
||||||
.searchbar-dropmarker-image {
|
|
||||||
-moz-margin-start: 12px;
|
|
||||||
margin-top: 8px;
|
|
||||||
list-style-image: url("chrome://browser/skin/search-arrow.gif");
|
|
||||||
}
|
|
||||||
|
|
||||||
.search-go-button-container {
|
.search-go-button-container {
|
||||||
border-left: 1px solid ThreeDShadow;
|
border-left: 1px solid ThreeDShadow;
|
||||||
}
|
}
|
||||||
|
|
Загрузка…
Ссылка в новой задаче