Updated to 58.0

This commit is contained in:
Алзим 2018-01-24 12:33:01 +03:00
parent 1baf3ab6e9
commit c19636a9e4
9 changed files with 432 additions and 676 deletions

View file

@ -1,2 +1,2 @@
sources:
firefox-56.0.2.source.tar.xz: 1b7310adea833a7c74498505f1207416690c9748
firefox-58.0.source.tar.xz: 253d1bcd2256fa013eadac40f04b5ddacc2b5e74

View file

@ -8,5 +8,5 @@ diff -ur mozilla-release/python/mach/mach/main.py mozilla-release.new/python/mac
- module_name = 'mach.commands.%s' % uuid.uuid1().get_hex()
+ module_name = 'mach.commands.%s' % uuid.uuid4().get_hex()
try:
imp.load_source(module_name, path)

View file

@ -28,17 +28,17 @@
class nsAutoOwningThread
{
--- firefox-56.0/dom/base/nsNodeInfoManager.h-orig 2017-07-31 19:20:51.000000000 +0300
+++ firefox-56.0/dom/base/nsNodeInfoManager.h 2017-09-28 19:02:39.456369315 +0300
@@ -14,7 +14,7 @@
#include "mozilla/Attributes.h" // for final
--- firefox-57.0/dom/base/nsNodeInfoManager.h-orig 2017-11-02 19:16:34.000000000 +0300
+++ firefox-57.0/dom/base/nsNodeInfoManager.h 2017-11-14 21:06:37.557820720 +0300
@@ -15,7 +15,7 @@
#include "nsCOMPtr.h" // for member
#include "nsCycleCollectionParticipant.h" // for NS_DECL_CYCLE_*
#include "nsStringFwd.h"
-#include "plhash.h" // for typedef PLHashNumber
+#include "nspr4/plhash.h" // for typedef PLHashNumber
class nsAString;
class nsBindingManager;
class nsAtom;
--- firefox-56.0/xpcom/ds/nsCRT.h-orig 2017-09-28 20:02:28.000000000 +0300
+++ firefox-56.0/xpcom/ds/nsCRT.h 2017-09-28 20:03:25.099126089 +0300
@@ -8,7 +8,7 @@

File diff suppressed because it is too large Load diff

View file

@ -7,7 +7,7 @@
# This also means only STABLE upstream releases, NO betas.
# This is a discussed topic. Please, do not flame it again.
%define major 56.0.2
%define major 58.0
%define ff_epoch 0
# (tpg) set version HERE !!!
%define realver %{major}
@ -24,15 +24,13 @@
%define _use_syshunspell 0
%define update_channel release
%define toolkit_gtk3 1
Summary: Next generation web browser
Name: firefox
Version: %{major}
Epoch: %{ff_epoch}
Release: 3
Release: 1
License: MPLv1+
Group: Networking/WWW
Url: http://www.mozilla.com/firefox/
@ -46,9 +44,6 @@ Source9: kde.js
Patch11: firefox-kde.patch
Patch12: mozilla-kde.patch
#Patch13: mozilla-kde-background.patch
Patch34: xulrunner_nojit.patch
Patch35: firefox-37-build-with-time-independent-uuids.patch
Patch37: firefox-50.1-fix-glibc-check.patch
@ -58,7 +53,6 @@ Patch215: firefox-enable-addons.patch
Patch219: rhbz-1173156.patch
Patch300: firefox-56.0-build-error.patch
Patch301: rhbz-1497932.patch
BuildRequires: gtk+2-devel
%if %{toolkit_gtk3}
@ -180,13 +174,7 @@ Files and macros mainly for building Firefox extensions.
## KDE INTEGRATION
%patch11 -p1 -b .kdepatch
%patch12 -p1 -b .kdemoz
#%%patch13 -p1 -b .kdebackground
%ifarch %{arm}
%if "%{_target_cpu}" != "armv7l"
%patch34 -p1
%endif
%endif
%patch35 -p1
%patch37 -p1
@ -195,7 +183,6 @@ Files and macros mainly for building Firefox extensions.
%patch219 -p2 -b .rhbz-1173156
%patch300 -p1
%patch301 -p1
pushd js/src
autoconf-2.13
@ -246,13 +233,18 @@ ac_add_options --with-distribution-id=org.rosa
ac_add_options --disable-crashreporter
ac_add_options --disable-debug
ac_add_options --enable-optimize
#ac_add_options --enable-rust-debug
# Error stylo in x86 v57.0
%ifarch %{ix86}
ac_add_options --disable-stylo
%endif
EOF
perl -p -i -e 's|\-0|\-9|g' config/make-jars.pl
export LDFLAGS="%{ldflags}"
%make -f client.mk build
./mach build
%install
# Make sure locale works for langpacks
@ -274,7 +266,7 @@ popd
mkdir -p %{buildroot}%{mozillalibdir}/defaults/preferences/
install -m 644 %{SOURCE9} %{buildroot}%{mozillalibdir}/defaults/preferences/kde.js
# Create and own %_libdir/mozilla/plugins & firefox extensions directories
# Create and own %%_libdir/mozilla/plugins & firefox extensions directories
mkdir -p %{buildroot}%{pluginsdir}
mkdir -p %{buildroot}%{_libdir}/mozilla/extensions/%{firefox_appid}
mkdir -p %{buildroot}%{_datadir}/mozilla/extensions/%{firefox_appid}
@ -320,7 +312,7 @@ EOF
rm -fr %{buildroot}%{mozillalibdir}/dictionaries
ln -s %{_datadir}/dict/mozilla/ %{buildroot}%{mozillalibdir}/dictionaries
# (lm) touch and %ghost bookmarks.html to a proper uninstall
# (lm) touch and %%ghost bookmarks.html to a proper uninstall
touch %{buildroot}%{mozillalibdir}/defaults/profile/bookmarks.html
mkdir -p %{buildroot}%{_sys_macros_dir}

View file

@ -1,141 +0,0 @@
diff -urN firefox-50.0.2-orig/browser/components/shell/nsKDEShellService.cpp firefox-50.0.2-patched/browser/components/shell/nsKDEShellService.cpp
--- firefox-50.0.2-orig/browser/components/shell/nsKDEShellService.cpp 2016-12-07 19:28:13.314146351 +1000
+++ firefox-50.0.2-patched/browser/components/shell/nsKDEShellService.cpp 2016-12-07 20:58:32.879636319 +1000
@@ -17,6 +17,22 @@
#include "nsIMutableArray.h"
#include "nsISupportsPrimitives.h"
#include "nsArrayUtils.h"
+#include "nsIImageLoadingContent.h"
+#include "imgIContainer.h"
+#include "imgIRequest.h"
+#include "nsIStringBundle.h"
+#include "nsIDOMHTMLImageElement.h"
+#include "prenv.h"
+
+#include <glib.h>
+#include <glib-object.h>
+#include <gtk/gtk.h>
+#include <gdk/gdk.h>
+#if defined(MOZ_WIDGET_GTK)
+#include "nsIImageToPixbuf.h"
+#endif
+#include <limits.h>
+#include <stdlib.h>
using namespace mozilla;
@@ -28,6 +44,28 @@
return NS_OK;
}
+static nsresult
+WriteImage(const nsCString& aPath, imgIContainer* aImage)
+{
+#if !defined(MOZ_WIDGET_GTK)
+ return NS_ERROR_NOT_AVAILABLE;
+#else
+ nsCOMPtr<nsIImageToPixbuf> imgToPixbuf =
+ do_GetService("@mozilla.org/widget/image-to-gdk-pixbuf;1");
+ if (!imgToPixbuf)
+ return NS_ERROR_NOT_AVAILABLE;
+
+ GdkPixbuf* pixbuf = imgToPixbuf->ConvertImageToPixbuf(aImage);
+ if (!pixbuf)
+ return NS_ERROR_NOT_AVAILABLE;
+
+ gboolean res = gdk_pixbuf_save(pixbuf, aPath.get(), "png", nullptr, nullptr);
+
+ g_object_unref(pixbuf);
+ return res ? NS_OK : NS_ERROR_FAILURE;
+#endif
+}
+
NS_IMPL_ISUPPORTS(nsKDEShellService, nsIGNOMEShellService, nsIShellService)
NS_IMETHODIMP
@@ -88,19 +126,82 @@
nsKDEShellService::SetDesktopBackground(nsIDOMElement* aElement,
PRInt32 aPosition)
{
- return NS_ERROR_NOT_IMPLEMENTED;
+ nsresult rv;
+ nsCOMPtr<nsIImageLoadingContent> imageContent = do_QueryInterface(aElement, &rv);
+ if (!imageContent) return rv;
+
+ // get the image container
+ nsCOMPtr<imgIRequest> request;
+ rv = imageContent->GetRequest(nsIImageLoadingContent::CURRENT_REQUEST,
+ getter_AddRefs(request));
+ if (!request) return rv;
+ nsCOMPtr<imgIContainer> container;
+ rv = request->GetImage(getter_AddRefs(container));
+ if (!container) return rv;
+
+ // Set desktop wallpaper filling style
+ nsAutoCString options;
+ if (aPosition == BACKGROUND_TILE)
+ options.Assign("TiledResize");
+ else if (aPosition == BACKGROUND_STRETCH)
+ options.Assign("ScaledResize");
+ else if (aPosition == BACKGROUND_FILL)
+ options.Assign("ScaledAndCroppedResize");
+ else if (aPosition == BACKGROUND_FIT)
+ options.Assign("MaxpectResize");
+ else
+ options.Assign("CenteredResize");
+
+ // Write the background file to the home directory.
+ nsAutoCString filePath(PR_GetEnv("HOME"));
+
+ // get the product brand name from localized strings
+ nsString brandName;
+ nsCID bundleCID = NS_STRINGBUNDLESERVICE_CID;
+ nsCOMPtr<nsIStringBundleService> bundleService(do_GetService(bundleCID));
+ if (bundleService) {
+ nsCOMPtr<nsIStringBundle> brandBundle;
+ rv = bundleService->CreateBundle(BRAND_PROPERTIES,
+ getter_AddRefs(brandBundle));
+ if (NS_SUCCEEDED(rv) && brandBundle) {
+ rv = brandBundle->GetStringFromName("brandShortName", brandName);
+ NS_ENSURE_SUCCESS(rv, rv);
+ }
+ }
+
+ // build the file name
+ filePath.Append('/');
+ filePath.Append(NS_ConvertUTF16toUTF8(brandName));
+ filePath.Append("_wallpaper.png");
+
+ // write the image to a file in the home dir
+ rv = WriteImage(filePath, container);
+ NS_ENSURE_SUCCESS(rv, rv);
+
+ nsCOMPtr<nsIMutableArray> command = do_CreateInstance( NS_ARRAY_CONTRACTID );
+ nsCOMPtr<nsISupportsCString> cmdstr = do_CreateInstance( NS_SUPPORTS_CSTRING_CONTRACTID );
+ nsCOMPtr<nsISupportsCString> imgstr = do_CreateInstance( NS_SUPPORTS_CSTRING_CONTRACTID );
+ nsCOMPtr<nsISupportsCString> modestr = do_CreateInstance( NS_SUPPORTS_CSTRING_CONTRACTID );
+ cmdstr->SetData( NS_LITERAL_CSTRING( "SETWALLPAPER" ));
+ command->AppendElement( cmdstr, false );
+ imgstr->SetData( filePath );
+ command->AppendElement( imgstr, false );
+ modestr->SetData( options );
+ command->AppendElement( modestr, false );
+ return nsKDEUtils::command( command ) ? rv : NS_ERROR_FAILURE;
}
NS_IMETHODIMP
nsKDEShellService::GetDesktopBackgroundColor(PRUint32 *aColor)
{
- return NS_ERROR_NOT_IMPLEMENTED;
+ aColor = 0;
+ return NS_OK;
}
NS_IMETHODIMP
nsKDEShellService::SetDesktopBackgroundColor(PRUint32 aColor)
{
- return NS_ERROR_NOT_IMPLEMENTED;
+ return NS_OK;
}
NS_IMETHODIMP

