summaryrefslogtreecommitdiff
path: root/muttator
diff options
context:
space:
mode:
authorKris Maglione <kris@vimperator.org>2009-11-09 03:12:27 -0500
committerKris Maglione <kris@vimperator.org>2009-11-09 03:12:27 -0500
commita72068c9f792be065c84998d28227527f2d1dd45 (patch)
treeefda9a51f58edc285130ea45e8571fd7105445b1 /muttator
parent4d88ccb0368b3697cca433de508cd23ecf15e481 (diff)
downloadpentadactyl-a72068c9f792be065c84998d28227527f2d1dd45.tar.gz
Refactor modules.config.
Diffstat (limited to 'muttator')
-rw-r--r--muttator/content/config.js24
-rw-r--r--muttator/content/mail.js2
2 files changed, 15 insertions, 11 deletions
diff --git a/muttator/content/config.js b/muttator/content/config.js
index ff31088f..557aa581 100644
--- a/muttator/content/config.js
+++ b/muttator/content/config.js
@@ -3,7 +3,12 @@
// This work is licensed for reuse under an MIT license. Details are
// given in the LICENSE.txt file included with this file.
-const config = { //{{{
+const config = Module("config", ConfigBase, {
+ init: function () {
+ // don't wait too long when selecting new messages
+ // GetThreadTree()._selectDelay = 300; // TODO: make configurable
+ },
+
/*** required options, no checks done if they really exist, so be careful ***/
name: "Muttator",
hostApplication: "Thunderbird", // TODO: can this be found out otherwise? gBrandBundle.getString("brandShortName");
@@ -146,20 +151,21 @@ const config = { //{{{
get scripts() this.isComposeWindow() ? ["compose/compose.js"] : [
"addressbook.js",
"mail.js",
+ "tabs.js",
],
// to allow Vim to :set ft=mail automatically
tempFile: "mutt-ator-mail",
- init: function () {
- // don't wait too long when selecting new messages
- // GetThreadTree()._selectDelay = 300; // TODO: make configurable
-
+}, {
+}, {
+ commands: function () {
commands.add(["pref[erences]", "prefs"],
"Show " + config.hostApplication + " preferences",
function () { window.openOptionsDialog(); },
{ argCount: "0" });
-
+ },
+ optons: function () {
// FIXME: comment obviously incorrect
// 0: never automatically edit externally
// 1: automatically edit externally when message window is shown the first time
@@ -179,9 +185,7 @@ const config = { //{{{
},
getter: function () MailOfflineMgr.isOnline()
});
-
- //}}}
- }
-}; //}}}
+ },
+})
// vim: set fdm=marker sw=4 ts=4 et:
diff --git a/muttator/content/mail.js b/muttator/content/mail.js
index 416b95d4..c6a6d84f 100644
--- a/muttator/content/mail.js
+++ b/muttator/content/mail.js
@@ -479,7 +479,7 @@ const Mail = Module("mail", {
bang: true,
});
},
- completions: function () {
+ completion: function () {
completion.mailFolder = function mailFolder(context) {
let folders = mail.getFolders(context.filter);
context.anchored = false;