From 093041bbc540e02ec7f6de1f0fda6055f1658625 Mon Sep 17 00:00:00 2001 From: "mgalli%geckonnection.com" Date: Wed, 11 Jan 2006 20:02:43 +0000 Subject: [PATCH] When start network load, disable menu item nav-menu-button, enables stop. And the treatment the other way around. --- minimo/chrome/content/minimo.js | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/minimo/chrome/content/minimo.js b/minimo/chrome/content/minimo.js index 6a492253128..7a6f7c54199 100755 --- a/minimo/chrome/content/minimo.js +++ b/minimo/chrome/content/minimo.js @@ -103,6 +103,10 @@ nsBrowserStatusHandler.prototype = if (aStateFlags & nsIWebProgressListener.STATE_START) { + // disable and hides the nav-menu-button; and enables unhide the stop button + document.getElementById("nav-menu-button").hidden=true; + document.getElementById("nav-stop-button").hidden=false; + // Notify anyone interested that we are loading. try { var os = Components.classes["@mozilla.org/observer-service;1"] @@ -127,9 +131,13 @@ nsBrowserStatusHandler.prototype = /* To be fixed. We dont want to directly access sytle from here */ document.styleSheets[1].cssRules[0].style.backgroundPosition="1000px 100%"; - if (aRequest) { + if (aRequest) { if (aWebProgress.DOMWindow == content) this.endDocumentLoad(aRequest, aStatus); - } + } + + // disable and hides the nav-stop-button; and enables unhides the nav-menu-button button + document.getElementById("nav-menu-button").hidden=true; + document.getElementById("nav-stop-button").hidden=false; return; }