зеркало из https://github.com/mozilla/pjs.git
Make url bar work again after toolbar rebuild.
This commit is contained in:
Родитель
f149ef735f
Коммит
ccabc06975
|
@ -320,6 +320,9 @@ function Startup()
|
|||
gBrowser = document.getElementById("content");
|
||||
gURLBar = document.getElementById("urlbar");
|
||||
|
||||
var toolbar = document.getElementById("nav-bar");
|
||||
toolbar.toolbarChanged = BrowserToolbarChanged;
|
||||
|
||||
SetPageProxyState("invalid", null);
|
||||
|
||||
var webNavigation;
|
||||
|
@ -3542,6 +3545,14 @@ function goAboutDialog()
|
|||
}
|
||||
|
||||
|
||||
function BrowserToolbarChanged()
|
||||
{
|
||||
gURLBar = document.getElementById("urlbar");
|
||||
gProxyButton = document.getElementById("page-proxy-button");
|
||||
gProxyFavIcon = document.getElementById("page-proxy-favicon");
|
||||
gProxyDeck = document.getElementById("page-proxy-deck");
|
||||
}
|
||||
|
||||
function BrowserCustomizeToolbar()
|
||||
{
|
||||
window.openDialog("chrome://browser/content/customizeToolbar.xul", "Customize Toolbar", "modal,chrome,resizable=yes");
|
||||
|
|
|
@ -275,4 +275,15 @@ function updateToolbar()
|
|||
var toolbar = window.opener.document.getElementById("nav-bar");
|
||||
toolbar.setAttribute("currentset", newSet);
|
||||
window.opener.document.persist("nav-bar", "currentset");
|
||||
|
||||
toolbar.rebuild();
|
||||
}
|
||||
|
||||
// Revert back to the default set.
|
||||
function resetToDefault()
|
||||
{
|
||||
var toolbar = window.opener.document.getElementById("nav-bar");
|
||||
var defaultSet = toolbar.getAttribute("defaultset");
|
||||
var cloneToolbar = document.getElementById("cloneToolbar");
|
||||
|
||||
}
|
||||
|
|
|
@ -19,6 +19,11 @@
|
|||
<field name="afterPalette">
|
||||
null
|
||||
</field>
|
||||
|
||||
<field name="toolbarChanged">
|
||||
null
|
||||
</field>
|
||||
|
||||
<method name="rebuild">
|
||||
<body>
|
||||
<![CDATA[
|
||||
|
@ -26,6 +31,7 @@
|
|||
this.removeChild(this.firstChild);
|
||||
}
|
||||
this.buildItemsFromPalette();
|
||||
this.toolbarChanged();
|
||||
]]>
|
||||
</body>
|
||||
</method>
|
||||
|
|
Загрузка…
Ссылка в новой задаче