menuOverlay.xul (4795B)
1 <?xml version="1.0"?> 2 <!-- 3 ***** BEGIN LICENSE BLOCK ***** 4 5 Copyright © 2009 Center for History and New Media 6 George Mason University, Fairfax, Virginia, USA 7 http://zotero.org 8 9 The Original Code is Mozilla.org Code. 10 11 The Initial Developer of the Original Code is Netscape 12 Communications Corporation. Portions created by Netscape are 13 Copyright (C) 1998-2000 Netscape Communications Corporation. All 14 Rights Reserved. 15 16 This file is part of Zotero. 17 18 Zotero is free software: you can redistribute it and/or modify 19 it under the terms of the GNU Affero General Public License as published by 20 the Free Software Foundation, either version 3 of the License, or 21 (at your option) any later version. 22 23 Zotero is distributed in the hope that it will be useful, 24 but WITHOUT ANY WARRANTY; without even the implied warranty of 25 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 26 GNU Affero General Public License for more details. 27 28 You should have received a copy of the GNU Affero General Public License 29 along with Zotero. If not, see <http://www.gnu.org/licenses/>. 30 31 ***** END LICENSE BLOCK ***** 32 --> 33 34 35 <!DOCTYPE overlay [ 36 <!ENTITY % brandDTD SYSTEM "chrome://branding/locale/brand.dtd"> %brandDTD; 37 <!ENTITY % standaloneDTD SYSTEM "chrome://zotero/locale/standalone.dtd"> %standaloneDTD; 38 <!ENTITY % browserDTD SYSTEM "chrome://zotero/locale/mozilla/browser.dtd"> %browserDTD; 39 ]> 40 <overlay id="menuOverlay" 41 xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" 42 xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"> 43 44 <script type="application/javascript" src="chrome://global/content/macWindowMenu.js"/> 45 <script> 46 function openPrefs() { 47 var Zotero = Components.classes['@zotero.org/Zotero;1'] 48 .getService(Components.interfaces.nsISupports) 49 .wrappedJSObject; 50 Zotero.Utilities.Internal.openPreferences(); 51 } 52 </script> 53 54 <commandset id="mainCommandSet"> 55 <command id="minimizeWindow" 56 label="&minimizeWindow.label;" 57 oncommand="window.minimize();" /> 58 <command id="zoomWindow" 59 label="&zoomWindow.label;" 60 oncommand="zoomWindow();" /> 61 </commandset> 62 63 <keyset id="mainKeyset"> 64 <key id="key_minimizeWindow" 65 command="minimizeWindow" 66 key="&minimizeWindow.key;" 67 modifiers="accel"/> 68 <key id="key_openHelpMac" 69 oncommand="ZoteroStandalone.openHelp();" 70 key="&helpMac.commandkey;" 71 modifiers="accel"/> 72 73 <!-- These are used to build the Application menu under Cocoa widgets --> 74 <key id="key_preferencesCmdMac" 75 key="&preferencesCmdMac.commandkey;" 76 modifiers="accel"/> 77 <key id="key_hideThisAppCmdMac" 78 key="&hideThisAppCmdMac.commandkey;" 79 modifiers="accel"/> 80 <key id="key_hideOtherAppsCmdMac" 81 key="&hideOtherAppsCmdMac.commandkey;" 82 modifiers="accel,alt"/> 83 <key id="key_quitApplication" 84 key="&quitApplicationCmdMac.key;" 85 command="cmd_quitApplication" 86 modifiers="accel"/> 87 </keyset> 88 89 <!-- nsMenuBarX hides these and uses them to build the Application menu. --> 90 <menupopup id="menu_FilePopup"> 91 <menuitem id="menu_preferences" 92 label="&preferencesCmdMac.label;" 93 key="key_preferencesCmdMac" 94 oncommand="openPrefs()"/> 95 <menuitem id="menu_mac_services" 96 label="&servicesMenuMac.label;"/> 97 <menuitem id="menu_mac_hide_app" 98 label="&hideThisAppCmdMac.label;" 99 key="key_hideThisAppCmdMac"/> 100 <menuitem id="menu_mac_hide_others" 101 label="&hideOtherAppsCmdMac.label;" 102 key="key_hideOtherAppsCmdMac"/> 103 <menuitem id="menu_mac_show_all" 104 label="&showAllAppsCmdMac.label;"/> 105 <menuitem id="menu_FileQuitItem" 106 label="&quitApplicationCmdMac.label;" 107 key="key_quitApplication" 108 command="cmd_quitApplication"/> 109 </menupopup> 110 111 <menu id="windowMenu" 112 label="&windowMenu.label;" 113 datasources="rdf:window-mediator" ref="NC:WindowMediatorRoot" 114 onpopupshowing="macWindowMenuDidShow();" 115 hidden="false"> 116 <template> 117 <rule> 118 <menupopup> 119 <menuitem uri="rdf:*" 120 label="rdf:http://home.netscape.com/NC-rdf#Name" 121 type="radio" 122 name="windowList" 123 oncommand="ShowWindowFromResource(event.target)"/> 124 </menupopup> 125 </rule> 126 </template> 127 <menupopup id="menu_windowPopup"> 128 <menuitem command="minimizeWindow" label="&minimizeWindow.label;" key="key_minimizeWindow"/> 129 <menuitem command="zoomWindow" label="&zoomWindow.label;"/> 130 <!-- decomment when "BringAllToFront" is implemented 131 <menuseparator/> 132 <menuitem label="&bringAllToFront.label;" disabled="true"/> --> 133 <menuseparator id="sep-window-list"/> 134 </menupopup> 135 </menu> 136 </overlay>