From 76e5f2d4745f8ccee2c431fce55332b745d7f7b0 Mon Sep 17 00:00:00 2001 From: Kris Maglione Date: Sat, 19 Feb 2011 22:33:08 -0500 Subject: [PATCH] Fix shortcomings in last commit. --- common/content/hints.js | 2 +- common/modules/addons.jsm | 4 ++++ common/modules/downloads.jsm | 4 ++++ common/modules/template.jsm | 4 ++-- 4 files changed, 11 insertions(+), 3 deletions(-) diff --git a/common/content/hints.js b/common/content/hints.js index 479819ff..a3e5c6cc 100644 --- a/common/content/hints.js +++ b/common/content/hints.js @@ -39,7 +39,7 @@ var HintSession = Class("HintSession", CommandMode, { this.top = opts.window || content; this.top.addEventListener("resize", hints.resizeTimer.closure.tell, true); - this.top.addEventListener("dactyl-commandupdate", hints.resizeTimer.closure.tell, true); + this.top.addEventListener("dactyl-commandupdate", hints.resizeTimer.closure.tell, false, true); this.generate(); diff --git a/common/modules/addons.jsm b/common/modules/addons.jsm index 8bf0f7f2..7a6629f2 100644 --- a/common/modules/addons.jsm +++ b/common/modules/addons.jsm @@ -228,6 +228,10 @@ var Addon = Class("Addon", { for (let node in values(this.nodes)) if (node.update && node.update !== callee) node.update(); + + let event = this.document.createEvent("Events"); + event.initEvent("dactyl-commandupdate", true, false); + this.document.dispatchEvent(event); } }); diff --git a/common/modules/downloads.jsm b/common/modules/downloads.jsm index 74840b51..403c1e41 100644 --- a/common/modules/downloads.jsm +++ b/common/modules/downloads.jsm @@ -258,6 +258,10 @@ var DownloadList = Class("DownloadList", if (node.update && node.update != update) node.update(); this.updateProgress(); + + let event = this.document.createEvent("Events"); + event.initEvent("dactyl-commandupdate", true, false); + this.document.dispatchEvent(event); }, timeRemaining: Infinity, diff --git a/common/modules/template.jsm b/common/modules/template.jsm index 976c8d67..d05b1e63 100644 --- a/common/modules/template.jsm +++ b/common/modules/template.jsm @@ -141,8 +141,8 @@ var Template = Module("Template", { if (collapsed == this.commandAllowed) { let event = this.node.ownerDocument.createEvent("Events"); - event.initEvent("dactyl-commandupdate", false, false); - this.node.dispatchEvent(event); + event.initEvent("dactyl-commandupdate", true, false); + this.node.ownerDocument.dispatchEvent(event); } } }),