View file

@ -1,5 +1,5 @@
# HG changeset patch
# Parent a930d4c1c3fba77f61071becdc51e3232e0b72ca
# Parent 5be2231eadfb6de978e93c0ba95469e8a4d54cb0
Description: Add KDE integration to Firefox (toolkit parts)
Author: Wolfgang Rosenauer <wolfgang@rosenauer.org>
Author: Lubos Lunak <lunak@suse.com>
@ -9,32 +9,32 @@ Bug: https://bugzilla.mozilla.org/show_bug.cgi?id=140751
diff --git a/modules/libpref/Preferences.cpp b/modules/libpref/Preferences.cpp
--- a/modules/libpref/Preferences.cpp
+++ b/modules/libpref/Preferences.cpp
@@ -33,16 +33,17 @@
#include "nsIZipReader.h"
#include "nsPrefBranch.h"
#include "nsXPIDLString.h"
#include "nsCRT.h"
#include "nsCOMArray.h"
@@ -75,16 +75,17 @@
#include "nsXPCOMCID.h"
#include "nsAutoPtr.h"
#include "nsPrintfCString.h"
#include "nsXPCOM.h"
#include "nsXULAppAPI.h"
#include "nsZipArchive.h"
#include "plbase64.h"
#include "PLDHashTable.h"
#include "plstr.h"
#include "prlink.h"
+#include "nsKDEUtils.h"
#include "nsQuickSort.h"
#include "PLDHashTable.h"
#ifdef MOZ_CRASHREPORTER
#include "nsICrashReporter.h"
#endif
#include "prefapi.h"
#include "prefread.h"
#include "prefapi_private_data.h"
@@ -1435,16 +1436,34 @@ pref_LoadPrefsInDir(nsIFile* aDir, char
static nsresult pref_LoadPrefsInDirList(const char *listId)
#ifdef XP_WIN
#include "windows.h"
#endif
@@ -4324,16 +4325,34 @@ pref_LoadPrefsInDirList(const char* aLis
{
nsresult rv;
nsCOMPtr<nsIProperties> dirSvc(do_GetService(NS_DIRECTORY_SERVICE_CONTRACTID, &rv));
if (NS_FAILED(rv))
nsCOMPtr<nsIProperties> dirSvc(
do_GetService(NS_DIRECTORY_SERVICE_CONTRACTID, &rv));
if (NS_FAILED(rv)) {
return rv;
}
+ // make sure we load these special files after all the others
+ static const char* specialFiles[] = {
@ -55,34 +55,34 @@ diff --git a/modules/libpref/Preferences.cpp b/modules/libpref/Preferences.cpp
+ }
+
nsCOMPtr<nsISimpleEnumerator> list;
dirSvc->Get(listId,
NS_GET_IID(nsISimpleEnumerator),
getter_AddRefs(list));
if (!list)
dirSvc->Get(aListId, NS_GET_IID(nsISimpleEnumerator), getter_AddRefs(list));
if (!list) {
return NS_OK;
}
bool hasMore;
@@ -1460,17 +1479,17 @@ static nsresult pref_LoadPrefsInDirList(
while (NS_SUCCEEDED(list->HasMoreElements(&hasMore)) && hasMore) {
@@ -4344,17 +4363,17 @@ pref_LoadPrefsInDirList(const char* aLis
}
nsAutoCString leaf;
path->GetNativeLeafName(leaf);
nsCOMPtr<nsIFile> path = do_QueryInterface(elem);
if (!path) {
continue;
}
// Do we care if a file provided by this process fails to load?
if (Substring(leaf, leaf.Length() - 4).EqualsLiteral(".xpi"))
ReadExtensionPrefs(path);
else
- pref_LoadPrefsInDir(path, nullptr, 0);
+ pref_LoadPrefsInDir(path, specialFiles, MOZ_ARRAY_LENGTH(specialFiles));
+ pref_LoadPrefsInDir(path, specialFiles, ArrayLength(specialFiles));
}
return NS_OK;
}
static nsresult pref_ReadPrefFromJar(nsZipArchive* jarReader, const char *name)
static nsresult
pref_ReadPrefFromJar(nsZipArchive* aJarReader, const char* aName)
{
nsZipItemPtr<char> manifest(jarReader, name, true);
NS_ENSURE_TRUE(manifest.Buffer(), NS_ERROR_NOT_AVAILABLE);
@@ -1566,24 +1585,36 @@ pref_InitInitialObjects()
/* these pref file names should not be used: we process them after all other application pref files for backwards compatibility */
@@ -4461,25 +4480,37 @@ pref_InitInitialObjects()
// application pref files for backwards compatibility.
static const char* specialFiles[] = {
#if defined(XP_MACOSX)
"macprefs.js"
@ -92,7 +92,8 @@ diff --git a/modules/libpref/Preferences.cpp b/modules/libpref/Preferences.cpp
"unix.js"
+ , "" // placeholder for KDE (empty is otherwise harmless)
#if defined(_AIX)
, "aix.js"
,
"aix.js"
#endif
#elif defined(XP_BEOS)
"beos.js"
@ -110,24 +111,24 @@ diff --git a/modules/libpref/Preferences.cpp b/modules/libpref/Preferences.cpp
+ }
+ }
+
rv = pref_LoadPrefsInDir(defaultPrefDir, specialFiles, ArrayLength(specialFiles));
if (NS_FAILED(rv))
rv = pref_LoadPrefsInDir(
defaultPrefDir, specialFiles, ArrayLength(specialFiles));
if (NS_FAILED(rv)) {
NS_WARNING("Error parsing application default preferences.");
}
// Load jar:$app/omni.jar!/defaults/preferences/*.js
// or jar:$gre/omni.jar!/defaults/preferences/*.js.
RefPtr<nsZipArchive> appJarReader = mozilla::Omnijar::GetReader(mozilla::Omnijar::APP);
// GetReader(mozilla::Omnijar::APP) returns null when $app == $gre, in which
diff --git a/modules/libpref/moz.build b/modules/libpref/moz.build
--- a/modules/libpref/moz.build
+++ b/modules/libpref/moz.build
@@ -33,16 +33,20 @@ EXPORTS.mozilla += [
@@ -27,16 +27,20 @@ XPIDL_MODULE = 'pref'
EXPORTS.mozilla += [
'Preferences.h',
]
UNIFIED_SOURCES += [
'nsPrefBranch.cpp',
'nsPrefsFactory.cpp',
'prefapi.cpp',
'Preferences.cpp',
'prefread.cpp',
]
+LOCAL_INCLUDES += [
@ -166,8 +167,7 @@ diff --git a/python/mozbuild/mozpack/chrome/flags.py b/python/mozbuild/mozpack/c
diff --git a/python/mozbuild/mozpack/chrome/manifest.py b/python/mozbuild/mozpack/chrome/manifest.py
--- a/python/mozbuild/mozpack/chrome/manifest.py
+++ b/python/mozbuild/mozpack/chrome/manifest.py
@@ -33,16 +33,17 @@ class ManifestEntry(object):
'application',
@@ -34,16 +34,17 @@ class ManifestEntry(object):
'platformversion',
'os',
'osversion',
@ -175,6 +175,7 @@ diff --git a/python/mozbuild/mozpack/chrome/manifest.py b/python/mozbuild/mozpac
'xpcnativewrappers',
'tablet',
'process',
'contentaccessible',
+ 'desktop',
]
@ -187,24 +188,20 @@ diff --git a/python/mozbuild/mozpack/chrome/manifest.py b/python/mozbuild/mozpac
diff --git a/toolkit/components/downloads/moz.build b/toolkit/components/downloads/moz.build
--- a/toolkit/components/downloads/moz.build
+++ b/toolkit/components/downloads/moz.build
@@ -37,16 +37,17 @@ UNIFIED_SOURCES += [
@@ -17,9 +17,13 @@ XPIDL_SOURCES += [
XPIDL_MODULE = 'downloads'
UNIFIED_SOURCES += [
'nsDownloadManager.cpp'
]
FINAL_LIBRARY = 'xul'
LOCAL_INCLUDES += [
'../protobuf',
'/ipc/chromium/src',
+ '/toolkit/xre',
'chromium'
]
DEFINES['GOOGLE_PROTOBUF_NO_RTTI'] = True
DEFINES['GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER'] = True
+LOCAL_INCLUDES += [
+ '/toolkit/xre'
+]
+
CXXFLAGS += CONFIG['TK_CFLAGS']
diff --git a/toolkit/content/jar.mn b/toolkit/content/jar.mn
--- a/toolkit/content/jar.mn
+++ b/toolkit/content/jar.mn
@ -246,7 +243,7 @@ diff --git a/toolkit/content/widgets/dialog-kde.xml b/toolkit/content/widgets/di
new file mode 100644
--- /dev/null
+++ b/toolkit/content/widgets/dialog-kde.xml
@@ -0,0 +1,455 @@
@@ -0,0 +1,459 @@
+<?xml version="1.0"?>
+<!-- This Source Code Form is subject to the terms of the Mozilla Public
+ - License, v. 2.0. If a copy of the MPL was not distributed with this
@ -434,9 +431,13 @@ new file mode 100644
+ focusedElt.getAttribute("noinitialfocus") == "true") {
+ document.commandDispatcher.advanceFocusIntoSubtree(focusedElt);
+ focusedElt = document.commandDispatcher.focusedElement;
+ if (focusedElt == initialFocusedElt)
+ if (focusedElt == initialFocusedElt) {
+ if (focusedElt.getAttribute("noinitialfocus") == "true") {
+ focusedElt.blur();
+ }
+ break;
+ }
+ }
+
+ if (initialFocusedElt.localName == "tab") {
+ if (focusedElt.hasAttribute("dlgtype")) {
@ -568,7 +569,7 @@ new file mode 100644
+ if (/Win/.test(navigator.platform)) {
+ var spacer = document.getAnonymousElementByAttribute(this, "anonid", "spacer");
+ spacer.removeAttribute("hidden");
+ spacer.setAttribute("flex", shown["extra2"] ? "1" : "0");
+ spacer.setAttribute("flex", shown.extra2 ? "1" : "0");
+ }
+ }
+ ]]>
@ -803,7 +804,7 @@ new file mode 100644
+ </field>
+ <field name="rootBranchInternal">
+ Components.classes["@mozilla.org/preferences-service;1"]
+ .getService(Components.interfaces.nsIPrefBranchInternal);
+ .getService(Components.interfaces.nsIPrefBranch);
+ </field>
+ <property name="type" readonly="true">
+ <getter>
@ -1083,7 +1084,7 @@ new file mode 100644
+ return fontEnumerator.getStandardFamilyName(family);
+ case "file":
+ var f = this._branch
+ .getComplexValue(this.name, Components.interfaces.nsILocalFile);
+ .getComplexValue(this.name, Components.interfaces.nsIFile);
+ return f;
+ default:
+ this._reportUnknownType();
@ -1128,14 +1129,14 @@ new file mode 100644
+ var lf;
+ if (typeof(val) == "string") {
+ lf = Components.classes["@mozilla.org/file/local;1"]
+ .createInstance(Components.interfaces.nsILocalFile);
+ .createInstance(Components.interfaces.nsIFile);
+ lf.persistentDescriptor = val;
+ if (!lf.exists())
+ lf.initWithPath(val);
+ } else
+ lf = val.QueryInterface(Components.interfaces.nsILocalFile);
+ lf = val.QueryInterface(Components.interfaces.nsIFile);
+ this.preferences.rootBranch
+ .setComplexValue(this.name, Components.interfaces.nsILocalFile, lf);
+ .setComplexValue(this.name, Components.interfaces.nsIFile, lf);
+ break;
+ default:
+ this._reportUnknownType();
@ -2119,7 +2120,7 @@ new file mode 100644
diff --git a/toolkit/mozapps/downloads/nsHelperAppDlg.js b/toolkit/mozapps/downloads/nsHelperAppDlg.js
--- a/toolkit/mozapps/downloads/nsHelperAppDlg.js
+++ b/toolkit/mozapps/downloads/nsHelperAppDlg.js
@@ -628,17 +628,17 @@ nsUnknownContentTypeDialog.prototype = {
@@ -626,17 +626,17 @@ nsUnknownContentTypeDialog.prototype = {
else
typeString = mimeInfo.MIMEType;
}
@ -2138,7 +2139,7 @@ diff --git a/toolkit/mozapps/downloads/nsHelperAppDlg.js b/toolkit/mozapps/downl
},
// Returns true if opening the default application makes sense.
@@ -802,17 +802,17 @@ nsUnknownContentTypeDialog.prototype = {
@@ -800,17 +800,17 @@ nsUnknownContentTypeDialog.prototype = {
switch (this.dialogElement("openHandler").selectedIndex) {
case 0:
// No app need be specified in this case.
@ -2157,7 +2158,7 @@ diff --git a/toolkit/mozapps/downloads/nsHelperAppDlg.js b/toolkit/mozapps/downl
this.mDialog.document.documentElement.getButton("accept").disabled = !ok;
},
@@ -1067,30 +1067,57 @@ nsUnknownContentTypeDialog.prototype = {
@@ -1065,30 +1065,57 @@ nsUnknownContentTypeDialog.prototype = {
if (params.handlerApp &&
params.handlerApp.executable &&
@ -2548,7 +2549,7 @@ new file mode 100644
+ if ( !rstr ) return false;
+
+ rstr->SetData( out[i] );
+ result->AppendElement( rstr, false );
+ result->AppendElement( rstr );
+ }
+
+ NS_ADDREF( *output = result);
@ -2770,11 +2771,11 @@ diff --git a/uriloader/exthandler/moz.build b/uriloader/exthandler/moz.build
'android/nsExternalSharingAppService.cpp',
'android/nsExternalURLHandlerService.cpp',
'android/nsMIMEInfoAndroid.cpp',
@@ -125,16 +127,17 @@ include('/ipc/chromium/chromium-config.m
@@ -129,16 +131,17 @@ include('/ipc/chromium/chromium-config.m
FINAL_LIBRARY = 'xul'
LOCAL_INCLUDES += [
'/docshell/base',
'/dom/base',
'/dom/ipc',
'/netwerk/base',
@ -2883,7 +2884,7 @@ diff --git a/uriloader/exthandler/unix/nsKDERegistry.cpp b/uriloader/exthandler/
new file mode 100644
--- /dev/null
+++ b/uriloader/exthandler/unix/nsKDERegistry.cpp
@@ -0,0 +1,88 @@
@@ -0,0 +1,87 @@
+/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
+/* This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
@ -2893,7 +2894,6 @@ new file mode 100644
+#include "prlink.h"
+#include "prmem.h"
+#include "nsString.h"
+#include "nsILocalFile.h"
+#include "nsMIMEInfoUnix.h"
+#include "nsAutoPtr.h"
+#include "nsKDEUtils.h"
@ -2989,8 +2989,8 @@ new file mode 100644
+#include "nsTArray.h"
+
+class nsMIMEInfoBase;
+class nsAutoCString;
+class nsCString;
+//class nsAutoCString;
+//class nsCString;
+
+class nsKDERegistry
+{
@ -3110,11 +3110,11 @@ diff --git a/uriloader/exthandler/unix/nsMIMEInfoUnix.cpp b/uriloader/exthandler
diff --git a/uriloader/exthandler/unix/nsOSHelperAppService.cpp b/uriloader/exthandler/unix/nsOSHelperAppService.cpp
--- a/uriloader/exthandler/unix/nsOSHelperAppService.cpp
+++ b/uriloader/exthandler/unix/nsOSHelperAppService.cpp
@@ -10,17 +10,17 @@
#if defined(MOZ_ENABLE_CONTENTACTION)
#include <contentaction/contentaction.h>
#include <QString>
#endif
@@ -5,17 +5,17 @@
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include <sys/types.h>
#include <sys/stat.h>
#include "nsOSHelperAppService.h"
#include "nsMIMEInfoUnix.h"
@ -3126,23 +3126,32 @@ diff --git a/uriloader/exthandler/unix/nsOSHelperAppService.cpp b/uriloader/exth
#include "nsString.h"
#include "nsReadableUtils.h"
#include "nsUnicharUtils.h"
#include "nsXPIDLString.h"
#include "nsIURL.h"
#include "nsIFileStreams.h"
@@ -1143,26 +1143,26 @@ nsresult nsOSHelperAppService::OSProtoco
ContentAction::Action::defaultActionForScheme(QString(aProtocolScheme) + ':');
#include "nsILineInputStream.h"
@@ -1128,17 +1128,17 @@ nsOSHelperAppService::GetHandlerAndDescr
if (action.isValid())
*aHandlerExists = true;
#endif
nsresult nsOSHelperAppService::OSProtocolHandlerExists(const char * aProtocolScheme, bool * aHandlerExists)
{
nsresult rv = NS_OK;
if (!XRE_IsContentProcess()) {
#ifdef MOZ_WIDGET_GTK
// Check the GNOME registry for a protocol handler
- *aHandlerExists = nsGNOMERegistry::HandlerExists(aProtocolScheme);
+ *aHandlerExists = nsCommonRegistry::HandlerExists(aProtocolScheme);
#else
*aHandlerExists = false;
#endif
} else {
*aHandlerExists = false;
nsCOMPtr<nsIHandlerService> handlerSvc = do_GetService(NS_HANDLERSERVICE_CONTRACTID, &rv);
if (NS_SUCCEEDED(rv) && handlerSvc) {
rv = handlerSvc->ExistsForProtocol(nsCString(aProtocolScheme), aHandlerExists);
@@ -1146,17 +1146,17 @@ nsresult nsOSHelperAppService::OSProtoco
}
return NS_OK;
return rv;
}
NS_IMETHODIMP nsOSHelperAppService::GetApplicationDescription(const nsACString& aScheme, nsAString& _retval)
@ -3158,7 +3167,7 @@ diff --git a/uriloader/exthandler/unix/nsOSHelperAppService.cpp b/uriloader/exth
nsresult nsOSHelperAppService::GetFileTokenForPath(const char16_t * platformAppPath, nsIFile ** aFile)
{
@@ -1249,17 +1249,17 @@ nsOSHelperAppService::GetFromExtension(c
@@ -1243,17 +1243,17 @@ nsOSHelperAppService::GetFromExtension(c
mime_types_description,
true);
@ -3177,7 +3186,7 @@ diff --git a/uriloader/exthandler/unix/nsOSHelperAppService.cpp b/uriloader/exth
rv = LookUpTypeAndDescription(NS_ConvertUTF8toUTF16(aFileExt),
majorType,
@@ -1370,17 +1370,17 @@ nsOSHelperAppService::GetFromType(const
@@ -1364,17 +1364,17 @@ nsOSHelperAppService::GetFromType(const
nsAutoString extensions, mime_types_description;
LookUpExtensionsAndDescription(majorType,
minorType,
@ -3276,7 +3285,7 @@ diff --git a/widget/gtk/nsFilePicker.cpp b/widget/gtk/nsFilePicker.cpp
mFilters.AppendElement(filter);
mFilterNames.AppendElement(name);
@@ -371,16 +375,37 @@ nsFilePicker::Show(int16_t *aReturn)
@@ -371,16 +375,39 @@ nsFilePicker::Show(int16_t *aReturn)
NS_IMETHODIMP
nsFilePicker::Open(nsIFilePickerShownCallback *aCallback)
@ -3289,6 +3298,7 @@ diff --git a/widget/gtk/nsFilePicker.cpp b/widget/gtk/nsFilePicker.cpp
+ if( nsKDEUtils::kdeSupport()) {
+ mCallback = aCallback;
+ mRunning = true;
+ NS_ADDREF_THIS();
+ g_idle_add([](gpointer data) -> gboolean {
+ nsFilePicker* queuedPicker = (nsFilePicker*) data;
+ int16_t result;
@ -3300,13 +3310,14 @@ diff --git a/widget/gtk/nsFilePicker.cpp b/widget/gtk/nsFilePicker.cpp
+ queuedPicker->mResult = result;
+ }
+ queuedPicker->mRunning = false;
+ NS_RELEASE(queuedPicker);
+ return G_SOURCE_REMOVE;
+ }, this);
+
+ return NS_OK;
+ }
+
nsXPIDLCString title;
nsCString title;
title.Adopt(ToNewUTF8String(mTitle));
GtkWindow *parent_widget =
@ -3314,7 +3325,7 @@ diff --git a/widget/gtk/nsFilePicker.cpp b/widget/gtk/nsFilePicker.cpp
GtkFileChooserAction action = GetGtkFileChooserAction(mMode);
@@ -603,8 +628,233 @@ nsFilePicker::Done(GtkWidget* file_choos
@@ -603,8 +630,233 @@ nsFilePicker::Done(GtkWidget* file_choos
if (mCallback) {
mCallback->Done(result);
mCallback = nullptr;
@ -3354,7 +3365,7 @@ diff --git a/widget/gtk/nsFilePicker.cpp b/widget/gtk/nsFilePicker.cpp
+ if( mMode == modeOpen && mFilters.Length() == 1 && mFilters[ 0 ].EqualsLiteral( "..apps" ))
+ return kdeAppsDialog( aReturn );
+
+ nsXPIDLCString title;
+ nsCString title;
+ title.Adopt(ToNewUTF8String(mTitle));
+
+ const char* arg = NULL;
@ -3521,7 +3532,7 @@ diff --git a/widget/gtk/nsFilePicker.cpp b/widget/gtk/nsFilePicker.cpp
+ {
+ NS_ENSURE_ARG_POINTER(aReturn);
+
+ nsXPIDLCString title;
+ nsCString title;
+ title.Adopt(ToNewUTF8String(mTitle));
+
+ nsTArray<nsCString> command;
@ -3727,7 +3738,7 @@ diff --git a/xpcom/components/moz.build b/xpcom/components/moz.build
diff --git a/xpcom/io/nsLocalFileUnix.cpp b/xpcom/io/nsLocalFileUnix.cpp
--- a/xpcom/io/nsLocalFileUnix.cpp
+++ b/xpcom/io/nsLocalFileUnix.cpp
@@ -46,16 +46,17 @@
@@ -45,16 +45,17 @@
#include "prproces.h"
#include "nsIDirectoryEnumerator.h"
#include "nsISimpleEnumerator.h"
@ -3745,7 +3756,7 @@ diff --git a/xpcom/io/nsLocalFileUnix.cpp b/xpcom/io/nsLocalFileUnix.cpp
#include "prmem.h"
#include "plbase64.h"
@@ -1941,59 +1942,74 @@ nsLocalFile::SetPersistentDescriptor(con
@@ -1938,59 +1939,74 @@ nsLocalFile::SetPersistentDescriptor(con
return InitWithNativePath(aPersistentDescriptor);
#endif
}

View file

@ -1,21 +0,0 @@
diff -up firefox-56.0/media/libyuv/libyuv/tools_libyuv/autoroller/unittests/testdata/DEPS.chromium.old firefox-56.0/media/libyuv/libyuv/tools_libyuv/autoroller/unittests/testdata/DEPS.chromium
diff -up firefox-56.0/media/webrtc/trunk/Makefile.old firefox-56.0/media/webrtc/trunk/Makefile
diff -up firefox-56.0/widget/gtk/mozgtk/mozgtk.c.old firefox-56.0/widget/gtk/mozgtk/mozgtk.c
--- firefox-56.0/widget/gtk/mozgtk/mozgtk.c.old 2017-10-04 09:21:56.155553585 +0200
+++ firefox-56.0/widget/gtk/mozgtk/mozgtk.c 2017-10-04 09:22:35.562427061 +0200
@@ -61,7 +61,6 @@ STUB(gdk_screen_get_height_mm)
STUB(gdk_screen_get_n_monitors)
STUB(gdk_screen_get_monitor_at_window)
STUB(gdk_screen_get_monitor_geometry)
-STUB(gdk_screen_get_monitor_workarea)
STUB(gdk_screen_get_monitor_height_mm)
STUB(gdk_screen_get_number)
STUB(gdk_screen_get_resolution)
@@ -550,6 +549,7 @@ STUB(gtk_render_line)
STUB(gtk_render_option)
STUB(gtk_render_slider)
STUB(gtk_scale_new)
+STUB(gdk_screen_get_monitor_workarea)
STUB(gtk_scrollbar_new)
STUB(gtk_style_context_add_class)
STUB(gtk_style_context_add_region)

View file

@ -1,14 +0,0 @@
Index: mozilla-central/js/src/Makefile.in
===================================================================
--- mozilla-central.orig/js/src/Makefile.in
+++ mozilla-central/js/src/Makefile.in
@@ -923,7 +923,8 @@ endif
# Needed to "configure" it correctly. Unfortunately these
# flags wind up being applied to all code in js/src, not just
# the code in js/src/assembler.
-CXXFLAGS += -DUSE_SYSTEM_MALLOC=1 -DENABLE_ASSEMBLER=1 -DENABLE_JIT=1
+#CXXFLAGS += -DUSE_SYSTEM_MALLOC=1 -DENABLE_ASSEMBLER=1 -DENABLE_JIT=1
+CXXFLAGS += -DUSE_SYSTEM_MALLOC=1 -DENABLE_ASSEMBLER=0 -DENABLE_JIT=0 -DENABLE_YARR_JIT=0
INCLUDES += -I$(srcdir)/assembler -I$(srcdir)/yarr