Don't rely on last browser window to open prefs from menu
This commit is contained in:
parent
ee0b4f5d0d
commit
a8ba2fac33
|
@ -42,6 +42,14 @@
|
||||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
|
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
|
||||||
|
|
||||||
<script type="application/javascript" src="chrome://global/content/macWindowMenu.js"/>
|
<script type="application/javascript" src="chrome://global/content/macWindowMenu.js"/>
|
||||||
|
<script>
|
||||||
|
function openPrefs() {
|
||||||
|
var Zotero = Components.classes['@zotero.org/Zotero;1']
|
||||||
|
.getService(Components.interfaces.nsISupports)
|
||||||
|
.wrappedJSObject;
|
||||||
|
Zotero.Utilities.Internal.openPreferences();
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
<commandset id="mainCommandSet">
|
<commandset id="mainCommandSet">
|
||||||
<command id="minimizeWindow"
|
<command id="minimizeWindow"
|
||||||
|
@ -83,7 +91,7 @@
|
||||||
<menuitem id="menu_preferences"
|
<menuitem id="menu_preferences"
|
||||||
label="&preferencesCmdMac.label;"
|
label="&preferencesCmdMac.label;"
|
||||||
key="key_preferencesCmdMac"
|
key="key_preferencesCmdMac"
|
||||||
oncommand="Components.classes['@mozilla.org/appshell/window-mediator;1'].getService(Components.interfaces.nsIWindowMediator).getMostRecentWindow('navigator:browser').Zotero.Utilities.Internal.openPreferences();"/>
|
oncommand="openPrefs()"/>
|
||||||
<menuitem id="menu_mac_services"
|
<menuitem id="menu_mac_services"
|
||||||
label="&servicesMenuMac.label;"/>
|
label="&servicesMenuMac.label;"/>
|
||||||
<menuitem id="menu_mac_hide_app"
|
<menuitem id="menu_mac_hide_app"
|
||||||
|
|
Loading…
Reference in New Issue
Block a user