mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-06 17:16:12 +00:00
392 lines
18 KiB
XML
392 lines
18 KiB
XML
<?xml version="1.0"?> <!-- -*- Mode: HTML -*- -->
|
|
|
|
<!-- The contents of this file are subject to the Netscape Public
|
|
License Version 1.1 (the "License"); you may not use this file
|
|
except in compliance with the License. You may obtain a copy of
|
|
the License at http://www.mozilla.org/NPL/
|
|
|
|
Software distributed under the License is distributed on an "AS
|
|
IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
|
|
implied. See the License for the specific language governing
|
|
rights and limitations under the License.
|
|
|
|
The Original Code is Mozilla Communicator client code, released
|
|
March 31, 1998.
|
|
|
|
The Initial Developer of the Original Code is Netscape
|
|
Communications Corporation. Portions created by Netscape are
|
|
Copyright (C) 1998-2000 Netscape Communications Corporation. All
|
|
Rights Reserved.
|
|
|
|
Contributor(s): ______________________________________. -->
|
|
|
|
|
|
<?xml-stylesheet href="chrome://navigator/skin/" type="text/css"?>
|
|
|
|
<?xul-overlay href="chrome://navigator/content/navigatorOverlay.xul"?>
|
|
<?xul-overlay href="chrome://navigator/content/navExtraOverlay.xul"?>
|
|
<?xul-overlay href="chrome://communicator/content/tasksOverlay.xul"?>
|
|
<?xul-overlay href="chrome://communicator/content/sidebar/sidebarOverlay.xul"?>
|
|
<?xul-overlay href="chrome://communicator/content/securityOverlay.xul"?>
|
|
<?xul-overlay href="chrome://communicator/content/communicatorOverlay.xul"?>
|
|
|
|
<!DOCTYPE window [
|
|
<!ENTITY % brandDTD SYSTEM "chrome://global/locale/brand.dtd" >
|
|
%brandDTD;
|
|
<!ENTITY % navigatorDTD SYSTEM "chrome://navigator/locale/navigator.dtd" >
|
|
%navigatorDTD;
|
|
]>
|
|
|
|
<window id="main-window" xmlns:html="http://www.w3.org/1999/xhtml"
|
|
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
|
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
|
|
onload="Startup()"
|
|
onunload="Shutdown()"
|
|
contenttitlesettting="true"
|
|
title="&mainWindow.title;"
|
|
titlemodifier="&mainWindow.titlemodifier;"
|
|
titlemenuseparator="&mainWindow.titlemodifiermenuseparator;"
|
|
viewsourcetitlepreface="&viewsourcetitle.preface;"
|
|
windowtype="navigator:browser"
|
|
align="vertical"
|
|
width="640" height="480"
|
|
screenX="10" screenY="10"
|
|
persist="screenX screenY width height sizemode">
|
|
|
|
<script language="javascript" src="chrome://global/content/nsJSSupportsUtils.js"></script>
|
|
<script language="javascript" src="chrome://global/content/nsJSComponentManager.js"></script>
|
|
<script language="javascript" src="chrome://global/content/nsUserSettings.js"></script>
|
|
<script language="javascript" src="chrome://global/content/nsTransferable.js"></script>
|
|
<script language="javascript" src="chrome://global/content/nsClipboard.js"></script>
|
|
<script language="javascript" src="chrome://global/content/nsDragAndDrop.js"></script>
|
|
<script language="javascript" src="chrome://global/content/builtinURLs.js"></script>
|
|
<script language="javascript" src="chrome://global/content/strres.js"></script>
|
|
<script language="javascript" src="chrome://communicator/content/bookmarks/bookmarks.js"></script>
|
|
<script language="javascript" src="chrome://navigator/content/navigator.js"></script>
|
|
<script language="javascript" src="nsContextMenu.js"></script>
|
|
<script language="javascript" src="tooltip.js"></script>
|
|
<script language="javascript" src="navigatorDD.js"></script>
|
|
|
|
<!-- UI services -->
|
|
<script language="javascript" src="chrome://navigator/content/sessionHistoryUI.js"></script>
|
|
<script language="javascript" src="chrome://navigator/content/keywords.js"></script>
|
|
|
|
<commands id="commands">
|
|
<commandset id="globalEditMenuItems"/>
|
|
<commandset id="selectEditMenuItems"/>
|
|
<commandset id="undoEditMenuItems"/>
|
|
<commandset id="clipboardEditMenuItems"/>
|
|
</commands>
|
|
|
|
<!-- broadcasters are appended from the overlay -->
|
|
<broadcasterset id="broadcasterset">
|
|
<broadcaster id="canReload" oncommand="BrowserReallyReload(0);"/>
|
|
<broadcaster id="canPrint"/>
|
|
<broadcaster id="args" value=""/>
|
|
</broadcasterset>
|
|
|
|
<!-- keys are appended from the overlay -->
|
|
<keyset id="keyset"/>
|
|
|
|
<!-- tooltips -->
|
|
<popupset id="aTooltipSet"/>
|
|
<!-- XXX-TEMP this needs to move into an XBL binding for browser!!! -->
|
|
<popupset id="aHTMLTooltipSet">
|
|
<popup id="aHTMLTooltip" class="tooltip" oncreate="return FillInHTMLTooltip(document.tooltipNode);" >
|
|
<box id="HTML_TOOLTIP_tooltipBox" orient="vertical"/>
|
|
</popup>
|
|
</popupset>
|
|
|
|
<!-- Context menu -->
|
|
<script language="javascript">
|
|
// Global variable that holds the nsContextMenu instance.
|
|
var contextMenu = null;
|
|
</script>
|
|
<popupset>
|
|
<!-- This is the context menu for the content-area of the navigator
|
|
window. It contains each and every possible menu choice. The
|
|
appropriate items are hidden/shown upon display, based on what
|
|
the user has clicked-on.
|
|
-->
|
|
<popup id="context"
|
|
oncreate="contextMenu = new nsContextMenu( this ); return contextMenu.shouldDisplay;"
|
|
ondestroy="contextMenu.onDestroy(); contextMenu = null;">
|
|
|
|
<!-- Open ==================================== -->
|
|
<menuitem id="context-openlink"
|
|
value="&openLinkCmd.label;"
|
|
accesskey=""
|
|
oncommand="contextMenu.openLink();"/>
|
|
<!-- XXX - DEPENDENT ON PRESENCE OF EDITOR!! - XXX -->
|
|
<menuitem id="context-editlink"
|
|
value="&editLinkCmd.label;"
|
|
accesskey=""
|
|
oncommand="contextMenu.editLink();"/>
|
|
<menuitem id="context-openframe"
|
|
value="&openFrameCmd.label;"
|
|
accesskey=""
|
|
oncommand="contextMenu.openFrame();"/>
|
|
<menuseparator id="context-sep-open"/>
|
|
<!-- Navigation ============================== -->
|
|
<menuitem id="context-back"
|
|
value="&goBackCmd.label;"
|
|
accesskey="&goBackCmd.accesskey;"
|
|
oncommand="BrowserBack()"/>
|
|
<menuitem id="context-forward"
|
|
value="&goForwardCmd.label;"
|
|
accesskey="&goForwardCmd.accesskey;"
|
|
oncommand="BrowserForward()"/>
|
|
<menuitem id="context-reload"
|
|
value="&reloadCmd.label;"
|
|
accesskey="&reloadCmd.accesskey;"
|
|
oncommand="BrowserReallyReload(0);"/>
|
|
<menuitem id="context-reload-frame"
|
|
value="&reloadFrameCmd.label;"
|
|
accesskey="&reloadFrameCmd.accesskey;"
|
|
oncommand="contextMenu.reloadFrame();"/>
|
|
<menuitem id="context-stop"
|
|
value="&stopCmd.label;"
|
|
accesskey=""
|
|
oncommand="BrowserStop();"/>
|
|
<menuseparator/>
|
|
<!-- View ==================================== -->
|
|
<menuitem id="context-viewsource"
|
|
value="&viewPageSourceCmd.label;"
|
|
accesskey=""
|
|
oncommand="BrowserViewSource();"/>
|
|
<menuitem id="context-viewframesource"
|
|
value="&viewFrameSourceCmd.label;"
|
|
accesskey=""
|
|
oncommand="contextMenu.viewFrameSource();"/>
|
|
<menuitem id="context-viewinfo"
|
|
value="&viewPageInfoCmd.label;"
|
|
accesskey=""
|
|
oncommand="contextMenu.viewInfo();"/>
|
|
<menuitem id="context-viewframeinfo"
|
|
value="&viewFrameInfoCmd.label;"
|
|
accesskey=""
|
|
oncommand="contextMenu.viewFrameInfo();"/>
|
|
<menuitem id="context-viewimage"
|
|
value="&viewImageCmd.label;"
|
|
accesskey=""
|
|
oncommand="contextMenu.viewImage();"/>
|
|
<menuitem id="context-blockimage"
|
|
value="&blockImageCmd.label;"
|
|
accesskey=""
|
|
oncommand="contextMenu.blockImage();"/>
|
|
<menuseparator id="context-sep-view"/>
|
|
<!-- Misc ==================================== -->
|
|
<menuitem id="context-bookmarkpage"
|
|
value="&bookmarkPageCmd.label;"
|
|
accesskey="&bookmarkPageCmd.accesskey;"
|
|
oncommand="BrowserAddBookmark( window._content.location.href,
|
|
window._content.document.title )"/>
|
|
<menuitem id="context-bookmarklink"
|
|
value="&bookmarkLinkCmd.label;"
|
|
accesskey="&bookmarkLinkCmd.accesskey;"
|
|
oncommand="BrowserAddBookmark( contextMenu.linkURL(),
|
|
contextMenu.linkText() )"/>
|
|
<menuseparator/>
|
|
<!-- Save ==================================== -->
|
|
<menuitem id="context-savepage"
|
|
value="&savePageCmd.label;"
|
|
accesskey="&savePageCmd.accesskey;"
|
|
oncommand="contextMenu.savePage();"/>
|
|
<menuitem id="context-saveframe"
|
|
value="&saveFrameCmd.label;"
|
|
accesskey="&saveFrameCmd.accesskey;"
|
|
oncommand="contextMenu.saveFrame();"/>
|
|
<menuitem id="context-savelink"
|
|
value="&saveLinkCmd.label;"
|
|
accesskey="&saveLinkCmd.accesskey;"
|
|
oncommand="contextMenu.saveLink();"/>
|
|
<menuitem id="context-saveimage"
|
|
value="&saveImageCmd.label;"
|
|
accesskey="&saveImageCmd.accesskey;"
|
|
oncommand="contextMenu.saveImage();"/>
|
|
<menuitem id="context-savebgimage"
|
|
value="&saveBGImageCmd.label;"
|
|
accesskey="&saveBGImageCmd.accesskey;"
|
|
oncommand="contextMenu.saveBGImage();"/>
|
|
<menuseparator id="context-sep-save"/>
|
|
<!-- Clipboard =============================== -->
|
|
<menuitem id="context-selectall"
|
|
value="&selectAllCmd.label;"
|
|
accesskey="&selectAllCmd.accesskey;"
|
|
observes="cmd_selectAll"/>
|
|
<menuitem id="context-cut"
|
|
value="&cutCmd.label;"
|
|
accesskey="&cutCmd.accesskey;"
|
|
observes="cmd_cut"/>
|
|
<menuitem id="context-copy"
|
|
value="©Cmd.label;"
|
|
accesskey="©Cmd.accesskey;"
|
|
observes="cmd_copy"/>
|
|
<menuitem id="context-paste"
|
|
value="&pasteCmd.label;"
|
|
accesskey="&pasteCmd.accesskey;"
|
|
observes="cmd_paste"/>
|
|
<menuitem id="context-copylink"
|
|
value="©LinkCmd.label;"
|
|
accesskey="©LinkCmd.accesskey;"
|
|
oncommand="contextMenu.copyLink();"/>
|
|
<menuitem id="context-copyimage"
|
|
value="©ImageCmd.label;"
|
|
accesskey="©ImageCmd.accesskey;"
|
|
oncommand="contextMenu.copyImage();"/>
|
|
</popup>
|
|
</popupset>
|
|
|
|
<popupset>
|
|
<popup id="contextual" oncreate="return fillContextMenu('contextual', 'innermostBox');" >
|
|
<menu />
|
|
</popup>
|
|
</popupset>
|
|
|
|
|
|
<script language="javascript">
|
|
var gBookmarkPopup = null;
|
|
</script>
|
|
|
|
<toolbox id="navigator-toolbox" class="toolbox-top" deferattached="true">
|
|
<!-- Menu -->
|
|
<menubar id="main-menubar" persist="collapsed" grippytooltip="aTooltip" grippytooltiptext="&menuBar.tooltip;"/>
|
|
|
|
<toolbar class="toolbar-primary chromeclass-toolbar" id="nav-bar" persist="collapsed"
|
|
grippytooltip="aTooltip" grippytooltiptext="&navigationBar.tooltip;">
|
|
<menubutton class="menubutton-dual toolbar top" id="back-button" value="&backButton.label;"
|
|
crop="right" observes="canGoBack" oncommand="gotoHistoryIndex(event);"
|
|
tooltip="aTooltip"
|
|
buttonaction="BrowserBack();" buttontooltiptext="&backButton.tooltip;">
|
|
<menupopup oncreate="BrowserBackMenu(event);"/>
|
|
</menubutton>
|
|
<menubutton class="menubutton-dual toolbar top" id="forward-button"
|
|
crop="right" observes="canGoForward" tooltip="aTooltip"
|
|
oncommand="gotoHistoryIndex(event);" buttonaction="BrowserForward();"
|
|
value="&forwardButton.label;" buttontooltiptext="&forwardButton.tooltip;">
|
|
<menupopup oncreate="BrowserForwardMenu(event);"/>
|
|
</menubutton>
|
|
|
|
<button class="button-toolbar-1 top" id="reload-button" crop="right" observes="canReload" value="&reloadButton.label;"
|
|
tooltip="aTooltip" tooltiptext="&reloadButton.tooltip;"/>
|
|
<button class="button-toolbar-1 top" id="stop-button" crop="right" observes="canStop" onclick="BrowserStop()" value="&stopButton.label;"
|
|
tooltip="aTooltip" tooltiptext="&stopButton.tooltip;"/>
|
|
|
|
<toolbarseparator/>
|
|
<box id="nav-bar-inner" autostretch="never" flex="1" style="min-width: 0px;">
|
|
<box id="urlbar-group" class="box-toolbar-group chromeclass-location" flex="1">
|
|
<box autostretch="never" valign="middle" flex="1" id="urlbar-container">
|
|
<image id="page-proxy-button" ondraggesture="nsDragAndDrop.startDrag(event, proxyIconDNDObserver);"/>
|
|
<textfield autocomplete="true" timeout="300" class="plain"
|
|
searchSessionType="urlbar" id="urlbar" tooltip="aTooltip" tooltiptext="&locationBar.tooltip;"
|
|
onkeypress="if( event.keyCode == 13 ) { addToUrlbarHistory(); BrowserLoadURL(); }" flex="1"/>
|
|
</box>
|
|
<menubutton class="menubutton-icon" id="ubhist">
|
|
<menupopup id="ubhist-popup" popupalign="topright" popupanchor="bottomright"
|
|
oncreate="createUBHistoryMenu(event.target);" oncommand="executeUrlBarHistoryCommand(event.target);">
|
|
<menuitem value=" "/>
|
|
</menupopup>
|
|
</menubutton>
|
|
<button class="button-toolbar-3" id="go-button" value="&goButton.label;" oncommand="addToUrlbarHistory(); BrowserLoadURL();"
|
|
tooltip="aTooltip" tooltiptext="&goButton.tooltip;"/>
|
|
</box>
|
|
<button class="button-toolbar-3 chromeclass-location" id="search-button" value="&searchButton.label;"
|
|
oncommand="OpenSearch('internet',false, document.getElementById('urlbar').value);"
|
|
tooltip="aTooltip" tooltiptext="&searchButton.tooltip;"/>
|
|
<button id="navigator-throbber" oncommand="goClickThrobber('browser.throbber.url')" tooltip="aTooltip" tooltiptext="&throbber.tooltip;"/>
|
|
</box>
|
|
</toolbar>
|
|
|
|
<toolbar id="PersonalToolbar" class="chromeclass-directories" persist="collapsed" dragdroparea="innermostBox"
|
|
ondragover="nsDragAndDrop.dragOver(event, personalToolbarObserver);"
|
|
ondragdrop="nsDragAndDrop.drop(event, personalToolbarObserver);"
|
|
ondraggesture="nsDragAndDrop.startDrag(event, personalToolbarObserver);"
|
|
ondragexit="nsDragAndDrop.dragExit(event, personalToolbarObserver);"
|
|
grippytooltip="aTooltip" grippytooltiptext="&personalBar.tooltip;"
|
|
last-toolbar="true">
|
|
|
|
<!-- Personal toolbar items -->
|
|
<box id="innermostBox" flex="1" style="min-width: 1px;" context="contextual"
|
|
datasources="rdf:bookmarks" ref="NC:PersonalToolbarFolder" flags="dont-test-empty">
|
|
|
|
<template>
|
|
<rule parent="box" iscontainer="true">
|
|
<menubutton class="button-toolbar bookmarkfolder" uri="rdf:*"
|
|
tooltip="aTooltip" tooltiptext="rdf:http://home.netscape.com/NC-rdf#URL"
|
|
value="rdf:http://home.netscape.com/NC-rdf#Name">
|
|
<menupopup/>
|
|
</menubutton>
|
|
</rule>
|
|
|
|
<rule parent="box">
|
|
<button class="button-toolbar bookmarkitem" uri="rdf:*"
|
|
tooltip="aTooltip" tooltiptext="rdf:http://home.netscape.com/NC-rdf#URL"
|
|
value="rdf:http://home.netscape.com/NC-rdf#Name" crop="right"
|
|
oncommand="OpenBookmarkURL(event.target, document.getElementById('innermostBox').database);"/>
|
|
</rule>
|
|
|
|
<rule iscontainer="true">
|
|
<menupopup>
|
|
<menu class="menu-iconic bookmarkfolder" uri="rdf:*"
|
|
value="rdf:http://home.netscape.com/NC-rdf#Name">
|
|
<menupopup/>
|
|
</menu>
|
|
</menupopup>
|
|
</rule>
|
|
<rule rdf:type="http://home.netscape.com/NC-rdf#BookmarkSeparator">
|
|
<menupopup>
|
|
<menuseparator uri="rdf:*" />
|
|
</menupopup>
|
|
</rule>
|
|
<rule>
|
|
<menupopup>
|
|
<menuitem class="menuitem-iconic bookmarkitem" uri="rdf:*"
|
|
value="rdf:http://home.netscape.com/NC-rdf#Name"
|
|
oncommand="OpenBookmarkURL(event.target, document.getElementById('innermostBox').database)"/>
|
|
</menupopup>
|
|
</rule>
|
|
</template>
|
|
|
|
<button class="button-toolbar bookmarkitem" id="homebutton" value="&homeButton.label;"
|
|
tooltip="aTooltip"
|
|
ondraggesture="nsDragAndDrop.startDrag(event, homeButtonObserver);"
|
|
ondragover="nsDragAndDrop.dragOver(event, homeButtonObserver);"
|
|
ondragdrop="nsDragAndDrop.drop(event, homeButtonObserver);"
|
|
ondragexit="nsDragAndDrop.dragExit(event, homeButtonObserver);"
|
|
oncommand="BrowserHome(); event.preventBubble();"/>
|
|
|
|
<toolbarseparator/>
|
|
|
|
</box>
|
|
|
|
</toolbar>
|
|
|
|
</toolbox>
|
|
|
|
<box flex="1" >
|
|
<box id="sidebar-box" class="chromeclass-extrachrome"/>
|
|
<splitter id="sidebar-splitter" class="chromeclass-extrachrome" />
|
|
|
|
<box id="appcontent" align="vertical" flex="100%"
|
|
onclick="if (event.button==2) browserHandleMiddleClick(event);"
|
|
ondragover="nsDragAndDrop.dragOver(event, contentAreaDNDObserver);"
|
|
ondragdrop="nsDragAndDrop.drop(event, contentAreaDNDObserver);"
|
|
ondraggesture="nsDragAndDrop.startDrag(event, contentAreaDNDObserver);">
|
|
|
|
<!-- this box is temporary, pending XBLified <browser> -->
|
|
<box id="browser" flex="1">
|
|
<browser context="context" type="content-primary" id="content"
|
|
src="about:blank" flex="1" tooltip="aHTMLTooltip" onmouseover="if (throbberElement) EnableBusyCursor(throbberElement.getAttribute('busy') == 'true')"/>
|
|
</box>
|
|
|
|
<statusbar id="status-bar" class="chromeclass-status"/>
|
|
|
|
</box>
|
|
|
|
|
|
</box>
|
|
|
|
<box id="taskbar" class="chromeclass-extrachrome toolbox-bottom"/>
|
|
|
|
</window>
|