diff --git a/common/content/dactyl.js b/common/content/dactyl.js index fc7f8bf0..b46ad7b3 100644 --- a/common/content/dactyl.js +++ b/common/content/dactyl.js @@ -1157,7 +1157,7 @@ const Dactyl = Module("dactyl", { // show a usage index either in the MOW or as a full help page showHelpIndex: function (tag, items, inMow) { if (inMow) - dactyl.echo(template.usage(items), commandline.FORCE_MULTILINE); + commandline.commandOutput(template.usage(array(items).sort(function (a, b) String.localeCompare(a.name, b.name)))); else dactyl.help(tag); } diff --git a/common/content/mappings.js b/common/content/mappings.js index 3d335523..37ac49e5 100644 --- a/common/content/mappings.js +++ b/common/content/mappings.js @@ -186,7 +186,13 @@ const Mappings = Module("mappings", { // NOTE: just normal mode for now /** @property {Iterator(Map)} @private */ - __iterator__: function () this._mappingsIterator([modes.NORMAL], this._main), + __iterator__: function () { + let mode = modes.NORMAL; + let seen = {}; + for (let map in iterAll(values(this._user[mode]), values(this._main[mode]))) + if (!set.add(seen, map.name)) + yield map; + }, // used by :mkpentadactylrc to save mappings /** diff --git a/common/modules/base.jsm b/common/modules/base.jsm index 97076991..5cb5df87 100644 --- a/common/modules/base.jsm +++ b/common/modules/base.jsm @@ -1013,7 +1013,7 @@ function octal(decimal) parseInt(decimal, 8); */ const array = Class("array", Array, { init: function (ary) { - if (isinstance(ary, ["Iterator", "Generator"])) + if (isinstance(ary, ["Iterator", "Generator"]) || "__iterator__" in ary) ary = [k for (k in ary)]; else if (ary.length) ary = Array.slice(ary); diff --git a/pentadactyl/TODO b/pentadactyl/TODO index 94978f1a..a763fcac 100644 --- a/pentadactyl/TODO +++ b/pentadactyl/TODO @@ -17,7 +17,6 @@ REFACTORING: - remove unnecessary usage of "self" BUGS: -- :viusage! doesn't work - insert abbreviations broken on - :sidebar improvements (:sidebar! Downloads while downloads is open should refocus the sidebar) - ;s saves the page rather than the image @@ -37,7 +36,7 @@ FEATURES: 8 :redir and 'verbosefile' 8 middleclick in content == p, and if command line is open, paste there the clipboard buffer 8 all search commands should start searching from the top of the visible viewport -8 / should work as in vim (i.e., save page positions as well as +8 / should work as in Vim (i.e., save page positions as well as locations in the history list). 8 jump to the next heading with ]h, next image ]i, previous textbox [t and so on 7 add source location links to the output of certain commands (e.g. :viusage! or describe-key)