commit 3bcd421f07d83c14ce2f81db9d1b3152907cd8bb parent 25fbec095f251340d1bb0178a18e7459dd111b00 Author: Simon Kornblith <simon@simonster.com> Date: Mon, 31 Jan 2011 20:28:42 +0000 add getActiveZoteroPane() call to global Zotero object Diffstat:
| M | chrome/content/zotero/xpcom/zotero.js | | | 7 | +++++++ |
1 file changed, 7 insertions(+), 0 deletions(-)
diff --git a/chrome/content/zotero/xpcom/zotero.js b/chrome/content/zotero/xpcom/zotero.js @@ -122,6 +122,13 @@ var Zotero = new function(){ Zotero.DB.query(sql, val); }); + this.getActiveZoteroPane = function() { + var wm = Components.classes["@mozilla.org/appshell/window-mediator;1"] + .getService(Components.interfaces.nsIWindowMediator); + var win = wm.getMostRecentWindow("navigator:browser"); + return win.getActiveZoteroPane(); + }; + this.getLocalUserKey = function (generate) { if (_localUserKey) { return _localUserKey;