mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 564075 - Url bar gets displaced, with open sidebar, focusing url bar and then dismissing awesome bar [r=mfinkle]
This commit is contained in:
parent
a03d3624fe
commit
727be4ffff
@ -197,13 +197,11 @@ var BrowserUI = {
|
||||
|
||||
_updateToolbar: function _updateToolbar() {
|
||||
let icons = document.getElementById("urlbar-icons");
|
||||
if (Browser.selectedTab.isLoading() && icons.getAttribute("mode") != "loading") {
|
||||
this.lockToolbar();
|
||||
let mode = icons.getAttribute("mode");
|
||||
if (Browser.selectedTab.isLoading() && mode != "loading") {
|
||||
icons.setAttribute("mode", "loading");
|
||||
}
|
||||
else if (icons.getAttribute("mode") != "view") {
|
||||
if (this.isToolbarLocked())
|
||||
this.unlockToolbar();
|
||||
else if (mode != "view") {
|
||||
icons.setAttribute("mode", "view");
|
||||
}
|
||||
},
|
||||
@ -463,6 +461,7 @@ var BrowserUI = {
|
||||
this._updateToolbar();
|
||||
|
||||
this._updateIcon(browser.mIconURL);
|
||||
this.unlockToolbar();
|
||||
break;
|
||||
|
||||
case TOOLBARSTATE_LOADING:
|
||||
@ -471,6 +470,7 @@ var BrowserUI = {
|
||||
|
||||
browser.mIconURL = "";
|
||||
this._updateIcon();
|
||||
this.lockToolbar();
|
||||
break;
|
||||
}
|
||||
},
|
||||
@ -754,11 +754,9 @@ var BrowserUI = {
|
||||
break;
|
||||
// URL textbox events
|
||||
case "mouseup":
|
||||
if (!this._isEventInsidePopup(aEvent))
|
||||
this._hidePopup();
|
||||
|
||||
if (aEvent.detail < 2 && aEvent.button == 0)
|
||||
if (aEvent.detail < 2 && aEvent.button == 0 && gFocusManager.focusedElement == this._edit.inputField) {
|
||||
this.doCommand("cmd_openLocation");
|
||||
}
|
||||
break;
|
||||
case "mousedown":
|
||||
if (!this._isEventInsidePopup(aEvent))
|
||||
|
@ -781,12 +781,20 @@ var Browser = {
|
||||
if (this._selectedTab) {
|
||||
this._selectedTab.contentScrollOffset = this.getScrollboxPosition(this.contentScrollboxScroller);
|
||||
this._selectedTab.pageScrollOffset = this.getScrollboxPosition(this.pageScrollboxScroller);
|
||||
|
||||
// Make sure we leave the toolbar in an unlocked state
|
||||
if (this._selectedTab.isLoading())
|
||||
BrowserUI.unlockToolbar();
|
||||
}
|
||||
|
||||
let isFirstTab = this._selectedTab == null;
|
||||
let lastTab = this._selectedTab;
|
||||
this._selectedTab = tab;
|
||||
|
||||
// Lock the toolbar if the new tab is still loading
|
||||
if (this._selectedTab.isLoading())
|
||||
BrowserUI.lockToolbar();
|
||||
|
||||
tab.ensureBrowserExists();
|
||||
|
||||
bv.beginBatchOperation();
|
||||
|
Loading…
Reference in New Issue
Block a user