зеркало из https://github.com/mozilla/pjs.git
bug 92947 r=timeless sr=jag
Better feedback when components of a page do not download
This commit is contained in:
Родитель
5997ad1072
Коммит
263e89a020
|
@ -256,10 +256,21 @@ nsBrowserStatusHandler.prototype =
|
|||
var location = aRequest.QueryInterface(nsIChannel).URI.spec;
|
||||
var msg = "";
|
||||
if (location != "about:blank") {
|
||||
// Record page loading time.
|
||||
var elapsed = ((new Date()).getTime() - this.startTime) / 1000;
|
||||
msg = gNavigatorBundle.getString("nv_done");
|
||||
msg = msg.replace(/%elapsed%/, elapsed);
|
||||
const kErrorBindingAborted = 2152398850;
|
||||
const kErrorNetTimeout = 2152398862;
|
||||
switch (aStatus) {
|
||||
case kErrorBindingAborted:
|
||||
msg = gNavigatorBundle.getString("nv_stopped");
|
||||
break;
|
||||
case kErrorNetTimeout:
|
||||
msg = gNavigatorBundle.getString("nv_timeout");
|
||||
break;
|
||||
default:
|
||||
// Record page loading time.
|
||||
var elapsed = ((new Date()).getTime() - this.startTime) / 1000;
|
||||
msg = gNavigatorBundle.getString("nv_done");
|
||||
msg = msg.replace(/%elapsed%/, elapsed);
|
||||
}
|
||||
}
|
||||
this.status = "";
|
||||
this.setDefaultStatus(msg);
|
||||
|
|
|
@ -1,4 +1,6 @@
|
|||
nv_done=Document: Done (%elapsed% secs)
|
||||
nv_timeout=Timed Out
|
||||
nv_stopped=Stopped
|
||||
openFile=Open File
|
||||
defaultStatus=
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче