1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2026-02-16 17:35:46 +01:00

More stuff.

This commit is contained in:
Kris Maglione
2011-07-26 21:25:37 -04:00
parent cff57155e6
commit 969cdfc5dc
4 changed files with 11 additions and 11 deletions

View File

@@ -756,14 +756,12 @@ var Options = Module("options", {
opt.set(opt.globalValue, Option.SCOPE_GLOBAL, true);
}, window);
function escape(str) str.replace(/[<&]/g, function (m) ({ "&": "&amp;", "<": "&lt;" })[m]);
services["dactyl:"].pages["options.dtd"] = function () [null,
util.makeDTD(
iter(([["option", o.name, "default"].join("."),
escape(o.type === "string" ? o.defaultValue.replace(/'/g, "''") :
o.value === true ? "on" :
o.value === false ? "off" : o.stringDefaultValue)]
o.type === "string" ? o.defaultValue.replace(/'/g, "''") :
o.value === true ? "on" :
o.value === false ? "off" : o.stringDefaultValue]
for (o in self)),
([["option", o.name, "type"].join("."), o.type] for (o in self)),