--- a/firefox-kde.patch Fri Dec 23 18:44:50 2011 +0100
+++ b/firefox-kde.patch Sun Dec 25 10:36:35 2011 +0100
@@ -2,7 +2,7 @@
new file mode 100644
--- /dev/null
+++ b/browser/base/content/browser-kde.xul
-@@ -0,0 +1,1054 @@
+@@ -0,0 +1,1111 @@
+#filter substitution
+<?xml version="1.0"?>
+# -*- Mode: HTML -*-
@@ -477,6 +477,7 @@
+
+ <toolbaritem id="unified-back-forward-button" class="chromeclass-toolbar-additional"
+ context="backForwardMenu" removable="true"
++ forwarddisabled="true"
+ title="&backForwardItem.title;">
+ <toolbarbutton id="back-button" class="toolbarbutton-1"
+ label="&backCmd.label;"
@@ -488,6 +489,13 @@
+ command="Browser:ForwardOrForwardDuplicate"
+ onclick="checkForMiddleClick(this, event);"
+ tooltip="forward-button-tooltip"/>
++ <dummyobservertarget hidden="true"
++ onbroadcast="if (this.getAttribute('disabled') == 'true')
++ this.parentNode.setAttribute('forwarddisabled', 'true');
++ else
++ this.parentNode.removeAttribute('forwarddisabled');">
++ <observes element="Browser:ForwardOrForwardDuplicate" attribute="disabled"/>
++ </dummyobservertarget>
+ </toolbaritem>
+
+ <toolbaritem id="urlbar-container" align="center" flex="400" persist="width" combined="true"
@@ -963,22 +971,63 @@
+ onclick="return contentAreaClick(event, false);"/>
+ <statuspanel id="statusbar-display" inactive="true"/>
+ </vbox>
++ <splitter id="devtools-side-splitter" hidden="true"/>
++ <vbox id="devtools-sidebar-box" hidden="true"
++ style="min-width: 18em; width: 22em; max-width: 42em;" persist="width">
++ <toolbar id="devtools-sidebar-toolbar" nowindowdrag="true"/>
++ <deck id="devtools-sidebar-deck" flex="1"/>
++ </vbox>
+ <vbox id="browser-border-end" hidden="true" layer="true"/>
+ </hbox>
+
++ <hbox id="full-screen-warning-container" hidden="true" fadeout="true">
++ <hbox style="min-width: 100%;" pack="center"> <!-- Inner hbox needed due to bug 579776. -->
++ <hbox id="full-screen-warning-message">
++ <description id="full-screen-warning-text" value="&domFullScreenWarning.label;"></description>
++ </hbox>
++ </hbox>
++ </hbox>
++
+ <vbox id="browser-bottombox" layer="true">
+ <toolbar id="inspector-toolbar"
+ nowindowdrag="true"
+ hidden="true">
-+ <toolbarbutton id="inspector-inspect-toolbutton"
-+ label="&inspectButton.label;"
-+ accesskey="&inspectButton.accesskey;"
-+ class="toolbarbutton-text"
-+ command="Inspector:Inspect"/>
-+ <toolbarseparator />
-+ <hbox id="inspector-tools">
-+ <!-- registered tools go here -->
-+ </hbox>
++ <vbox flex="1">
++ <resizer id="inspector-top-resizer" flex="1"
++ class="inspector-resizer"
++ dir="top" disabled="true"
++ element="inspector-tree-box"/>
++ <hbox>
++#ifdef XP_MACOSX
++ <toolbarbutton id="highlighter-closebutton"
++ oncommand="InspectorUI.closeInspectorUI(false);"
++ tooltiptext="&inspectCloseButton.tooltiptext;"/>
++#endif
++ <toolbarbutton id="inspector-inspect-toolbutton"
++ label="&inspectButton.label;"
++ accesskey="&inspectButton.accesskey;"
++ command="Inspector:Inspect"/>
++ <arrowscrollbox id="inspector-breadcrumbs"
++ flex="1" orient="horizontal"
++ clicktoscroll="true"/>
++ <hbox id="inspector-tools">
++ <toolbarbutton id="inspector-style-button"
++ label="&inspectStyleButton.label;"
++ accesskey="&inspectStyleButton.accesskey;"
++ command="Inspector:Sidebar"/>
++ <!-- registered tools go here -->
++ </hbox>
++#ifndef XP_MACOSX
++ <toolbarbutton id="highlighter-closebutton"
++ oncommand="InspectorUI.closeInspectorUI(false);"
++ tooltiptext="&inspectCloseButton.tooltiptext;"/>
++#endif
++ <resizer id="inspector-end-resizer"
++ class="inspector-resizer"
++ dir="top" disabled="true"
++ element="inspector-tree-box"/>
++ </hbox>
++ </vbox>
+ </toolbar>
+ <toolbar id="addon-bar"
+ toolbarname="&addonBarCmd.label;" accesskey="&addonBarCmd.accesskey;"
@@ -1007,6 +1056,10 @@
+ <svg:rect x="0" y="0" width="1" height="1" fill="white"/>
+ <svg:circle cx="-0.35" cy="0.5" r="0.58"/>
+ </svg:mask>
++ <svg:mask id="winstripe-urlbar-back-button-mask" maskContentUnits="userSpaceOnUse">
++ <svg:rect x="0" y="0" width="10000" height="50" fill="white"/>
++ <svg:circle cx="-11" cy="13" r="15"/>
++ </svg:mask>
+ </svg:svg>
+#endif
+#ifdef XP_MACOSX
@@ -1015,6 +1068,10 @@
+ <svg:rect x="0" y="0" width="1" height="1" fill="white"/>
+ <svg:circle cx="-0.41" cy="0.5" r="0.65"/>
+ </svg:mask>
++ <svg:mask id="pinstripe-urlbar-back-button-mask" maskContentUnits="userSpaceOnUse">
++ <svg:rect x="0" y="-5" width="10000" height="55" fill="white"/>
++ <svg:circle cx="-9" cy="11" r="15"/>
++ </svg:mask>
+ <svg:mask id="pinstripe-tab-ontop-left-curve-mask" maskContentUnits="userSpaceOnUse">
+ <svg:circle cx="9" cy="3" r="3" fill="white"/>
+ <svg:rect x="9" y="0" width="3" height="3" fill="white"/>
@@ -1142,7 +1199,7 @@
diff --git a/browser/components/preferences/advanced.js b/browser/components/preferences/advanced.js
--- a/browser/components/preferences/advanced.js
+++ b/browser/components/preferences/advanced.js
-@@ -683,24 +683,42 @@ var gAdvancedPane = {
+@@ -690,24 +690,42 @@ var gAdvancedPane = {
var brandBundle = document.getElementById("bundleBrand");
var shellBundle = document.getElementById("bundleShell");
var brandShortName = brandBundle.getString("brandShortName");
@@ -1271,33 +1328,33 @@
+NS_IMPL_ISUPPORTS1(nsKDEShellService, nsIShellService)
+
+NS_IMETHODIMP
-+nsKDEShellService::IsDefaultBrowser(PRBool aStartupCheck,
-+ PRBool* aIsDefaultBrowser)
++nsKDEShellService::IsDefaultBrowser(bool aStartupCheck,
++ bool* aIsDefaultBrowser)
+ {
+ *aIsDefaultBrowser = PR_FALSE;
+ if (aStartupCheck)
+ mCheckedThisSession = PR_TRUE;
-+ nsCStringArray command;
-+ command.AppendCString( NS_LITERAL_CSTRING( "ISDEFAULTBROWSER" ));
++ nsTArray<nsCString> command;
++ command.AppendElement( NS_LITERAL_CSTRING( "ISDEFAULTBROWSER" ));
+ if( nsKDEUtils::command( command ))
+ *aIsDefaultBrowser = PR_TRUE;
+ return NS_OK;
+ }
+
+NS_IMETHODIMP
-+nsKDEShellService::SetDefaultBrowser(PRBool aClaimAllTypes,
-+ PRBool aForAllUsers)
++nsKDEShellService::SetDefaultBrowser(bool aClaimAllTypes,
++ bool aForAllUsers)
+ {
-+ nsCStringArray command;
-+ command.AppendCString( NS_LITERAL_CSTRING( "SETDEFAULTBROWSER" ));
-+ command.AppendCString( aClaimAllTypes ? NS_LITERAL_CSTRING( "ALLTYPES" ) : NS_LITERAL_CSTRING( "NORMAL" ));
++ nsTArray<nsCString> command;
++ command.AppendElement( NS_LITERAL_CSTRING( "SETDEFAULTBROWSER" ));
++ command.AppendElement( aClaimAllTypes ? NS_LITERAL_CSTRING( "ALLTYPES" ) : NS_LITERAL_CSTRING( "NORMAL" ));
+ return nsKDEUtils::command( command ) ? NS_OK : NS_ERROR_FAILURE;
+ }
+
+NS_IMETHODIMP
-+nsKDEShellService::GetShouldCheckDefaultBrowser(PRBool* aResult)
++nsKDEShellService::GetShouldCheckDefaultBrowser(bool* aResult)
+{
-+ // If we've already checked, the browser has been started and this is a
++ // If we've already checked, the browser has been started and this is a
+ // new window open, and we don't want to check again.
+ if (mCheckedThisSession) {
+ *aResult = PR_FALSE;
@@ -1316,7 +1373,7 @@
+}
+
+NS_IMETHODIMP
-+nsKDEShellService::SetShouldCheckDefaultBrowser(PRBool aShouldCheck)
++nsKDEShellService::SetShouldCheckDefaultBrowser(bool aShouldCheck)
+{
+ nsCOMPtr<nsIPrefBranch> prefs;
+ nsCOMPtr<nsIPrefService> pserve(do_GetService(NS_PREFSERVICE_CONTRACTID));
@@ -1351,11 +1408,11 @@
+NS_IMETHODIMP
+nsKDEShellService::OpenApplication(PRInt32 aApplication)
+ {
-+ nsCStringArray command;
++ nsTArray<nsCString> command;
+ if( aApplication == APPLICATION_MAIL )
-+ command.AppendCString( NS_LITERAL_CSTRING( "OPENMAIL" ));
++ command.AppendElement( NS_LITERAL_CSTRING( "OPENMAIL" ));
+ else if( aApplication == APPLICATION_NEWS )
-+ command.AppendCString( NS_LITERAL_CSTRING( "OPENNEWS" ));
++ command.AppendElement( NS_LITERAL_CSTRING( "OPENNEWS" ));
+ else
+ return NS_ERROR_NOT_IMPLEMENTED;
+ return nsKDEUtils::command( command ) ? NS_OK : NS_ERROR_FAILURE;
@@ -1364,13 +1421,13 @@
+NS_IMETHODIMP
+nsKDEShellService::OpenApplicationWithURI(nsILocalFile* aApplication, const nsACString& aURI)
+ {
-+ nsCStringArray command;
-+ command.AppendCString( NS_LITERAL_CSTRING( "RUN" ));
++ nsTArray<nsCString> command;
++ command.AppendElement( NS_LITERAL_CSTRING( "RUN" ));
+ nsCString app;
+ nsresult rv = aApplication->GetNativePath( app );
+ NS_ENSURE_SUCCESS( rv, rv );
-+ command.AppendCString( app );
-+ command.AppendCString( aURI );
++ command.AppendElement( app );
++ command.AppendElement( aURI );
+ return nsKDEUtils::command( command ) ? NS_OK : NS_ERROR_FAILURE;
+ }
+
@@ -1379,14 +1436,14 @@
+ {
+ *_retval = nsnull;
+
-+ nsCStringArray command;
-+ command.AppendCString( NS_LITERAL_CSTRING( "GETDEFAULTFEEDREADER" ));
-+ nsCStringArray output;
-+ if( !nsKDEUtils::command( command, &output ) || output.Count() != 1 )
++ nsTArray<nsCString> command;
++ command.AppendElement( NS_LITERAL_CSTRING( "GETDEFAULTFEEDREADER" ));
++ nsTArray<nsCString> output;
++ if( !nsKDEUtils::command( command, &output ) || output.Length() != 1 )
+ return NS_ERROR_FAILURE;
+
+ nsCString path;
-+ path = *output[ 0 ];
++ path = output[ 0 ];
+ if (path.IsEmpty())
+ return NS_ERROR_FAILURE;
+
@@ -1398,7 +1455,7 @@
+ rv = defaultReader->InitWithNativePath(path);
+ NS_ENSURE_SUCCESS(rv, rv);
+
-+ PRBool exists;
++ bool exists;
+ rv = defaultReader->Exists(&exists);
+ NS_ENSURE_SUCCESS(rv, rv);
+ if (!exists)
@@ -1581,7 +1638,7 @@
diff --git a/browser/installer/package-manifest.in b/browser/installer/package-manifest.in
--- a/browser/installer/package-manifest.in
+++ b/browser/installer/package-manifest.in
-@@ -424,16 +424,17 @@
+@@ -426,16 +426,17 @@
#endif
#endif