зеркало из https://github.com/mozilla/gecko-dev.git
Fix bug 35233, Stop on the context menu needs to be disabled at the appropriate times. r=jrgm a=brendan
This commit is contained in:
Родитель
1cb6380993
Коммит
a5d6d0c110
|
@ -60,6 +60,7 @@ catch (ex)
|
|||
var throbberElement = null;
|
||||
var stopButton = null;
|
||||
var stopMenu = null;
|
||||
var stopContext = null;
|
||||
var locationFld = null;
|
||||
var backButton = null;
|
||||
var forwardButton = null;
|
||||
|
@ -286,6 +287,8 @@ nsXULBrowserWindow.prototype =
|
|||
stopButton = document.getElementById("stop-button");
|
||||
if(!stopMenu)
|
||||
stopMenu = document.getElementById("menuitem-stop");
|
||||
if(!stopContext)
|
||||
stopContext = document.getElementById("context-stop");
|
||||
|
||||
if (state & Components.interfaces.nsIWebProgressListener.flag_start) {
|
||||
if(state & Components.interfaces.nsIWebProgressListener.flag_is_network) {
|
||||
|
@ -298,6 +301,7 @@ nsXULBrowserWindow.prototype =
|
|||
// XXX: These need to be based on window activity...
|
||||
stopButton.setAttribute("disabled", false);
|
||||
stopMenu.setAttribute("disabled", false);
|
||||
stopContext.setAttribute("disabled", false);
|
||||
|
||||
// Initialize the progress stuff...
|
||||
statusMeter.setAttribute("mode","undetermined");
|
||||
|
@ -336,6 +340,7 @@ nsXULBrowserWindow.prototype =
|
|||
// XXX: These need to be based on window activity...
|
||||
stopButton.setAttribute("disabled", true);
|
||||
stopMenu.setAttribute("disabled", true);
|
||||
stopContext.setAttribute("disabled", true);
|
||||
|
||||
EnableBusyCursor(false);
|
||||
}
|
||||
|
|
|
@ -95,8 +95,8 @@ nsContextMenu.prototype = {
|
|||
this.showItem( "context-reload", !this.inFrame );
|
||||
this.showItem( "context-reload-frame", this.inFrame );
|
||||
|
||||
// Stop determined by canStop broadcaster.
|
||||
this.setItemAttrFromNode( "context-stop", "disabled", "canStop" );
|
||||
// XXX: Stop is determined in navigator.js; the canStop broadcaster is broken
|
||||
//this.setItemAttrFromNode( "context-stop", "disabled", "canStop" );
|
||||
},
|
||||
initSaveItems : function () {
|
||||
// Save page is always OK, unless in directory listing.
|
||||
|
|
Загрузка…
Ссылка в новой задаче