home *** CD-ROM | disk | FTP | other *** search
/ Chip 2002 January / 01_02.iso / software / netscape62win / browser.xpi / bin / chrome / comm.jar / content / communicator / contentAreaContextOverlay.xul < prev    next >
Encoding:
Extensible Markup Language  |  2001-08-13  |  8.6 KB  |  180 lines

  1. <?xml version="1.0"?> 
  2. <!-- The contents of this file are subject to the Netscape Public
  3.    - License Version 1.1 (the "License"); you may not use this file
  4.    - except in compliance with the License. You may obtain a copy of
  5.    - the License at http://www.mozilla.org/NPL/
  6.    - 
  7.    - Software distributed under the License is distributed on an "AS
  8.    - IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
  9.    - implied. See the License for the specific language governing
  10.    - rights and limitations under the License.
  11.    - 
  12.    - The Original Code is Mozilla Communicator client code, released
  13.    - March 31, 1998.
  14.    - 
  15.    - The Initial Developer of the Original Code is Netscape
  16.    - Communications Corporation. Portions created by Netscape are
  17.    - Copyright (C) 1998-1999 Netscape Communications Corporation. All
  18.    - Rights Reserved.
  19.    - 
  20.    - Contributor(s):
  21.    -   Blake Ross <blakeross@telocity.com>
  22.    -->
  23. <!DOCTYPE window SYSTEM "chrome://communicator/locale/contentAreaCommands.dtd" >
  24. <overlay id="contentAreaContextOverlay"
  25.          xmlns:html="http://www.w3.org/1999/xhtml"
  26.          xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
  27.          xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
  28.  
  29.   <!-- Context menu -->
  30.   <!-- XXX: Replace strres.js when nsContextMenu.js is converted -->
  31.   <script type="application/x-javascript" src="chrome://global/content/strres.js"/>
  32.   <script type="application/x-javascript">
  33.     // Global variable that holds the nsContextMenu instance.
  34.     var gContextMenu = null;
  35.   </script>
  36.   <script type="application/x-javascript" src="chrome://communicator/content/nsContextMenu.js"/>
  37.   <script type="application/x-javascript" src="chrome://communicator/content/contentAreaUtils.js"/>
  38.  
  39.   <popupset id="contentAreaContextSet">
  40.     <!-- This is a generic context menu for a content area. It contains 
  41.          each and every possible menu choice.  The appropriate items are
  42.          hidden/shown upon display, based on what the user has clicked-on.
  43.      -->
  44.     <popup id="contentAreaContextMenu"
  45.            onpopupshowing="gContextMenu = new nsContextMenu( this ); return gContextMenu.shouldDisplay;"
  46.            onpopuphiding="gContextMenu.onDestroy(); gContextMenu = null;">
  47.       <!-- Open ==================================== -->
  48.       <menuitem id="context-openlink"
  49.                 label="&openLinkCmd.label;"
  50.                 accesskey="&openLinkCmd.accesskey;"
  51.                 oncommand="gContextMenu.openLink();"/>
  52.       <!-- XXX - DEPENDENT ON PRESENCE OF EDITOR!! - XXX -->
  53.       <menuitem id="context-editlink"
  54.                 label="&editLinkCmd.label;"
  55.                 accesskey="&editLinkCmd.accesskey;"
  56.                 oncommand="gContextMenu.editLink();"/>
  57.       <menuitem id="context-openframe"
  58.                 label="&openFrameCmd.label;"
  59.                 accesskey="&openFrameCmd.accesskey;"
  60.                 oncommand="gContextMenu.openFrame();"/>
  61.       <menuitem id="context-showonlythisframe"
  62.                 label="&showOnlyThisFrameCmd.label;"
  63.                 accesskey="&showOnlyThisFrameCmd.accesskey;"
  64.                 oncommand="gContextMenu.showOnlyThisFrame();"/>
  65.       <menuseparator id="context-sep-open"/>
  66.       <!-- Navigation ============================== -->
  67.       <menuitem id="context-back"
  68.                 label="&goBackCmd.label;"
  69.                 accesskey="&goBackCmd.accesskey;"
  70.                 oncommand="BrowserBack()"/>
  71.       <menuitem id="context-forward"
  72.                 label="&goForwardCmd.label;"
  73.                 accesskey="&goForwardCmd.accesskey;"
  74.                 oncommand="BrowserForward()"/>
  75.       <menuitem id="context-reload"
  76.                 label="&reloadCmd.label;"
  77.                 accesskey="&reloadCmd.accesskey;"
  78.                 oncommand="BrowserReload();"/>
  79.       <menuitem id="context-reload-frame"
  80.                 label="&reloadFrameCmd.label;"
  81.                 accesskey="&reloadFrameCmd.accesskey;"
  82.                 oncommand="gContextMenu.reloadFrame();"/>
  83.       <menuitem id="context-stop"
  84.                 label="&stopCmd.label;"
  85.                 oncommand="BrowserStop();"/>
  86.       <menuseparator id="context-sep-navigation"/>
  87.       <!-- View ==================================== -->
  88.       <menuitem id="context-viewsource"
  89.                 label="&viewPageSourceCmd.label;"
  90.                 accesskey="&viewPageSourceCmd.accesskey;"
  91.                 oncommand="BrowserViewSource();"/>
  92.       <menuitem id="context-viewframesource"
  93.                 label="&viewFrameSourceCmd.label;"
  94.                 accesskey="&viewFrameSourceCmd.accesskey;"
  95.                 oncommand="gContextMenu.viewFrameSource();"/>
  96.       <menuitem id="context-viewinfo"
  97.                 label="&viewPageInfoCmd.label;"
  98.                 accesskey="&viewPageInfoCmd.accesskey;"
  99.                 oncommand="gContextMenu.viewInfo();"/>
  100.       <menuitem id="context-viewframeinfo"
  101.                 label="&viewFrameInfoCmd.label;"
  102.                 accesskey="&viewFrameInfoCmd.accesskey;"
  103.                 oncommand="gContextMenu.viewFrameInfo();"/>
  104.       <menuitem id="context-viewimage"
  105.                 label="&viewImageCmd.label;"
  106.                 accesskey="&viewImageCmd.accesskey;"
  107.                 oncommand="gContextMenu.viewImage();"/>
  108.       <menuitem id="context-viewbgimage"
  109.                 label="&viewBGImageCmd.label;"
  110.                 accesskey="&viewBGImageCmd.accesskey;"
  111.                 oncommand="gContextMenu.viewBGImage();"/>
  112.       <menuseparator id="context-sep-view"/>
  113.       <!-- Misc ==================================== -->
  114.       <menuitem id="context-bookmarkpage"
  115.                 label="&bookmarkPageCmd.label;"
  116.                 accesskey="&bookmarkPageCmd.accesskey;"
  117.                 oncommand="BookmarksUtils.addBookmarkForBrowser(document.getElementById('content').webNavigation, true);"/>
  118.       <menuitem id="context-bookmarklink"
  119.                 label="&bookmarkLinkCmd.label;"
  120.                 accesskey="&bookmarkLinkCmd.accesskey;"
  121.                 oncommand="BookmarksUtils.addBookmark(gContextMenu.linkURL(),
  122.                                                       gContextMenu.linkText(), 
  123.                                                       undefined, true);"/>
  124.       <menuseparator id="context-sep-bookmark"/>
  125.       <!-- Save ==================================== -->
  126.       <menuitem id="context-savepage"
  127.                 label="&savePageCmd.label;"
  128.                 accesskey="&savePageCmd.accesskey;"
  129.                 oncommand="gContextMenu.savePage();"/>
  130.       <menuitem id="context-saveframe"
  131.                 label="&saveFrameCmd.label;"
  132.                 accesskey="&saveFrameCmd.accesskey;"
  133.                 oncommand="gContextMenu.saveFrame();"/>
  134.       <menuitem id="context-savelink"
  135.                 label="&saveLinkCmd.label;"
  136.                 accesskey="&saveLinkCmd.accesskey;"
  137.                 oncommand="gContextMenu.saveLink();"/>
  138.       <menuitem id="context-saveimage"
  139.                 accesskey="&saveImageCmd.accesskey;"
  140.                 oncommand="gContextMenu.saveImage();"/>
  141.       <menuseparator id="context-sep-save"/>
  142.       <!-- Clipboard =============================== -->
  143.       <menuitem id="context-selectall"
  144.                 label="&selectAllCmd.label;"
  145.                 accesskey="&selectAllCmd.accesskey;"
  146.                 command="cmd_selectAll"/>
  147.       <menuitem id="context-cut"
  148.                 label="&cutCmd.label;"
  149.                 accesskey="&cutCmd.accesskey;"
  150.                 command="cmd_cut"/>
  151.       <menuitem id="context-copy"
  152.                 label="©Cmd.label;"
  153.                 accesskey="©Cmd.accesskey;"
  154.                 command="cmd_copy"/>
  155.       <menuitem id="context-paste"
  156.                 label="&pasteCmd.label;"
  157.                 accesskey="&pasteCmd.accesskey;"
  158.                 command="cmd_paste"/>
  159.       <menuitem id="context-copyemail"
  160.                 label="©EmailCmd.label;"
  161.                 accesskey="©EmailCmd.accesskey;"
  162.                 oncommand="gContextMenu.copyEmail();"/>
  163.       <menuitem id="context-copylink"
  164.                 label="©LinkCmd.label;"
  165.                 accesskey="©LinkCmd.accesskey;"
  166.                 command="cmd_copyLink"/>
  167.       <menuitem id="context-copyimage"
  168.                 label="©ImageCmd.label;"
  169.                 accesskey="©ImageCmd.accesskey;"
  170.                 command="cmd_copyImageLocation"/>
  171.       <menuseparator id="context-sep-clip"/>
  172.       <!-- Metadata ================================ -->
  173.       <menuitem id="context-metadata"
  174.                 label="&metadataCmd.label;"
  175.                 accesskey="&metadataCmd.accesskey;"
  176.                 oncommand="gContextMenu.showMetadata();"/>
  177.     </popup>
  178.   </popupset>
  179. </overlay>
  180.