Reduce use of eval()
This commit is contained in:
parent
330e7503aa
commit
be899d1b52
@ -299,12 +299,12 @@ var TreeStyleTabWindowHelper = {
|
|||||||
}, 'treeStyleTab');
|
}, 'treeStyleTab');
|
||||||
}
|
}
|
||||||
|
|
||||||
TreeStyleTabUtils.doPatching(FullScreen.toggle, 'FullScreen.toggle', function(aName, aSource) {
|
FullScreen.__treestyletab__toggle = FullScreen.toggle;
|
||||||
return eval(aName+' = '+aSource.replace(
|
FullScreen.toggle = function(...aArgs) {
|
||||||
'if (enterFS) {',
|
var enterFS = window.fullScreen;
|
||||||
'gBrowser.treeStyleTab.onBeforeFullScreenToggle(enterFS); $&'
|
gBrowser.treeStyleTab.onBeforeFullScreenToggle(enterFS);
|
||||||
));
|
return this.__treestyletab__toggle.apply(this, aArgs);
|
||||||
}, 'treeStyleTab');
|
};
|
||||||
|
|
||||||
PrintUtils.__treestyletab__printPreview = PrintUtils.printPreview;
|
PrintUtils.__treestyletab__printPreview = PrintUtils.printPreview;
|
||||||
PrintUtils.printPreview = function(...aArgs) {
|
PrintUtils.printPreview = function(...aArgs) {
|
||||||
|
Loading…
Reference in New Issue
Block a user