1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2025-12-22 05:57:59 +01:00

Give *.penta plugins their own JS sandboxen.

--HG--
branch : key-processing
This commit is contained in:
Kris Maglione
2011-01-26 14:35:58 -05:00
parent b051e4edc2
commit 787f063692
5 changed files with 18 additions and 6 deletions

View File

@@ -478,7 +478,7 @@ var JavaScript = Module("javascript", {
if (obj.length) {
let func = obj[0][0][funcName];
if (callable(func)) {
let [, prefix, args] = /^(function .*?)\((.*)?\)/.exec(Function.prototype.toString.call(func));
let [, prefix, args] = /^(function .*?)\((.*?)\)/.exec(Function.prototype.toString.call(func));
let n = this._get(i).comma.length;
args = template.map(Iterator(args.split(", ")),
function ([i, arg]) <span highlight={i == n ? "Filter" : ""}>{arg}</span>,