diff options
author | Einar Egilsson | 2009-05-10 05:20:55 +0000 |
---|---|---|
committer | Einar Egilsson | 2009-05-10 05:20:55 +0000 |
commit | 0226cb6655cdf0948be1e91d0876925c0b7cb72c (patch) | |
tree | a964da8d7c49842eaa8edbf69498dfb127f01456 /chrome/content/redirectList.js | |
parent | 612e652d4a9feac5331c0262bbe6d234df3542e7 (diff) |
SVN keywords on all source files
git-svn-id: http://einaregilsson.googlecode.com/svn/mozilla/redirector/trunk@210 119bf307-c92d-0410-89bd-8f53e6181181
Diffstat (limited to 'chrome/content/redirectList.js')
-rw-r--r-- | chrome/content/redirectList.js | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/chrome/content/redirectList.js b/chrome/content/redirectList.js index c50583b..cd8c550 100644 --- a/chrome/content/redirectList.js +++ b/chrome/content/redirectList.js @@ -1,5 +1,8 @@ +//// $Id$ var Redirector = Components.classes["@einaregilsson.com/redirector;1"].getService(Components.interfaces.nsISupports).wrappedJSObject; +const Cc = Components.classes; +const Ci = Components.interfaces; function $(id) { return document.getElementById(id); @@ -45,6 +48,21 @@ var RedirectList = { } }, + openHelp : function() {
+ var windowName = "redirectorHelp";
+ var windowsMediator = Cc["@mozilla.org/appshell/window-mediator;1"].getService(Ci.nsIWindowMediator);
+ var win;
+ var iter = windowsMediator.getEnumerator(null);
+ while (iter.hasMoreElements()) {
+ win = iter.getNext();
+ if (win.name == windowName) {
+ win.focus();
+ return;
+ }
+ }
+ window.openDialog("chrome://redirector/content/help.html", windowName, "chrome,dialog,resizable=yes,location=0,toolbar=0,status=0,width=800px,height=600px,centerscreen", this);
+ },
+ close : function() { window.close(); }, |