diff --git a/content/buffer.js b/content/buffer.js index 7b0b4709..3542f2f9 100644 --- a/content/buffer.js +++ b/content/buffer.js @@ -216,12 +216,12 @@ liberator.Buffer = function () //{{{ function (count) { liberator.buffer.scrollLines(-(count > 1 ? count : 1)); }, { flags: liberator.Mappings.flags.COUNT }); - liberator.mappings.add(modes, ["h", ""], + liberator.mappings.add(modes, liberator.has("mail") ? ["h"] : ["h", ""], "Scroll document to the left", function (count) { liberator.buffer.scrollColumns(-(count > 1 ? count : 1)); }, { flags: liberator.Mappings.flags.COUNT }); - liberator.mappings.add(modes, ["l", ""], + liberator.mappings.add(modes, liberator.has("mail") ? ["l"] : ["l", ""], "Scroll document to the right", function (count) { liberator.buffer.scrollColumns(count > 1 ? count : 1); }, { flags: liberator.Mappings.flags.COUNT }); diff --git a/content/mail.js b/content/mail.js index 861b0ae2..a7edb59e 100644 --- a/content/mail.js +++ b/content/mail.js @@ -201,6 +201,27 @@ liberator.Mail = function () "Forward message inline", function () { goDoCommand("cmd_forwardInline"); }); + // SCROLLING + liberator.mappings.add(modes, [""], + "Scroll message down", + function (count) { liberator.buffer.scrollLines(count > 1 ? count : 1); }, + { flags: liberator.Mappings.flags.COUNT }); + + liberator.mappings.add(modes, [""], + "Scroll message up", + function (count) { liberator.buffer.scrollLines(-(count > 1 ? count : 1)); }, + { flags: liberator.Mappings.flags.COUNT }); + + liberator.mappings.add([liberator.modes.MESSAGE], [""], + "Select previous message", + function (count) { liberator.mail.selectMessage(function (msg) { return true; }, false, true, count); }, + { flags: liberator.Mappings.flags.COUNT }); + + liberator.mappings.add([liberator.modes.MESSAGE], [""], + "Select next message", + function (count) { liberator.mail.selectMessage(function (msg) { return true; }, false, false, count); }, + { flags: liberator.Mappings.flags.COUNT }); + // UNDO/REDO liberator.mappings.add(modes, ["u"],