1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2025-12-23 20:02:25 +01:00

Move status updates out of the page load pipeline.

This commit is contained in:
Kris Maglione
2011-03-15 19:27:58 -04:00
parent afbe703985
commit eeb24d07a3
2 changed files with 13 additions and 6 deletions

View File

@@ -96,7 +96,7 @@ var StatusLine = Module("statusline", {
signals: {
"browser.locationChange": function (webProgress, request, uri) {
let win = webProgress.DOMWindow;
this.status = buffer.uri;
this.updateStatus();
this.progress = uri && win && win.dactylProgress || "";
// if this is not delayed we get the position of the old buffer
@@ -142,11 +142,13 @@ var StatusLine = Module("statusline", {
this.progress = 0;
if (flags & Ci.nsIWebProgressListener.STATE_STOP) {
this.progress = "";
this.status = buffer.uri;
this.updateStatus();
}
},
"browser.statusChange": function onStatusChange(webProgress, request, status, message) {
this.timeout(function () {
this.status = message || buffer.uri;
});
},
},
@@ -175,7 +177,7 @@ var StatusLine = Module("statusline", {
// update all fields of the statusline
update: function update() {
this.status = buffer.uri;
this.updateStatus();
this.inputBuffer = "";
this.progress = "";
this.updateTabCount();
@@ -263,7 +265,11 @@ var StatusLine = Module("statusline", {
},
updateStatus: function updateStatus() { this.status = buffer.uri; },
updateStatus: function updateStatus() {
this.timeout(function () {
this.status = buffer.uri;
});
},
updateUrl: deprecated("statusline.status", function updateUrl(url) { this.status = url || buffer.uri }),

View File

@@ -215,7 +215,8 @@ var Contexts = Module("contexts", {
contexts.removeGroup(this.GROUP);
})
});
// Class.replaceProperty(plugins, file.path, self);
if (group !== this.user)
Class.replaceProperty(plugins, file.path, self);
// This belongs elsewhere
if (isPlugin && args)