1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2025-12-30 04:22:28 +01:00

Frob some fnords.

This commit is contained in:
Kris Maglione
2008-10-02 06:42:42 +00:00
parent 0a905986d9
commit 76b6c530b1
9 changed files with 187 additions and 176 deletions

View File

@@ -205,23 +205,21 @@ liberator.AutoCommands = function () //{{{
let cmds = (item for (item in Iterator(autoCommands))
if ((!auEvent || item[0] == auEvent) && item[1].length));
// Okay, maybe a bit scary. --Kris
XML.prettyPrinting = false;
var list = liberator.buffer.template.generic(
var list = liberator.template.generic(
<table>
<tr>
<td class="hl-Title" colspan="2">----- Auto Commands -----</td>
</tr>
{[
{
liberator.template.map2(cmds, function (event, items)
<tr>
<td class="hl-Title" colspan="2">{event}</td>
</tr>
+ [<tr>
<td>&#160;{item[0]}</td>
<td>{item[1]}</td>
</tr>
for each (item in items)].reduce(liberator.buffer.template.add)
for ([event, items] in cmds)].reduce(liberator.buffer.template.add, <></>)
+ liberator.template.map(items, function (item)
<tr>
<td>&#160;{item[0]}</td>
<td>{item[1]}</td>
</tr>))
}
</table>);
@@ -669,13 +667,13 @@ liberator.Events = function () //{{{
{
XML.prettyPrinting = false;
var str = <table>
{[
{
liberator.template.map2(liberator.events.getMacros(args),
function(macro, keys)
<tr>
<td>{macro}</td>
<td>{keys}</td>
</tr>
for ([macro, keys] in Iterator(liberator.events.getMacros(args)))
].reduce(liberator.buffer.template.add, <></>)
</tr>)
}
</table>.toXMLString();
liberator.echo(str, liberator.commandline.FORCE_MULTILINE);