From 9320c5b1bebae5ebefd3661a2c351ed028988afb Mon Sep 17 00:00:00 2001 From: Martin Stubenschrott Date: Fri, 10 Apr 2009 10:17:35 +0200 Subject: [PATCH] * Fix muttator and experimentally increase buffer position display timeout to 500ms to avoid rendering the page twice --- common/content/events.js | 2 +- muttator/content/config.js | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/common/content/events.js b/common/content/events.js index 929afd26..972af6ca 100644 --- a/common/content/events.js +++ b/common/content/events.js @@ -1699,7 +1699,7 @@ function Events() //{{{ autocommands.trigger("LocationChange", { url: buffer.URL }); // if this is not delayed we get the position of the old buffer - setTimeout(function () { statusline.updateBufferPosition(); }, 100); + setTimeout(function () { statusline.updateBufferPosition(); }, 500); }, // called at the very end of a page load asyncUpdateUI: function () diff --git a/muttator/content/config.js b/muttator/content/config.js index 27cc400c..62bb0a78 100644 --- a/muttator/content/config.js +++ b/muttator/content/config.js @@ -104,7 +104,8 @@ const config = { //{{{ focusChange: function(win) { // we switch to -- MESSAGE -- mode for Muttator, when the main HTML widget gets focus - if (hasHTMLDocument(win) || elem instanceof HTMLAnchorElement) + let elem = window.document.commandDispatcher.focusedElement; + if ((win && win.document && win.document instanceof HTMLDocument) || elem instanceof HTMLAnchorElement) { if (config.isComposeWindow) modes.set(modes.INSERT, modes.TEXTAREA); @@ -123,7 +124,7 @@ const config = { //{{{ ],*/ optionDefaults: { - stal: 2, + showtabline: 1, }, scripts: [