1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2025-12-21 13:28:11 +01:00

Move application specific modes to config.modes.

This commit is contained in:
Doug Kearns
2009-05-24 01:56:44 +10:00
parent aeec233730
commit abc11f1068
3 changed files with 10 additions and 5 deletions

View File

@@ -275,11 +275,6 @@ const modes = (function () //{{{
self.addMode("CARET"); // text cursor is visible
self.addMode("TEXTAREA", { char: "i" }); // text cursor is in a HTMLTextAreaElement
self.addMode("CUSTOM", { display: function () plugins.mode });
// FIXME: These belong elsewhere
// So too, probably, do most of the others.
self.addMode("MESSAGE", { char: "m" }); // for now only used in Muttator when the message has focus
self.addMode("COMPOSE");
self.addMode("PLAYER", { char: "p" }); // Player mode for songbird
// extended modes, can include multiple modes, and even main modes
self.addMode("EX", true);
self.addMode("HINTS", true);
@@ -293,6 +288,9 @@ const modes = (function () //{{{
self.addMode("LINE", true); // linewise visual mode
self.addMode("PROMPT", true);
if (config.modes)
config.modes.forEach(function (mode) { self.addMode.apply(self, mode) });
return self;
//}}}
})(); //}}}

View File

@@ -123,6 +123,11 @@ const config = { //{{{
"various.html"
],*/
modes: [
["MESSAGE", { char: "m" }],
["COMPOSE"]
],
optionDefaults: {
showtabline: 1,
},

View File

@@ -163,6 +163,8 @@ const config = { //{{{
"developer.html", "various.html", "index.html", "version.html"
],
modes: [["PLAYER", { char: "p" }]],
optionDefaults: {
showtabline: 2,
},