diff options
Diffstat (limited to 'chrome/content/overlay.js')
-rw-r--r-- | chrome/content/overlay.js | 52 |
1 files changed, 0 insertions, 52 deletions
diff --git a/chrome/content/overlay.js b/chrome/content/overlay.js deleted file mode 100644 index 29b9a07..0000000 --- a/chrome/content/overlay.js +++ /dev/null @@ -1,52 +0,0 @@ -"use strict"; - -var topmenu = { - logger : null, - proxy : null, - - setupLogging: function() { - Components.utils.import("chrome://topmenu/content/log4moz.js", topmenu); - var Log4Moz = this.Log4Moz; - var formatter = new Log4Moz.BasicFormatter(); - var root = Log4Moz.repository.rootLogger; - root.level = Log4Moz.Level.Warn; - - var capp = new Log4Moz.ConsoleAppender(formatter); - capp.level = Log4Moz.Level.Warn; - root.addAppender(capp); - - /* - var dapp = new Log4Moz.DumpAppender(formatter); - dapp.level = Log4Moz.Level.Debug; - root.addAppender(dapp); - */ - - this.logger = Log4Moz.repository.getLogger("topmenu"); - }, - - setupMenuProxy: function() { - Components.utils.import("chrome://topmenu/content/topmenuservice.js", topmenu); - this.proxy = topmenu.TopMenuService.createWindowProxy(window); - }, - - dispose: function() { - if (this.proxy) { - this.proxy.dispose(); - this.proxy = null; - } - }, - - onLoad: function() { - window.removeEventListener('load', topmenu.onLoad); - window.addEventListener('unload', topmenu.onUnload); - topmenu.setupLogging(); - topmenu.setupMenuProxy(); - }, - - onUnload: function() { - window.removeEventListener('unload', topmenu.onUnload); - topmenu.dispose(); - }, -} - -window.addEventListener('load', topmenu.onLoad); |