1 diff --git a/browser/app/Makefile.in b/browser/app/Makefile.in
2 --- a/browser/app/Makefile.in
3 +++ b/browser/app/Makefile.in
4 @@ -44,16 +44,17 @@ srcdir = @srcdir@
7 include $(DEPTH)/config/autoconf.mk
9 DIRS = profile/extensions
11 PREF_JS_EXPORTS = $(srcdir)/profile/firefox.js \
12 $(srcdir)/profile/channel-prefs.js \
13 + $(srcdir)/profile/kde.js \
17 # hardcode en-US for the moment
20 DEFINES += -DAB_CD=$(AB_CD)
22 diff --git a/browser/base/content/browser-kde.xul b/browser/base/content/browser-kde.xul
25 +++ b/browser/base/content/browser-kde.xul
28 +<?xml version="1.0"?>
31 +# ***** BEGIN LICENSE BLOCK *****
32 +# Version: MPL 1.1/GPL 2.0/LGPL 2.1
34 +# The contents of this file are subject to the Mozilla Public License Version
35 +# 1.1 (the "License"); you may not use this file except in compliance with
36 +# the License. You may obtain a copy of the License at
37 +# http://www.mozilla.org/MPL/
39 +# Software distributed under the License is distributed on an "AS IS" basis,
40 +# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
41 +# for the specific language governing rights and limitations under the
44 +# The Original Code is Mozilla Communicator client code, released
47 +# The Initial Developer of the Original Code is
48 +# Netscape Communications Corporation.
49 +# Portions created by the Initial Developer are Copyright (C) 1998-2000
50 +# the Initial Developer. All Rights Reserved.
53 +# Blake Ross <blake@cs.stanford.edu>
54 +# David Hyatt <hyatt@mozilla.org>
55 +# Joe Hewitt <hewitt@netscape.com>
56 +# Pierre Chanial <chanial@noos.fr>
57 +# Dean Tessman <dean_tessman@hotmail.com>
58 +# Johnathan Nightingale <johnath@mozilla.com>
59 +# Dão Gottwald <dao@mozilla.com>
60 +# Ehsan Akhgari <ehsan.akhgari@gmail.com>
61 +# Robert Strong <robert.bugzilla@gmail.com>
62 +# Rob Campbell <rcampbell@mozilla.com>
63 +# Patrick Walton <pcwalton@mozilla.com>
64 +# David Dahl <ddahl@mozilla.com>
65 +# Frank Yan <fyan@mozilla.com>
67 +# Alternatively, the contents of this file may be used under the terms of
68 +# either the GNU General Public License Version 2 or later (the "GPL"), or
69 +# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
70 +# in which case the provisions of the GPL or the LGPL are applicable instead
71 +# of those above. If you wish to allow use of your version of this file only
72 +# under the terms of either the GPL or the LGPL, and not to allow others to
73 +# use your version of this file under the terms of the MPL, indicate your
74 +# decision by deleting the provisions above and replace them with the notice
75 +# and other provisions required by the GPL or the LGPL. If you do not delete
76 +# the provisions above, a recipient may use your version of this file under
77 +# the terms of any one of the MPL, the GPL or the LGPL.
79 +# ***** END LICENSE BLOCK *****
81 +<?xml-stylesheet href="chrome://browser/content/browser.css" type="text/css"?>
82 +<?xml-stylesheet href="chrome://browser/content/places/places.css" type="text/css"?>
83 +<?xml-stylesheet href="chrome://global/skin/webConsole.css" type="text/css"?>
84 +<?xml-stylesheet href="chrome://browser/skin/" type="text/css"?>
86 +<?xul-overlay href="chrome://global/content/editMenuOverlay.xul"?>
87 +<?xul-overlay href="chrome://browser/content/baseMenuOverlay.xul"?>
88 +<?xul-overlay href="chrome://browser/content/places/placesOverlay.xul"?>
90 +# All DTD information is stored in a separate file so that it can be shared by
92 +#include browser-doctype.inc
94 +<window id="main-window"
95 + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
96 + xmlns:svg="http://www.w3.org/2000/svg"
97 + xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
98 + onload="BrowserStartup()" onunload="BrowserShutdown()" onclose="return WindowIsClosing();"
99 + title="&mainWindow.title;@PRE_RELEASE_SUFFIX@"
100 + title_normal="&mainWindow.title;@PRE_RELEASE_SUFFIX@"
102 + title_privatebrowsing="&mainWindow.title;@PRE_RELEASE_SUFFIX@&mainWindow.titlemodifiermenuseparator;&mainWindow.titlePrivateBrowsingSuffix;"
103 + titledefault="&mainWindow.title;@PRE_RELEASE_SUFFIX@"
105 + titlemodifier_normal=""
106 + titlemodifier_privatebrowsing="&mainWindow.titlePrivateBrowsingSuffix;"
108 + title_privatebrowsing="&mainWindow.titlemodifier;@PRE_RELEASE_SUFFIX@ &mainWindow.titlePrivateBrowsingSuffix;"
109 + titlemodifier="&mainWindow.titlemodifier;@PRE_RELEASE_SUFFIX@"
110 + titlemodifier_normal="&mainWindow.titlemodifier;@PRE_RELEASE_SUFFIX@"
111 + titlemodifier_privatebrowsing="&mainWindow.titlemodifier;@PRE_RELEASE_SUFFIX@ &mainWindow.titlePrivateBrowsingSuffix;"
113 + titlemenuseparator="&mainWindow.titlemodifiermenuseparator;"
114 + lightweightthemes="true"
115 + lightweightthemesfooter="browser-bottombox"
116 + windowtype="navigator:browser"
117 + screenX="4" screenY="4"
118 + browsingmode="normal"
119 + persist="screenX screenY width height sizemode">
121 +# All JS files which are not content (only) dependent that browser.xul
122 +# wishes to include *must* go into the global-scripts.inc file
123 +# so that they can be shared by macBrowserOverlay.xul.
124 +#include global-scripts.inc
125 +<script type="application/javascript" src="chrome://browser/content/nsContextMenu.js"/>
127 +#ifdef MOZ_SAFE_BROWSING
128 +<script type="application/javascript" src="chrome://browser/content/safebrowsing/sb-loader.js"/>
130 +<script type="application/javascript" src="chrome://global/content/contentAreaUtils.js"/>
132 +<script type="application/javascript" src="chrome://browser/content/places/editBookmarkOverlay.js"/>
134 +# All sets except for popupsets (commands, keys, stringbundles and broadcasters) *must* go into the
135 +# browser-sets.inc file for sharing with hiddenWindow.xul.
136 +#include browser-sets.inc
138 + <popupset id="mainPopupSet">
139 + <menupopup id="tabContextMenu"
140 + onpopupshowing="if (event.target == this) TabContextMenu.updateContextMenu(this);"
141 + onpopuphidden="if (event.target == this) TabContextMenu.contextTab = null;">
142 + <menuitem id="context_reloadTab" label="&reloadTab.label;" accesskey="&reloadTab.accesskey;"
143 + oncommand="gBrowser.reloadTab(TabContextMenu.contextTab);"/>
145 + <menuitem id="context_pinTab" label="&pinAppTab.label;"
146 + accesskey="&pinAppTab.accesskey;"
147 + oncommand="gBrowser.pinTab(TabContextMenu.contextTab);"/>
148 + <menuitem id="context_unpinTab" label="&unpinAppTab.label;" hidden="true"
149 + accesskey="&unpinAppTab.accesskey;"
150 + oncommand="gBrowser.unpinTab(TabContextMenu.contextTab);"/>
151 + <menu id="context_tabViewMenu" label="&moveToGroup.label;"
152 + accesskey="&moveToGroup.accesskey;">
153 + <menupopup id="context_tabViewMenuPopup"
154 + onpopupshowing="if (event.target == this) TabView.moveToGroupPopupShowing(event);">
155 + <menuseparator id="context_tabViewNamedGroups" hidden="true"/>
156 + <menuitem id="context_tabViewNewGroup" label="&moveToNewGroup.label;"
157 + oncommand="TabView.moveTabTo(TabContextMenu.contextTab, null);"/>
160 + <menuitem id="context_openTabInWindow" label="&moveToNewWindow.label;"
161 + accesskey="&moveToNewWindow.accesskey;"
162 + tbattr="tabbrowser-multiple"
163 + oncommand="gBrowser.replaceTabWithWindow(TabContextMenu.contextTab);"/>
165 + <menuitem id="context_reloadAllTabs" label="&reloadAllTabs.label;" accesskey="&reloadAllTabs.accesskey;"
166 + tbattr="tabbrowser-multiple"
167 + oncommand="gBrowser.reloadAllTabs();"/>
168 + <menuitem id="context_bookmarkAllTabs"
169 + label="&bookmarkAllTabs.label;"
170 + accesskey="&bookmarkAllTabs.accesskey;"
171 + command="Browser:BookmarkAllTabs"/>
172 + <menuitem id="context_closeOtherTabs" label="&closeOtherTabs.label;" accesskey="&closeOtherTabs.accesskey;"
173 + oncommand="gBrowser.removeAllTabsBut(TabContextMenu.contextTab);"/>
175 + <menuitem id="context_undoCloseTab"
176 + label="&undoCloseTab.label;"
177 + accesskey="&undoCloseTab.accesskey;"
178 + observes="History:UndoCloseTab"/>
179 + <menuitem id="context_closeTab" label="&closeTab.label;" accesskey="&closeTab.accesskey;"
180 + oncommand="gBrowser.removeTab(TabContextMenu.contextTab, { animate: true });"/>
183 + <!-- bug 415444/582485: event.stopPropagation is here for the cloned version
184 + of this menupopup -->
185 + <menupopup id="backForwardMenu"
186 + onpopupshowing="return FillHistoryMenu(event.target);"
187 + oncommand="gotoHistoryIndex(event); event.stopPropagation();"
188 + onclick="checkForMiddleClick(this, event);"/>
189 + <tooltip id="aHTMLTooltip" onpopupshowing="return FillInHTMLTooltip(document.tooltipNode);"/>
191 + <!-- for search and content formfill/pw manager -->
192 + <panel type="autocomplete" id="PopupAutoComplete" noautofocus="true" hidden="true"/>
194 + <!-- for url bar autocomplete -->
195 + <panel type="autocomplete-richlistbox" id="PopupAutoCompleteRichResult" noautofocus="true" hidden="true"/>
197 + <!-- for invalid form error message -->
198 + <panel id="invalid-form-popup" type="arrow" orient="vertical" noautofocus="true" hidden="true" level="parent">
202 + <panel id="editBookmarkPanel"
207 + onpopupshown="StarUI.panelShown(event);"
208 + aria-labelledby="editBookmarkPanelTitle">
209 + <row id="editBookmarkPanelHeader" align="center" hidden="true">
210 + <vbox align="center">
211 + <image id="editBookmarkPanelStarIcon"/>
214 + <label id="editBookmarkPanelTitle"/>
215 + <description id="editBookmarkPanelDescription"/>
217 + <button id="editBookmarkPanelRemoveButton"
218 + class="editBookmarkPanelHeaderButton"
219 + oncommand="StarUI.removeBookmarkButtonCommand();"
220 + accesskey="&editBookmark.removeBookmark.accessKey;"/>
224 + <vbox id="editBookmarkPanelContent" flex="1" hidden="true"/>
225 + <hbox id="editBookmarkPanelBottomButtons" pack="end">
227 + <button id="editBookmarkPanelDoneButton"
228 + class="editBookmarkPanelBottomButton"
229 + label="&editBookmark.done.label;"
231 + oncommand="StarUI.panel.hidePopup();"/>
232 + <button id="editBookmarkPanelDeleteButton"
233 + class="editBookmarkPanelBottomButton"
234 + label="&editBookmark.cancel.label;"
235 + oncommand="StarUI.cancelButtonOnCommand();"/>
237 + <button id="editBookmarkPanelDeleteButton"
238 + class="editBookmarkPanelBottomButton"
239 + label="&editBookmark.cancel.label;"
240 + oncommand="StarUI.cancelButtonOnCommand();"/>
241 + <button id="editBookmarkPanelDoneButton"
242 + class="editBookmarkPanelBottomButton"
243 + label="&editBookmark.done.label;"
245 + oncommand="StarUI.panel.hidePopup();"/>
250 + <panel id="highlighter-panel"
255 + onclick="InspectorUI.stopInspecting();"
256 + onmousemove="InspectorUI.highlighter.handleMouseMove(event);"
257 + onMozMousePixelScroll="InspectorUI.highlighter.handlePixelScroll(event);"/>
259 + <panel id="inspector-tree-panel"
267 + onpopuphiding="InspectorUI.closeInspectorUI(true);"
268 + label="&inspectPanelTitle.label;">
269 + <toolbar id="inspector-toolbar"
270 + nowindowdrag="true">
271 + <toolbarbutton id="inspector-inspect-toolbutton"
272 + label="&inspectButton.label;"
273 + accesskey="&inspectButton.accesskey;"
274 + class="toolbarbutton-text"
275 + command="Inspector:Inspect"/>
276 + <toolbarbutton id="inspector-previous-toolbutton"
277 + label="&inspectPreviousButton.label;"
278 + accesskey="&inspectPreviousButton.accesskey;"
279 + class="toolbarbutton-text"
280 + command="Inspector:Previous"/>
281 + <toolbarbutton id="inspector-next-toolbutton"
282 + label="&inspectNextButton.label;"
283 + accesskey="&inspectNextButton.accesskey;"
284 + class="toolbarbutton-text"
285 + command="Inspector:Next"/>
286 + <toolbarbutton id="inspector-style-toolbutton"
287 + label="&inspectStyleButton.label;"
288 + accesskey="&inspectStyleButton.accesskey;"
289 + class="toolbarbutton-text"
290 + oncommand="InspectorUI.toggleStylePanel();"/>
291 + <toolbarbutton id="inspector-dom-toolbutton"
292 + label="&inspectObjectButton.label;"
293 + accesskey="&inspectObjectButton.accesskey;"
294 + class="toolbarbutton-text"
295 + oncommand="InspectorUI.toggleDOMPanel();"/>
297 + <hbox id="tree-panel-resizer-box" align="end">
298 + <spacer flex="1" />
299 + <resizer dir="bottomend" />
303 + <panel id="inspector-style-panel"
310 + label="&inspectStylePanelTitle.label;">
311 + <listbox id="inspector-style-listbox" flex="1"/>
313 + <spacer flex="1" />
314 + <resizer dir="bottomend"/>
318 + <menupopup id="toolbar-context-menu"
319 + onpopupshowing="onViewToolbarsPopupShowing(event);">
321 + <menuitem command="cmd_ToggleTabsOnTop"
323 + label="&viewTabsOnTop.label;"
324 + accesskey="&viewTabsOnTop.accesskey;"/>
326 + <menuitem command="cmd_CustomizeToolbars"
327 + label="&viewCustomizeToolbar.label;"
328 + accesskey="&viewCustomizeToolbar.accesskey;"/>
331 + <menupopup id="blockedPopupOptions"
332 + onpopupshowing="gPopupBlockerObserver.fillPopupList(event);"
333 + onpopuphiding="gPopupBlockerObserver.onPopupHiding(event);">
334 + <menuitem observes="blockedPopupAllowSite"/>
335 + <menuitem observes="blockedPopupEditSettings"/>
336 + <menuitem observes="blockedPopupDontShowMessage"/>
337 + <menuseparator observes="blockedPopupsSeparator"/>
340 + <menupopup id="autohide-context"
341 + onpopupshowing="FullScreen.getAutohide(this.firstChild);">
342 + <menuitem type="checkbox" label="&fullScreenAutohide.label;"
343 + accesskey="&fullScreenAutohide.accesskey;"
344 + oncommand="FullScreen.setAutohide();"/>
346 + <menuitem label="&fullScreenExit.label;"
347 + accesskey="&fullScreenExit.accesskey;"
348 + oncommand="BrowserFullScreen();"/>
351 + <menupopup id="contentAreaContextMenu"
352 + onpopupshowing="if (event.target != this)
354 + gContextMenu = new nsContextMenu(this, gBrowser);
355 + if (gContextMenu.shouldDisplay)
356 + updateEditUIVisibility();
357 + return gContextMenu.shouldDisplay;"
358 + onpopuphiding="if (event.target == this) { gContextMenu = null; updateEditUIVisibility(); }">
359 +#include browser-context.inc
362 + <menupopup id="placesContext"/>
364 + <panel id="notification-popup" type="arrow" position="after_start"
365 + hidden="true" orient="vertical"/>
367 + <!-- Popup for site identity information -->
368 + <panel id="identity-popup"
372 + onpopupshown="document.getElementById('identity-popup-more-info-button').focus();"
374 + <hbox id="identity-popup-container" align="top">
375 + <image id="identity-popup-icon"/>
376 + <vbox id="identity-popup-content-box">
377 + <label id="identity-popup-connectedToLabel"
378 + class="identity-popup-label"
379 + value="&identity.connectedTo;"/>
380 + <label id="identity-popup-connectedToLabel2"
381 + class="identity-popup-label"
382 + value="&identity.unverifiedsite2;"/>
383 + <description id="identity-popup-content-host"
384 + class="identity-popup-description"/>
385 + <label id="identity-popup-runByLabel"
386 + class="identity-popup-label"
387 + value="&identity.runBy;"/>
388 + <description id="identity-popup-content-owner"
389 + class="identity-popup-description"/>
390 + <description id="identity-popup-content-supplemental"
391 + class="identity-popup-description"/>
392 + <description id="identity-popup-content-verifier"
393 + class="identity-popup-description"/>
394 + <hbox id="identity-popup-encryption" flex="1">
396 + <image id="identity-popup-encryption-icon"/>
398 + <description id="identity-popup-encryption-label" flex="1"
399 + class="identity-popup-description"/>
401 + <!-- Footer button to open security page info -->
402 + <hbox id="identity-popup-button-container" pack="end">
403 + <button id="identity-popup-more-info-button"
404 + label="&identity.moreInfoLinkText;"
405 + onblur="gIdentityHandler.hideIdentityPopup();"
406 + oncommand="gIdentityHandler.handleMoreInfoClick(event);"/>
412 + <tooltip id="urlTooltip">
413 + <label crop="center" flex="1" class="tooltip-label"/>
416 + <panel id="ctrlTab-panel" class="KUI-panel" hidden="true" norestorefocus="true" level="top">
418 + <button class="ctrlTab-preview" flex="1"/>
419 + <button class="ctrlTab-preview" flex="1"/>
420 + <button class="ctrlTab-preview" flex="1"/>
421 + <button class="ctrlTab-preview" flex="1"/>
422 + <button class="ctrlTab-preview" flex="1"/>
423 + <button class="ctrlTab-preview" flex="1"/>
425 + <hbox pack="center">
426 + <button id="ctrlTab-showAll" class="ctrlTab-preview" noicon="true"/>
430 + <panel id="allTabs-panel" hidden="true" norestorefocus="true" ignorekeys="true"
431 + onmouseover="allTabs._updateTabCloseButton(event);">
432 + <hbox id="allTabs-meta" align="center">
434 + <textbox id="allTabs-filter"
435 + tooltiptext="&allTabs.filter.emptyText;"
437 + oncommand="allTabs.filter();"/>
439 + <toolbarbutton class="KUI-panel-closebutton"
440 + oncommand="allTabs.close()"
441 + tooltiptext="&closeCmd.label;"/>
443 + <stack id="allTabs-stack">
444 + <vbox id="allTabs-container"><hbox/></vbox>
445 + <toolbarbutton id="allTabs-tab-close-button"
446 + class="tabs-closebutton"
447 + oncommand="allTabs.closeTab(event);"
448 + tooltiptext="&closeCmd.label;"
449 + style="visibility:hidden"/>
453 + <!-- Bookmarks and history tooltip -->
454 + <tooltip id="bhTooltip"/>
456 + <panel id="customizeToolbarSheetPopup"
458 + <iframe id="customizeToolbarSheetIFrame"
459 + style="&dialog.style;"
463 + <tooltip id="tabbrowser-tab-tooltip" onpopupshowing="gBrowser.createTooltip(event);"/>
466 +#ifdef CAN_DRAW_IN_TITLEBAR
467 +<vbox id="titlebar">
468 + <hbox id="titlebar-content">
469 + <hbox id="appmenu-button-container">
470 + <button id="appmenu-button"
472 + label="&brandShortName;"
473 + style="-moz-user-focus: ignore;">
474 +#include browser-appmenu.inc
477 + <spacer id="titlebar-spacer" flex="1"/>
478 + <hbox id="titlebar-buttonbox-container" align="start">
479 + <hbox id="titlebar-buttonbox">
480 + <toolbarbutton class="titlebar-button" id="titlebar-min" oncommand="window.minimize();"/>
481 + <toolbarbutton class="titlebar-button" id="titlebar-max" oncommand="onTitlebarMaxClick();"/>
482 + <toolbarbutton class="titlebar-button" id="titlebar-close" command="cmd_closeWindow"/>
489 +<deck flex="1" id="tab-view-deck">
492 + <toolbox id="navigator-toolbox"
493 + defaultmode="icons" mode="icons"
495 + defaulticonsize="small" iconsize="small"
500 + persist="tabsontop">
502 + <toolbar type="menubar" id="toolbar-menubar" class="chromeclass-menubar" customizable="true"
503 + defaultset="menubar-items"
504 + mode="icons" iconsize="small" defaulticonsize="small"
505 + lockiconsize="true"
506 +#ifdef MENUBAR_CAN_AUTOHIDE
507 + toolbarname="&menubarCmd.label;"
508 + accesskey="&menubarCmd.accesskey;"
510 + context="toolbar-context-menu">
511 + <toolbaritem id="menubar-items" align="center">
512 +# The entire main menubar is placed into browser-menubar.inc, so that it can be shared by
514 +#include browser-menubar.inc
517 +#ifdef CAN_DRAW_IN_TITLEBAR
518 + <hbox class="titlebar-placeholder" type="appmenu-button" ordinal="0"/>
519 + <hbox class="titlebar-placeholder" type="caption-buttons" ordinal="1000"/>
523 + <toolbar id="nav-bar" class="toolbar-primary chromeclass-toolbar"
524 + toolbarname="&navbarCmd.label;" accesskey="&navbarCmd.accesskey;"
525 + fullscreentoolbar="true" mode="icons" customizable="true"
527 + iconsize="small" defaulticonsize="small"
528 + defaultset="unified-back-forward-button,urlbar-container,reload-button,stop-button,search-container,home-button,bookmarks-menu-button-container,navigator-throbber,fullscreenflex,window-controls"
531 + defaultset="unified-back-forward-button,urlbar-container,reload-button,stop-button,search-container,home-button,bookmarks-menu-button-container,fullscreenflex,window-controls"
533 + context="toolbar-context-menu">
535 + <toolbaritem id="unified-back-forward-button" class="chromeclass-toolbar-additional"
536 + context="backForwardMenu" removable="true"
537 + title="&backForwardItem.title;">
538 + <toolbarbutton id="back-button" class="toolbarbutton-1"
539 + label="&backCmd.label;"
540 + command="Browser:BackOrBackDuplicate"
541 + onclick="checkForMiddleClick(this, event);"
542 + tooltiptext="&backButton.tooltip;"/>
543 + <toolbarbutton id="forward-button" class="toolbarbutton-1"
544 + label="&forwardCmd.label;"
545 + command="Browser:ForwardOrForwardDuplicate"
546 + onclick="checkForMiddleClick(this, event);"
547 + tooltiptext="&forwardButton.tooltip;"/>
550 + <toolbaritem id="urlbar-container" align="center" flex="400" persist="width" combined="true"
551 + title="&locationItem.title;" class="chromeclass-location" removable="true">
552 + <textbox id="urlbar" flex="1"
553 + placeholder="&urlbar.placeholder;"
554 + type="autocomplete"
555 + autocompletesearch="history"
556 + autocompletesearchparam="enable-actions"
557 + autocompletepopup="PopupAutoCompleteRichResult"
558 + completeselectedindex="true"
559 + tabscrolling="true"
560 + showcommentcolumn="true"
561 + showimagecolumn="true"
562 + enablehistory="true"
564 + newlines="stripsurroundingwhitespace"
565 + oninput="gBrowser.userTypedValue = this.value;"
566 + ontextentered="this.handleCommand(param);"
567 + ontextreverted="return this.handleRevert();"
568 + pageproxystate="invalid"
569 + onsearchbegin="LocationBarHelpers._searchBegin();"
570 + onsearchcomplete="LocationBarHelpers._searchComplete();"
571 + onfocus="document.getElementById('identity-box').style.MozUserFocus= 'normal'"
572 + onblur="setTimeout(function() document.getElementById('identity-box').style.MozUserFocus = '', 0);">
573 + <box id="notification-popup-box" hidden="true" align="center">
574 + <image id="default-notification-icon" class="notification-anchor-icon" role="button"/>
575 + <image id="geo-notification-icon" class="notification-anchor-icon" role="button"/>
576 + <image id="addons-notification-icon" class="notification-anchor-icon" role="button"/>
577 + <image id="indexedDB-notification-icon" class="notification-anchor-icon" role="button"/>
578 + <image id="password-notification-icon" class="notification-anchor-icon" role="button"/>
580 + <!-- Use onclick instead of normal popup= syntax since the popup
581 + code fires onmousedown, and hence eats our favicon drag events.
582 + We only add the identity-box button to the tab order when the location bar
583 + has focus, otherwise pressing F6 focuses it instead of the location bar -->
584 + <box id="identity-box" role="button"
585 + onclick="gIdentityHandler.handleIdentityButtonEvent(event);"
586 + onkeypress="gIdentityHandler.handleIdentityButtonEvent(event);"
587 + ondragstart="gIdentityHandler.onDragStart(event);">
588 + <hbox id="identity-box-inner" align="center">
589 + <stack id="page-proxy-stack"
590 + onclick="PageProxyClickHandler(event);">
591 + <image id="urlbar-throbber" busy="false"/>
592 + <image id="page-proxy-favicon" validate="never"
593 + pageproxystate="invalid"
594 + onerror="this.removeAttribute('src');"/>
596 + <hbox id="identity-icon-labels">
597 + <label id="identity-icon-label" class="plain" flex="1"/>
598 + <label id="identity-icon-country-label" class="plain"/>
602 + <box id="urlbar-display-box" align="center">
603 + <label id="urlbar-display" value="&urlbar.switchToTab.label;"/>
605 + <hbox id="urlbar-icons">
606 + <image id="page-report-button"
607 + class="urlbar-icon"
609 + tooltiptext="&pageReportIcon.tooltip;"
610 + onclick="gPopupBlockerObserver.onReportButtonClick(event);"/>
612 + <image id="star-button"
613 + class="urlbar-icon"
614 + onclick="PlacesStarButton.onClick(event);"/>
615 + <image id="go-button"
616 + class="urlbar-icon"
617 + tooltiptext="&goEndCap.tooltip;"
618 + onclick="gURLBar.handleCommand(event);"/>
620 + <toolbarbutton id="urlbar-go-button"
621 + class="chromeclass-toolbar-additional"
622 + onclick="gURLBar.handleCommand(event);"
623 + tooltiptext="&goEndCap.tooltip;"/>
624 + <toolbarbutton id="urlbar-reload-button"
625 + class="chromeclass-toolbar-additional"
626 + command="Browser:ReloadOrDuplicate"
627 + onclick="checkForMiddleClick(this, event);"
628 + tooltiptext="&reloadButton.tooltip;"/>
629 + <toolbarbutton id="urlbar-stop-button"
630 + class="chromeclass-toolbar-additional"
631 + command="Browser:Stop"
632 + tooltiptext="&stopButton.tooltip;"/>
636 + <toolbarbutton id="reload-button" class="toolbarbutton-1 chromeclass-toolbar-additional"
637 + label="&reloadCmd.label;" removable="true"
638 + command="Browser:ReloadOrDuplicate"
639 + onclick="checkForMiddleClick(this, event);"
640 + tooltiptext="&reloadButton.tooltip;"/>
642 + <toolbarbutton id="stop-button" class="toolbarbutton-1 chromeclass-toolbar-additional"
643 + label="&stopCmd.label;" removable="true"
644 + command="Browser:Stop"
645 + tooltiptext="&stopButton.tooltip;"/>
647 + <toolbaritem id="search-container" title="&searchItem.title;"
648 + align="center" class="chromeclass-toolbar-additional"
649 + flex="100" persist="width" removable="true">
650 + <searchbar id="searchbar" flex="1"/>
653 + <toolbarbutton id="home-button" class="toolbarbutton-1 chromeclass-toolbar-additional"
654 + persist="class" removable="true"
655 + label="&homeButton.label;"
656 + ondragover="homeButtonObserver.onDragOver(event)"
657 + ondragenter="homeButtonObserver.onDragOver(event)"
658 + ondrop="homeButtonObserver.onDrop(event)"
659 + ondragexit="homeButtonObserver.onDragExit(event)"
660 + onclick="BrowserGoHome(event);"
661 + aboutHomeOverrideTooltip="&abouthome.pageTitle;"/>
663 + <toolbaritem id="bookmarks-menu-button-container"
664 + class="chromeclass-toolbar-additional"
666 + title="&bookmarksMenuButton.label;">
667 + <toolbarbutton id="bookmarks-menu-button"
669 + class="toolbarbutton-1"
670 + label="&bookmarksMenuButton.label;"
671 + tooltiptext="&bookmarksMenuButton.tooltip;"
672 + ondragenter="PlacesMenuDNDHandler.onDragEnter(event);"
673 + ondragover="PlacesMenuDNDHandler.onDragOver(event);"
674 + ondragexit="PlacesMenuDNDHandler.onDragExit(event);"
675 + ondrop="PlacesMenuDNDHandler.onDrop(event);">
676 + <menupopup id="BMB_bookmarksPopup"
678 + context="placesContext"
679 + openInTabs="children"
680 + oncommand="BookmarksEventHandler.onCommand(event, this.parentNode._placesView);"
681 + onclick="BookmarksEventHandler.onClick(event, this.parentNode._placesView);"
682 + onpopupshowing="BookmarksMenuButton.onPopupShowing(event);
683 + if (!this.parentNode._placesView)
684 + new PlacesMenu(event, 'place:folder=BOOKMARKS_MENU');"
685 + tooltip="bhTooltip" popupsinherittooltip="true">
686 + <menuitem id="BMB_viewBookmarksToolbar"
687 + placesanonid="view-toolbar"
688 + toolbarId="PersonalToolbar"
690 + oncommand="onViewToolbarCommand(event)"
691 + label="&viewBookmarksToolbar.label;"/>
693 + <menuitem id="BMB_bookmarksShowAll"
694 + label="&showAllBookmarks2.label;"
695 + command="Browser:ShowAllBookmarks"
696 + key="manBookmarkKb"/>
698 + <menuitem id="BMB_bookmarkThisPage"
700 + class="menuitem-iconic"
702 + label="&bookmarkThisPageCmd.label;"
703 + command="Browser:AddBookmarkAs"
704 + key="addBookmarkAsKb"/>
705 + <menuitem id="BMB_subscribeToPageMenuitem"
707 + class="menuitem-iconic"
709 + label="&subscribeToPageMenuitem.label;"
710 + oncommand="return FeedHandler.subscribeToFeed(null, event);"
711 + onclick="checkForMiddleClick(this, event);"
712 + observes="singleFeedMenuitemState"/>
713 + <menu id="BMB_subscribeToPageMenupopup"
715 + class="menu-iconic"
717 + label="&subscribeToPageMenupopup.label;"
718 + observes="multipleFeedsMenuState">
719 + <menupopup id="BMB_subscribeToPageSubmenuMenupopup"
720 + onpopupshowing="return FeedHandler.buildFeedList(event.target);"
721 + oncommand="return FeedHandler.subscribeToFeed(null, event);"
722 + onclick="checkForMiddleClick(this, event);"/>
725 + <menu id="BMB_bookmarksToolbar"
726 + placesanonid="toolbar-autohide"
727 + class="menu-iconic bookmark-item"
728 + label="&personalbarCmd.label;"
730 + <menupopup id="BMB_bookmarksToolbarPopup"
732 + context="placesContext"
733 + onpopupshowing="if (!this.parentNode._placesView)
734 + new PlacesMenu(event, 'place:folder=TOOLBAR');"/>
737 + <!-- Bookmarks menu items -->
738 + <menuseparator builder="end"
739 + class="hide-if-empty-places-result"/>
740 + <menuitem id="BMB_unsortedBookmarks"
741 + label="&bookmarksMenuButton.unsorted.label;"
742 + oncommand="PlacesCommandHook.showPlacesOrganizer('UnfiledBookmarks');"
743 + class="menuitem-iconic"/>
748 + <hbox id="fullscreenflex" flex="1" hidden="true" fullscreencontrol="true"/>
749 + <hbox id="window-controls" hidden="true" fullscreencontrol="true">
750 + <toolbarbutton id="minimize-button"
751 + tooltiptext="&fullScreenMinimize.tooltip;"
752 + oncommand="window.minimize();"/>
754 + <toolbarbutton id="restore-button"
755 + tooltiptext="&fullScreenRestore.tooltip;"
756 + oncommand="BrowserFullScreen();"/>
758 + <toolbarbutton id="close-button"
759 + tooltiptext="&fullScreenClose.tooltip;"
760 + oncommand="BrowserTryToCloseWindow();"/>
764 + <toolbarset id="customToolbars" context="toolbar-context-menu"/>
766 + <toolbar id="PersonalToolbar"
767 + mode="icons" iconsize="small" defaulticonsize="small"
768 + lockiconsize="true"
769 + class="chromeclass-directories"
770 + context="toolbar-context-menu"
771 + defaultset="personal-bookmarks"
772 + toolbarname="&personalbarCmd.label;" accesskey="&personalbarCmd.accesskey;"
774 + customizable="true">
775 + <toolbaritem flex="1" id="personal-bookmarks" title="&bookmarksItem.title;"
779 + context="placesContext"
780 + onclick="BookmarksEventHandler.onClick(event, this._placesView);"
781 + oncommand="BookmarksEventHandler.onCommand(event, this._placesView);"
782 + tooltip="bhTooltip"
783 + popupsinherittooltip="true">
784 + <toolbarbutton class="bookmark-item bookmarks-toolbar-customize"
785 + mousethrough="never"
786 + label="&bookmarksToolbarItem.label;"/>
788 + <hbox align="center">
789 + <image id="PlacesToolbarDropIndicator"
790 + mousethrough="always"
793 + <scrollbox orient="horizontal"
794 + id="PlacesToolbarItems"
796 + <toolbarbutton type="menu"
799 + mousethrough="never"
801 + tooltiptext="&bookmarksToolbarChevron.tooltip;"
802 + onpopupshowing="document.getElementById('PlacesToolbar')
803 + ._placesView._onChevronPopupShowing(event);">
804 + <menupopup id="PlacesChevronPopup"
806 + tooltip="bhTooltip" popupsinherittooltip="true"
807 + context="placesContext"/>
814 +#ifdef MENUBAR_CAN_AUTOHIDE
815 +#ifndef CAN_DRAW_IN_TITLEBAR
816 +#define APPMENU_ON_TABBAR
821 + <toolbar id="TabsToolbar"
822 + class="toolbar-primary"
823 + fullscreentoolbar="true"
824 + customizable="true"
825 + mode="icons" lockmode="true"
826 + iconsize="small" defaulticonsize="small" lockiconsize="true"
827 + aria-label="&tabsToolbar.label;"
828 + context="toolbar-context-menu"
829 +#ifdef APPMENU_ON_TABBAR
830 + defaultset="appmenu-toolbar-button,tabbrowser-tabs,new-tab-button,alltabs-button,tabs-closebutton"
832 + defaultset="tabbrowser-tabs,new-tab-button,alltabs-button,tabs-closebutton"
836 +#ifdef APPMENU_ON_TABBAR
837 + <toolbarbutton id="appmenu-toolbar-button"
838 + class="chromeclass-toolbar-additional"
840 + label="&brandShortName;"
841 + tooltiptext="&appMenuButton.tooltip;">
842 +#include browser-appmenu.inc
846 + <tabs id="tabbrowser-tabs"
847 + class="tabbrowser-tabs"
848 + tabbrowser="content"
851 + tooltip="tabbrowser-tab-tooltip">
852 + <tab class="tabbrowser-tab" selected="true" fadein="true"/>
855 + <toolbarbutton id="new-tab-button"
856 + class="toolbarbutton-1 chromeclass-toolbar-additional"
857 + label="&tabCmd.label;"
858 + command="cmd_newNavigatorTab"
859 + onclick="checkForMiddleClick(this, event);"
860 + tooltiptext="&newTabButton.tooltip;"
861 + ondrop="newTabButtonObserver.onDrop(event)"
862 + ondragover="newTabButtonObserver.onDragOver(event)"
863 + ondragenter="newTabButtonObserver.onDragOver(event)"
864 + ondragexit="newTabButtonObserver.onDragExit(event)"
867 + <toolbarbutton id="alltabs-button"
868 + class="toolbarbutton-1 chromeclass-toolbar-additional tabs-alltabs-button"
870 + label="&listAllTabs.label;"
871 + tooltiptext="&listAllTabs.label;"
873 + <menupopup id="alltabs-popup"
874 + position="after_end">
875 + <menuitem id="menu_tabview"
876 + class="menuitem-iconic"
878 + label="&viewTabGroups.label;"
879 + command="Browser:ToggleTabView"
880 + observes="tabviewGroupsNumber"
882 + <menuseparator id="alltabs-popup-separator" keepme="true"/>
886 + <toolbarbutton id="tabs-closebutton"
887 + class="close-button tabs-closebutton"
888 + command="cmd_close"
889 + label="&closeTab.label;"
890 + tooltiptext="&closeTab.label;"/>
892 +#ifdef CAN_DRAW_IN_TITLEBAR
893 + <hbox class="titlebar-placeholder" type="appmenu-button" ordinal="0"/>
894 + <hbox class="titlebar-placeholder" type="caption-buttons" ordinal="1000"/>
898 + <toolbarpalette id="BrowserToolbarPalette">
900 +# Update primaryToolbarButtons in browser/themes/browserShared.inc when adding
901 +# or removing default items with the toolbarbutton-1 class.
903 + <toolbarbutton id="print-button" class="toolbarbutton-1 chromeclass-toolbar-additional"
904 + label="&printButton.label;" command="cmd_print"
905 + tooltiptext="&printButton.tooltip;"/>
907 + <toolbaritem id="navigator-throbber" title="&throbberItem.title;" align="center" pack="center"
908 + mousethrough="always">
912 + <toolbarbutton id="downloads-button" class="toolbarbutton-1 chromeclass-toolbar-additional"
913 + observes="Tools:Downloads"
914 + ondrop="DownloadsButtonDNDObserver.onDrop(event)"
915 + ondragover="DownloadsButtonDNDObserver.onDragOver(event)"
916 + ondragenter="DownloadsButtonDNDObserver.onDragOver(event)"
917 + ondragexit="DownloadsButtonDNDObserver.onDragExit(event)"
918 + label="&downloads.label;"
919 + tooltiptext="&downloads.tooltip;"/>
921 + <toolbarbutton id="history-button" class="toolbarbutton-1 chromeclass-toolbar-additional"
922 + observes="viewHistorySidebar" label="&historyButton.label;"
923 + tooltiptext="&historyButton.tooltip;"/>
925 + <toolbarbutton id="bookmarks-button" class="toolbarbutton-1 chromeclass-toolbar-additional"
926 + observes="viewBookmarksSidebar"
927 + tooltiptext="&bookmarksButton.tooltip;"
928 + ondrop="bookmarksButtonObserver.onDrop(event)"
929 + ondragover="bookmarksButtonObserver.onDragOver(event)"
930 + ondragenter="bookmarksButtonObserver.onDragOver(event)"
931 + ondragexit="bookmarksButtonObserver.onDragExit(event)"/>
933 + <toolbarbutton id="new-window-button" class="toolbarbutton-1 chromeclass-toolbar-additional"
934 + label="&newNavigatorCmd.label;"
935 + command="key_newNavigator"
936 + tooltiptext="&newWindowButton.tooltip;"
937 + ondrop="newWindowButtonObserver.onDrop(event)"
938 + ondragover="newWindowButtonObserver.onDragOver(event)"
939 + ondragenter="newWindowButtonObserver.onDragOver(event)"
940 + ondragexit="newWindowButtonObserver.onDragExit(event)"/>
942 + <toolbarbutton id="cut-button" class="toolbarbutton-1 chromeclass-toolbar-additional"
943 + label="&cutCmd.label;"
945 + tooltiptext="&cutButton.tooltip;"/>
947 + <toolbarbutton id="copy-button" class="toolbarbutton-1 chromeclass-toolbar-additional"
948 + label="©Cmd.label;"
950 + tooltiptext="©Button.tooltip;"/>
952 + <toolbarbutton id="paste-button" class="toolbarbutton-1 chromeclass-toolbar-additional"
953 + label="&pasteCmd.label;"
954 + command="cmd_paste"
955 + tooltiptext="&pasteButton.tooltip;"/>
957 + <toolbarbutton id="fullscreen-button" class="toolbarbutton-1 chromeclass-toolbar-additional"
958 + observes="View:FullScreen"
960 + label="&fullScreenCmd.label;"
961 + tooltiptext="&fullScreenButton.tooltip;"/>
963 + <toolbaritem id="zoom-controls" class="chromeclass-toolbar-additional"
964 + title="&zoomControls.label;">
965 + <toolbarbutton id="zoom-out-button" class="toolbarbutton-1"
966 + label="&fullZoomReduceCmd.label;"
967 + command="cmd_fullZoomReduce"
968 + tooltiptext="&zoomOutButton.tooltip;"/>
969 + <toolbarbutton id="zoom-in-button" class="toolbarbutton-1"
970 + label="&fullZoomEnlargeCmd.label;"
971 + command="cmd_fullZoomEnlarge"
972 + tooltiptext="&zoomInButton.tooltip;"/>
974 +#ifdef MOZ_SERVICES_SYNC
975 + <toolbarbutton id="sync-button"
976 + class="toolbarbutton-1 chromeclass-toolbar-additional"
977 + label="&syncToolbarButton.label;"
978 + oncommand="gSyncUI.handleToolbarButton()"/>
980 + <toolbarbutton id="feed-button"
982 + class="toolbarbutton-1 chromeclass-toolbar-additional"
984 + label="&feedButton.label;"
985 + tooltiptext="&feedButton.tooltip;"
986 + onclick="return FeedHandler.onFeedButtonClick(event);">
987 + <menupopup position="after_end"
989 + onpopupshowing="return FeedHandler.buildFeedList(this);"
990 + oncommand="return FeedHandler.subscribeToFeed(null, event);"
991 + onclick="checkForMiddleClick(this, event);"/>
994 + <toolbarbutton id="tabview-button" class="toolbarbutton-1 chromeclass-toolbar-additional"
995 + label="&tabGroupsButton.label;"
996 + command="Browser:ToggleTabView"
997 + tooltiptext="&tabGroupsButton.tooltip;"
998 + observes="tabviewGroupsNumber"/>
1002 + <hbox flex="1" id="browser">
1003 + <vbox id="browser-border-start" hidden="true" layer="true"/>
1004 + <vbox id="sidebar-box" hidden="true" class="chromeclass-extrachrome">
1005 + <sidebarheader id="sidebar-header" align="center">
1006 + <label id="sidebar-title" persist="value" flex="1" crop="end" control="sidebar"/>
1007 + <image id="sidebar-throbber"/>
1008 + <toolbarbutton class="tabs-closebutton" tooltiptext="&sidebarCloseButton.tooltip;" oncommand="toggleSidebar();"/>
1010 + <browser id="sidebar" flex="1" autoscroll="false" disablehistory="true"
1011 + style="min-width: 14em; width: 18em; max-width: 36em;"/>
1014 + <splitter id="sidebar-splitter" class="chromeclass-extrachrome" hidden="true"/>
1015 + <vbox id="appcontent" flex="1">
1016 + <tabbrowser id="content" disablehistory="true"
1017 + flex="1" contenttooltip="aHTMLTooltip"
1018 + tabcontainer="tabbrowser-tabs"
1019 + contentcontextmenu="contentAreaContextMenu"
1020 + autocompletepopup="PopupAutoComplete"
1021 + onclick="return contentAreaClick(event, false);"/>
1022 + <statuspanel id="statusbar-display" label=""/>
1024 + <vbox id="browser-border-end" hidden="true" layer="true"/>
1027 + <vbox id="browser-bottombox" layer="true">
1028 + <toolbar id="addon-bar"
1029 + toolbarname="&addonBarCmd.label;" accesskey="&addonBarCmd.accesskey;"
1031 + class="toolbar-primary chromeclass-toolbar"
1032 + context="toolbar-context-menu" toolboxid="navigator-toolbox"
1033 + mode="icons" iconsize="small" defaulticonsize="small"
1034 + lockiconsize="true"
1035 + defaultset="addonbar-closebutton,spring,status-bar"
1036 + customizable="true"
1037 + key="key_toggleAddonBar">
1038 + <toolbarbutton id="addonbar-closebutton"
1039 + tooltiptext="&addonBarCloseButton.tooltip;"
1040 + oncommand="setToolbarVisibility(this.parentNode, false);"/>
1041 + <statusbar id="status-bar" ordinal="1000"/>
1046 + <svg:svg height="0">
1047 + <svg:mask id="winstripe-keyhole-forward-mask" maskContentUnits="objectBoundingBox">
1048 + <svg:rect x="0" y="0" width="1" height="1" fill="white"/>
1049 + <svg:circle cx="-0.46" cy="0.5" r="0.63"/>
1051 + <svg:mask id="winstripe-keyhole-forward-mask-hover" maskContentUnits="objectBoundingBox">
1052 + <svg:rect x="0" y="0" width="1" height="1" fill="white"/>
1053 + <svg:circle cx="-0.35" cy="0.5" r="0.58"/>
1058 + <svg:svg height="0">
1059 + <svg:mask id="pinstripe-keyhole-forward-mask" maskContentUnits="objectBoundingBox">
1060 + <svg:rect x="0" y="0" width="1" height="1" fill="white"/>
1061 + <svg:circle cx="-0.46" cy="0.48" r="0.65"/>
1063 + <svg:mask id="pinstripe-tab-ontop-left-curve-mask" maskContentUnits="userSpaceOnUse">
1064 + <svg:circle cx="9" cy="3" r="3" fill="white"/>
1065 + <svg:rect x="9" y="0" width="3" height="3" fill="white"/>
1066 + <svg:rect x="6" y="3" width="6" height="19" fill="white"/>
1067 + <svg:rect x="1" y="17" width="5" height="5" fill="white"/>
1068 + <svg:circle cx="1" cy="17" r="5"/>
1069 + <svg:rect x="0" y="22" width="12" height="1" fill="white"/>
1071 + <svg:mask id="pinstripe-tab-ontop-right-curve-mask" maskContentUnits="userSpaceOnUse">
1072 + <svg:circle cx="3" cy="3" r="3" fill="white"/>
1073 + <svg:rect x="0" y="0" width="3" height="3" fill="white"/>
1074 + <svg:rect x="0" y="3" width="6" height="19" fill="white"/>
1075 + <svg:rect x="6" y="17" width="5" height="5" fill="white"/>
1076 + <svg:circle cx="11" cy="17" r="5"/>
1077 + <svg:rect x="0" y="22" width="12" height="1" fill="white"/>
1079 + <svg:mask id="pinstripe-tab-onbottom-left-curve-mask" maskContentUnits="userSpaceOnUse">
1080 + <svg:circle cx="9" cy="20" r="3" fill="white"/>
1081 + <svg:rect x="9" y="20" width="3" height="3" fill="white"/>
1082 + <svg:rect x="6" y="1" width="6" height="19" fill="white"/>
1083 + <svg:rect x="1" y="1" width="5" height="5" fill="white"/>
1084 + <svg:circle cx="1" cy="6" r="5"/>
1085 + <svg:rect x="0" y="0" width="12" height="1" fill="white"/>
1087 + <svg:mask id="pinstripe-tab-onbottom-right-curve-mask" maskContentUnits="userSpaceOnUse">
1088 + <svg:circle cx="3" cy="20" r="3" fill="white"/>
1089 + <svg:rect x="0" y="20" width="3" height="3" fill="white"/>
1090 + <svg:rect x="0" y="1" width="6" height="19" fill="white"/>
1091 + <svg:rect x="6" y="1" width="5" height="5" fill="white"/>
1092 + <svg:circle cx="11" cy="6" r="5"/>
1093 + <svg:rect x="0" y="0" width="12" height="1" fill="white"/>
1099 +# <iframe id="tab-view"> is dynamically appended as the 2nd child of #tab-view-deck.
1100 +# Introducing the iframe dynamically, as needed, was found to be better than
1101 +# starting with an empty iframe here in browser.xul from a Ts standpoint.
1105 diff --git a/browser/base/jar.mn b/browser/base/jar.mn
1106 --- a/browser/base/jar.mn
1107 +++ b/browser/base/jar.mn
1108 @@ -22,16 +22,18 @@ browser.jar:
1109 * content/browser/aboutHome.css (content/aboutHome.css)
1110 content/browser/aboutHome-restore-icon.png (content/aboutHome-restore-icon.png)
1111 content/browser/aboutHome-restore-icon-small.png (content/aboutHome-restore-icon-small.png)
1112 content/browser/aboutRobots-icon.png (content/aboutRobots-icon.png)
1113 content/browser/aboutRobots-widget-left.png (content/aboutRobots-widget-left.png)
1114 * content/browser/browser.css (content/browser.css)
1115 * content/browser/browser.js (content/browser.js)
1116 * content/browser/browser.xul (content/browser.xul)
1117 +* content/browser/browser-kde.xul (content/browser-kde.xul)
1118 +% override chrome://browser/content/browser.xul chrome://browser/content/browser-kde.xul desktop=kde
1119 * content/browser/browser-tabPreviews.xml (content/browser-tabPreviews.xml)
1120 * content/browser/fullscreen-video.xhtml (content/fullscreen-video.xhtml)
1121 * content/browser/inspector.html (content/inspector.html)
1122 * content/browser/pageinfo/pageInfo.xul (content/pageinfo/pageInfo.xul)
1123 * content/browser/pageinfo/pageInfo.js (content/pageinfo/pageInfo.js)
1124 * content/browser/pageinfo/pageInfo.css (content/pageinfo/pageInfo.css)
1125 * content/browser/pageinfo/pageInfo.xml (content/pageinfo/pageInfo.xml)
1126 * content/browser/pageinfo/feeds.js (content/pageinfo/feeds.js)
1127 diff --git a/browser/components/build/nsModule.cpp b/browser/components/build/nsModule.cpp
1128 --- a/browser/components/build/nsModule.cpp
1129 +++ b/browser/components/build/nsModule.cpp
1131 #include "nsBrowserCompsCID.h"
1132 #include "DirectoryProvider.h"
1135 #include "nsWindowsShellService.h"
1136 #elif defined(XP_MACOSX)
1137 #include "nsMacShellService.h"
1138 #elif defined(MOZ_WIDGET_GTK2)
1139 -#include "nsGNOMEShellService.h"
1140 +#include "nsUnixShellService.h"
1145 #include "nsProfileMigrator.h"
1146 #include "nsDogbertProfileMigrator.h"
1147 #if !defined(XP_OS2)
1148 #include "nsOperaProfileMigrator.h"
1149 @@ -82,18 +82,16 @@ using namespace mozilla::browser;
1151 /////////////////////////////////////////////////////////////////////////////
1153 NS_GENERIC_FACTORY_CONSTRUCTOR(DirectoryProvider)
1155 NS_GENERIC_FACTORY_CONSTRUCTOR(nsWindowsShellService)
1156 #elif defined(XP_MACOSX)
1157 NS_GENERIC_FACTORY_CONSTRUCTOR(nsMacShellService)
1158 -#elif defined(MOZ_WIDGET_GTK2)
1159 -NS_GENERIC_FACTORY_CONSTRUCTOR_INIT(nsGNOMEShellService, Init)
1164 NS_GENERIC_FACTORY_CONSTRUCTOR(nsDogbertProfileMigrator)
1165 #if !defined(XP_OS2)
1166 NS_GENERIC_FACTORY_CONSTRUCTOR(nsOperaProfileMigrator)
1168 @@ -145,17 +143,17 @@ NS_DEFINE_NAMED_CID(NS_SEAMONKEYPROFILEM
1170 NS_DEFINE_NAMED_CID(NS_PRIVATE_BROWSING_SERVICE_WRAPPER_CID);
1172 static const mozilla::Module::CIDEntry kBrowserCIDs[] = {
1173 { &kNS_BROWSERDIRECTORYPROVIDER_CID, false, NULL, DirectoryProviderConstructor },
1175 { &kNS_SHELLSERVICE_CID, false, NULL, nsWindowsShellServiceConstructor },
1176 #elif defined(MOZ_WIDGET_GTK2)
1177 - { &kNS_SHELLSERVICE_CID, false, NULL, nsGNOMEShellServiceConstructor },
1178 + { &kNS_SHELLSERVICE_CID, false, NULL, nsUnixShellServiceConstructor },
1180 { &kNS_FEEDSNIFFER_CID, false, NULL, nsFeedSnifferConstructor },
1181 { &kNS_BROWSER_ABOUT_REDIRECTOR_CID, false, NULL, AboutRedirector::Create },
1183 { &kNS_FIREFOX_PROFILEMIGRATOR_CID, false, NULL, nsProfileMigratorConstructor },
1184 #if defined(XP_WIN) && !defined(__MINGW32__)
1185 { &kNS_WINIEPROFILEMIGRATOR_CID, false, NULL, nsIEProfileMigratorConstructor },
1186 #elif defined(XP_MACOSX)
1187 diff --git a/browser/components/preferences/advanced.js b/browser/components/preferences/advanced.js
1188 --- a/browser/components/preferences/advanced.js
1189 +++ b/browser/components/preferences/advanced.js
1190 @@ -683,24 +683,42 @@ var gAdvancedPane = {
1191 var brandBundle = document.getElementById("bundleBrand");
1192 var shellBundle = document.getElementById("bundleShell");
1193 var brandShortName = brandBundle.getString("brandShortName");
1194 var promptTitle = shellBundle.getString("setDefaultBrowserTitle");
1196 const IPS = Components.interfaces.nsIPromptService;
1197 var psvc = Components.classes["@mozilla.org/embedcomp/prompt-service;1"]
1200 + var env = Components.classes["@mozilla.org/process/environment;1"]
1201 + .getService(Components.interfaces.nsIEnvironment);
1202 + var kde_session = 0;
1203 + if (env.get('KDE_FULL_SESSION') == "true")
1206 if (!shellSvc.isDefaultBrowser(false)) {
1207 promptMessage = shellBundle.getFormattedString("setDefaultBrowserMessage",
1209 var rv = psvc.confirmEx(window, promptTitle, promptMessage,
1210 IPS.STD_YES_NO_BUTTONS,
1211 null, null, null, null, { });
1214 shellSvc.setDefaultBrowser(true, false);
1215 + if (kde_session == 1) {
1216 + var shellObj = Components.classes["@mozilla.org/file/local;1"]
1217 + .createInstance(Components.interfaces.nsILocalFile);
1218 + shellObj.initWithPath("/usr/bin/kwriteconfig");
1219 + var process = Components.classes["@mozilla.org/process/util;1"]
1220 + .createInstance(Components.interfaces.nsIProcess);
1221 + process.init(shellObj);
1222 + var args = ["--file", "kdeglobals", "--group", "General", "--key", "BrowserApplication", "MozillaFirefox"];
1223 + process.run(false, args, args.length);
1228 promptMessage = shellBundle.getFormattedString("alreadyDefaultBrowser",
1230 psvc.alert(window, promptTitle, promptMessage);
1234 diff --git a/browser/components/shell/src/Makefile.in b/browser/components/shell/src/Makefile.in
1235 --- a/browser/components/shell/src/Makefile.in
1236 +++ b/browser/components/shell/src/Makefile.in
1237 @@ -52,17 +52,18 @@ endif
1239 ifneq (,$(filter WINCE WINNT,$(OS_ARCH)))
1240 CPPSRCS = nsWindowsShellService.cpp
1242 ifeq (cocoa,$(MOZ_WIDGET_TOOLKIT))
1243 CPPSRCS = nsMacShellService.cpp
1245 ifeq ($(MOZ_WIDGET_TOOLKIT), gtk2)
1246 -CPPSRCS = nsGNOMEShellService.cpp
1247 +CPPSRCS = nsUnixShellService.cpp nsGNOMEShellService.cpp nsKDEShellService.cpp
1248 +LOCAL_INCLUDES += -I$(topsrcdir)/toolkit/xre
1254 LIBRARY_NAME = shellservice_s
1257 diff --git a/browser/components/shell/src/nsKDEShellService.cpp b/browser/components/shell/src/nsKDEShellService.cpp
1258 new file mode 100644
1260 +++ b/browser/components/shell/src/nsKDEShellService.cpp
1262 +/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
1263 +/* ***** BEGIN LICENSE BLOCK *****
1264 + * Version: MPL 1.1/GPL 2.0/LGPL 2.1
1266 + * The contents of this file are subject to the Mozilla Public License Version
1267 + * 1.1 (the "License"); you may not use this file except in compliance with
1268 + * the License. You may obtain a copy of the License at
1269 + * http://www.mozilla.org/MPL/
1271 + * Software distributed under the License is distributed on an "AS IS" basis,
1272 + * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
1273 + * for the specific language governing rights and limitations under the
1276 + * The Original Code is Shell Service.
1278 + * The Initial Developer of the Original Code is mozilla.org.
1279 + * Portions created by the Initial Developer are Copyright (C) 2004
1280 + * the Initial Developer. All Rights Reserved.
1284 + * Alternatively, the contents of this file may be used under the terms of
1285 + * either the GNU General Public License Version 2 or later (the "GPL"), or
1286 + * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
1287 + * in which case the provisions of the GPL or the LGPL are applicable instead
1288 + * of those above. If you wish to allow use of your version of this file only
1289 + * under the terms of either the GPL or the LGPL, and not to allow others to
1290 + * use your version of this file under the terms of the MPL, indicate your
1291 + * decision by deleting the provisions above and replace them with the notice
1292 + * and other provisions required by the GPL or the LGPL. If you do not delete
1293 + * the provisions above, a recipient may use your version of this file under
1294 + * the terms of any one of the MPL, the GPL or the LGPL.
1296 + * ***** END LICENSE BLOCK ***** */
1298 +#include "nsKDEShellService.h"
1299 +#include "nsShellService.h"
1300 +#include "nsKDEUtils.h"
1301 +#include "nsCOMPtr.h"
1302 +#include "nsIPrefService.h"
1303 +#include "nsIProcess.h"
1304 +#include "nsILocalFile.h"
1305 +#include "nsServiceManagerUtils.h"
1306 +#include "nsComponentManagerUtils.h"
1309 +nsKDEShellService::Init()
1311 + if( !nsKDEUtils::kdeSupport())
1312 + return NS_ERROR_NOT_AVAILABLE;
1316 +NS_IMPL_ISUPPORTS1(nsKDEShellService, nsIShellService)
1319 +nsKDEShellService::IsDefaultBrowser(PRBool aStartupCheck,
1320 + PRBool* aIsDefaultBrowser)
1322 + *aIsDefaultBrowser = PR_FALSE;
1323 + if (aStartupCheck)
1324 + mCheckedThisSession = PR_TRUE;
1325 + nsCStringArray command;
1326 + command.AppendCString( NS_LITERAL_CSTRING( "ISDEFAULTBROWSER" ));
1327 + if( nsKDEUtils::command( command ))
1328 + *aIsDefaultBrowser = PR_TRUE;
1333 +nsKDEShellService::SetDefaultBrowser(PRBool aClaimAllTypes,
1334 + PRBool aForAllUsers)
1336 + nsCStringArray command;
1337 + command.AppendCString( NS_LITERAL_CSTRING( "SETDEFAULTBROWSER" ));
1338 + command.AppendCString( aClaimAllTypes ? NS_LITERAL_CSTRING( "ALLTYPES" ) : NS_LITERAL_CSTRING( "NORMAL" ));
1339 + return nsKDEUtils::command( command ) ? NS_OK : NS_ERROR_FAILURE;
1343 +nsKDEShellService::GetShouldCheckDefaultBrowser(PRBool* aResult)
1345 + // If we've already checked, the browser has been started and this is a
1346 + // new window open, and we don't want to check again.
1347 + if (mCheckedThisSession) {
1348 + *aResult = PR_FALSE;
1352 + nsCOMPtr<nsIPrefBranch> prefs;
1353 + nsCOMPtr<nsIPrefService> pserve(do_GetService(NS_PREFSERVICE_CONTRACTID));
1355 + pserve->GetBranch("", getter_AddRefs(prefs));
1358 + prefs->GetBoolPref(PREF_CHECKDEFAULTBROWSER, aResult);
1364 +nsKDEShellService::SetShouldCheckDefaultBrowser(PRBool aShouldCheck)
1366 + nsCOMPtr<nsIPrefBranch> prefs;
1367 + nsCOMPtr<nsIPrefService> pserve(do_GetService(NS_PREFSERVICE_CONTRACTID));
1369 + pserve->GetBranch("", getter_AddRefs(prefs));
1372 + prefs->SetBoolPref(PREF_CHECKDEFAULTBROWSER, aShouldCheck);
1378 +nsKDEShellService::SetDesktopBackground(nsIDOMElement* aElement,
1379 + PRInt32 aPosition)
1381 + return NS_ERROR_NOT_IMPLEMENTED;
1385 +nsKDEShellService::GetDesktopBackgroundColor(PRUint32 *aColor)
1387 + return NS_ERROR_NOT_IMPLEMENTED;
1391 +nsKDEShellService::SetDesktopBackgroundColor(PRUint32 aColor)
1393 + return NS_ERROR_NOT_IMPLEMENTED;
1397 +nsKDEShellService::OpenApplication(PRInt32 aApplication)
1399 + nsCStringArray command;
1400 + if( aApplication == APPLICATION_MAIL )
1401 + command.AppendCString( NS_LITERAL_CSTRING( "OPENMAIL" ));
1402 + else if( aApplication == APPLICATION_NEWS )
1403 + command.AppendCString( NS_LITERAL_CSTRING( "OPENNEWS" ));
1405 + return NS_ERROR_NOT_IMPLEMENTED;
1406 + return nsKDEUtils::command( command ) ? NS_OK : NS_ERROR_FAILURE;
1410 +nsKDEShellService::OpenApplicationWithURI(nsILocalFile* aApplication, const nsACString& aURI)
1412 + nsCStringArray command;
1413 + command.AppendCString( NS_LITERAL_CSTRING( "RUN" ));
1415 + nsresult rv = aApplication->GetNativePath( app );
1416 + NS_ENSURE_SUCCESS( rv, rv );
1417 + command.AppendCString( app );
1418 + command.AppendCString( aURI );
1419 + return nsKDEUtils::command( command ) ? NS_OK : NS_ERROR_FAILURE;
1423 +nsKDEShellService::GetDefaultFeedReader(nsILocalFile** _retval)
1425 + *_retval = nsnull;
1427 + nsCStringArray command;
1428 + command.AppendCString( NS_LITERAL_CSTRING( "GETDEFAULTFEEDREADER" ));
1429 + nsCStringArray output;
1430 + if( !nsKDEUtils::command( command, &output ) || output.Count() != 1 )
1431 + return NS_ERROR_FAILURE;
1434 + path = *output[ 0 ];
1435 + if (path.IsEmpty())
1436 + return NS_ERROR_FAILURE;
1439 + nsCOMPtr<nsILocalFile> defaultReader =
1440 + do_CreateInstance("@mozilla.org/file/local;1", &rv);
1441 + NS_ENSURE_SUCCESS(rv, rv);
1443 + rv = defaultReader->InitWithNativePath(path);
1444 + NS_ENSURE_SUCCESS(rv, rv);
1447 + rv = defaultReader->Exists(&exists);
1448 + NS_ENSURE_SUCCESS(rv, rv);
1450 + return NS_ERROR_FAILURE;
1452 + NS_ADDREF(*_retval = defaultReader);
1455 diff --git a/browser/components/shell/src/nsKDEShellService.h b/browser/components/shell/src/nsKDEShellService.h
1456 new file mode 100644
1458 +++ b/browser/components/shell/src/nsKDEShellService.h
1460 +/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
1461 +/* ***** BEGIN LICENSE BLOCK *****
1462 + * Version: MPL 1.1/GPL 2.0/LGPL 2.1
1464 + * The contents of this file are subject to the Mozilla Public License Version
1465 + * 1.1 (the "License"); you may not use this file except in compliance with
1466 + * the License. You may obtain a copy of the License at
1467 + * http://www.mozilla.org/MPL/
1469 + * Software distributed under the License is distributed on an "AS IS" basis,
1470 + * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
1471 + * for the specific language governing rights and limitations under the
1474 + * The Original Code is Shell Service.
1476 + * The Initial Developer of the Original Code is mozilla.org.
1477 + * Portions created by the Initial Developer are Copyright (C) 2004
1478 + * the Initial Developer. All Rights Reserved.
1482 + * Alternatively, the contents of this file may be used under the terms of
1483 + * either the GNU General Public License Version 2 or later (the "GPL"), or
1484 + * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
1485 + * in which case the provisions of the GPL or the LGPL are applicable instead
1486 + * of those above. If you wish to allow use of your version of this file only
1487 + * under the terms of either the GPL or the LGPL, and not to allow others to
1488 + * use your version of this file under the terms of the MPL, indicate your
1489 + * decision by deleting the provisions above and replace them with the notice
1490 + * and other provisions required by the GPL or the LGPL. If you do not delete
1491 + * the provisions above, a recipient may use your version of this file under
1492 + * the terms of any one of the MPL, the GPL or the LGPL.
1494 + * ***** END LICENSE BLOCK ***** */
1496 +#ifndef nskdeshellservice_h____
1497 +#define nskdeshellservice_h____
1499 +#include "nsIShellService.h"
1500 +#include "nsStringAPI.h"
1502 +class nsKDEShellService : public nsIShellService
1505 + nsKDEShellService() : mCheckedThisSession(PR_FALSE) { }
1508 + NS_DECL_NSISHELLSERVICE
1510 + nsresult Init() NS_HIDDEN;
1513 + ~nsKDEShellService() {}
1515 + PRPackedBool mCheckedThisSession;
1518 +#endif // nskdeshellservice_h____
1519 diff --git a/browser/components/shell/src/nsUnixShellService.cpp b/browser/components/shell/src/nsUnixShellService.cpp
1520 new file mode 100644
1522 +++ b/browser/components/shell/src/nsUnixShellService.cpp
1524 +/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
1525 +/* ***** BEGIN LICENSE BLOCK *****
1526 + * Version: MPL 1.1/GPL 2.0/LGPL 2.1
1528 + * The contents of this file are subject to the Mozilla Public License Version
1529 + * 1.1 (the "License"); you may not use this file except in compliance with
1530 + * the License. You may obtain a copy of the License at
1531 + * http://www.mozilla.org/MPL/
1533 + * Software distributed under the License is distributed on an "AS IS" basis,
1534 + * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
1535 + * for the specific language governing rights and limitations under the
1538 + * The Original Code is Shell Service.
1540 + * The Initial Developer of the Original Code is mozilla.org.
1541 + * Portions created by the Initial Developer are Copyright (C) 2004
1542 + * the Initial Developer. All Rights Reserved.
1546 + * Alternatively, the contents of this file may be used under the terms of
1547 + * either the GNU General Public License Version 2 or later (the "GPL"), or
1548 + * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
1549 + * in which case the provisions of the GPL or the LGPL are applicable instead
1550 + * of those above. If you wish to allow use of your version of this file only
1551 + * under the terms of either the GPL or the LGPL, and not to allow others to
1552 + * use your version of this file under the terms of the MPL, indicate your
1553 + * decision by deleting the provisions above and replace them with the notice
1554 + * and other provisions required by the GPL or the LGPL. If you do not delete
1555 + * the provisions above, a recipient may use your version of this file under
1556 + * the terms of any one of the MPL, the GPL or the LGPL.
1558 + * ***** END LICENSE BLOCK ***** */
1560 +#include "nsUnixShellService.h"
1561 +#include "nsGNOMEShellService.h"
1562 +#include "nsKDEShellService.h"
1563 +#include "nsKDEUtils.h"
1564 +#include "mozilla/ModuleUtils.h"
1566 +NS_GENERIC_FACTORY_CONSTRUCTOR_INIT(nsGNOMEShellService, Init)
1567 +NS_GENERIC_FACTORY_CONSTRUCTOR_INIT(nsKDEShellService, Init)
1570 +nsUnixShellServiceConstructor(nsISupports *aOuter, REFNSIID aIID, void **aResult)
1572 + if( nsKDEUtils::kdeSupport())
1573 + return nsKDEShellServiceConstructor( aOuter, aIID, aResult );
1574 + return nsGNOMEShellServiceConstructor( aOuter, aIID, aResult );
1576 diff --git a/browser/components/shell/src/nsUnixShellService.h b/browser/components/shell/src/nsUnixShellService.h
1577 new file mode 100644
1579 +++ b/browser/components/shell/src/nsUnixShellService.h
1581 +/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
1582 +/* ***** BEGIN LICENSE BLOCK *****
1583 + * Version: MPL 1.1/GPL 2.0/LGPL 2.1
1585 + * The contents of this file are subject to the Mozilla Public License Version
1586 + * 1.1 (the "License"); you may not use this file except in compliance with
1587 + * the License. You may obtain a copy of the License at
1588 + * http://www.mozilla.org/MPL/
1590 + * Software distributed under the License is distributed on an "AS IS" basis,
1591 + * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
1592 + * for the specific language governing rights and limitations under the
1595 + * The Original Code is Shell Service.
1597 + * The Initial Developer of the Original Code is mozilla.org.
1598 + * Portions created by the Initial Developer are Copyright (C) 2004
1599 + * the Initial Developer. All Rights Reserved.
1603 + * Alternatively, the contents of this file may be used under the terms of
1604 + * either the GNU General Public License Version 2 or later (the "GPL"), or
1605 + * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
1606 + * in which case the provisions of the GPL or the LGPL are applicable instead
1607 + * of those above. If you wish to allow use of your version of this file only
1608 + * under the terms of either the GPL or the LGPL, and not to allow others to
1609 + * use your version of this file under the terms of the MPL, indicate your
1610 + * decision by deleting the provisions above and replace them with the notice
1611 + * and other provisions required by the GPL or the LGPL. If you do not delete
1612 + * the provisions above, a recipient may use your version of this file under
1613 + * the terms of any one of the MPL, the GPL or the LGPL.
1615 + * ***** END LICENSE BLOCK ***** */
1617 +#ifndef nsunixshellservice_h____
1618 +#define nsunixshellservice_h____
1620 +#include "nsIShellService.h"
1623 +nsUnixShellServiceConstructor(nsISupports *aOuter, REFNSIID aIID, void **aResult);
1625 +#endif // nsunixshellservice_h____
1626 diff --git a/browser/installer/package-manifest.in b/browser/installer/package-manifest.in
1627 --- a/browser/installer/package-manifest.in
1628 +++ b/browser/installer/package-manifest.in
1629 @@ -442,16 +442,17 @@
1633 ; [Default Preferences]
1634 ; All the pref files must be part of base to prevent migration bugs
1635 @BINPATH@/@PREF_DIR@/firefox.js
1636 @BINPATH@/@PREF_DIR@/firefox-branding.js
1637 @BINPATH@/@PREF_DIR@/channel-prefs.js
1638 +@BINPATH@/@PREF_DIR@/kde.js
1639 #ifdef MOZ_SERVICES_SYNC
1640 @BINPATH@/@PREF_DIR@/services-sync.js
1642 @BINPATH@/greprefs.js
1643 @BINPATH@/defaults/autoconfig/platform.js
1644 @BINPATH@/defaults/autoconfig/prefcalls.js
1645 @BINPATH@/defaults/profile/prefs.js