diff -r 9ba8fb8909c4 -r 298263f797be mozilla-kde.patch --- a/mozilla-kde.patch Thu Feb 17 20:14:47 2011 +0100 +++ b/mozilla-kde.patch Wed Feb 23 15:14:39 2011 +0100 @@ -89,7 +89,7 @@ } //---------------------------------------------------------------------------------------- -@@ -826,28 +845,40 @@ static nsresult pref_InitDefaults() +@@ -890,24 +909,36 @@ static nsresult pref_InitInitialObjects( /* these pref file names should not be used: we process them after all other application pref files for backwards compatibility */ static const char* specialFiles[] = { #if defined(XP_MAC) || defined(XP_MACOSX) @@ -99,22 +99,18 @@ #elif defined(XP_UNIX) "unix.js" + , "" // placeholder for KDE (empty is otherwise harmless) - #if defined(VMS) - , "openvms.js" - #elif defined(_AIX) + #if defined(_AIX) , "aix.js" #endif #elif defined(XP_OS2) "os2pref.js" - #elif defined(XP_BEOS) - "beos.js" #endif }; + if(nsKDEUtils::kdeSession()) { // TODO what if some setup actually requires the helper? + for( int i = 0; -+ i < NS_ARRAY_LENGTH(specialFiles); -+ ++i ) { ++ i < NS_ARRAY_LENGTH(specialFiles); ++ ++i ) { + if( *specialFiles[ i ] == '\0' ) { + specialFiles[ i ] = "kde.js"; + break; @@ -127,8 +123,8 @@ NS_WARNING("Error parsing application default preferences."); } - return NS_OK; - } + rv = pref_LoadPrefsInDirList(NS_APP_PREFS_DEFAULTS_DIR_LIST); + NS_ENSURE_SUCCESS(rv, rv); diff --git a/toolkit/components/downloads/src/Makefile.in b/toolkit/components/downloads/src/Makefile.in --- a/toolkit/components/downloads/src/Makefile.in @@ -2155,9 +2151,9 @@ CPPSRCS += nsNativeAppSupportQt.cpp CPPSRCS += nsQAppInstance.cpp EXPORTS += nsQAppInstance.h - ifdef MOZ_ENABLE_MEEGOTOUCH - MOCSRCS += moc_MozMeegoAppService.cpp - CPPSRCS += moc_MozMeegoAppService.cpp + else + CPPSRCS += nsNativeAppSupportDefault.cpp + endif diff --git a/toolkit/xre/nsKDEUtils.cpp b/toolkit/xre/nsKDEUtils.cpp new file mode 100644 --- /dev/null @@ -2949,13 +2945,13 @@ diff --git a/uriloader/exthandler/unix/nsMIMEInfoUnix.cpp b/uriloader/exthandler/unix/nsMIMEInfoUnix.cpp --- a/uriloader/exthandler/unix/nsMIMEInfoUnix.cpp +++ b/uriloader/exthandler/unix/nsMIMEInfoUnix.cpp -@@ -48,28 +48,31 @@ - #include - #include +@@ -50,28 +50,31 @@ #include + #if (MOZ_ENABLE_CONTENTACTION) #include #include "nsContentHandlerApp.h" #endif + #endif #include "nsMIMEInfoUnix.h" -#include "nsGNOMERegistry.h" @@ -2983,7 +2979,7 @@ nsCAutoString spec; aURI->GetAsciiSpec(spec); if (hildon_uri_open(spec.get(), action, nsnull)) -@@ -91,22 +94,22 @@ nsMIMEInfoUnix::LoadUriInternal(nsIURI * +@@ -93,22 +96,22 @@ nsMIMEInfoUnix::LoadUriInternal(nsIURI * return rv; } @@ -3008,7 +3004,7 @@ if (*_retval) return NS_OK; -@@ -149,32 +152,49 @@ nsMIMEInfoUnix::LaunchDefaultWithFile(ns +@@ -151,32 +154,49 @@ nsMIMEInfoUnix::LaunchDefaultWithFile(ns ContentAction::Action::defaultActionForFile(uri, QString(mSchemeOrType.get())); if (action.isValid()) { action.trigger(); @@ -3063,7 +3059,7 @@ --- a/uriloader/exthandler/unix/nsOSHelperAppService.cpp +++ b/uriloader/exthandler/unix/nsOSHelperAppService.cpp @@ -44,17 +44,17 @@ - #if (MOZ_PLATFORM_MAEMO == 6) + #if defined(MOZ_ENABLE_CONTENTACTION) #include #include #endif @@ -3665,11 +3661,11 @@ endif ifdef MOZ_PLATFORM_MAEMO - CFLAGS += $(MOZ_PLATFORM_MAEMO_CFLAGS) + CFLAGS += $(MOZ_PLATFORM_MAEMO_CFLAGS) $(MOZ_QT_CFLAGS) diff --git a/xpcom/io/nsLocalFileUnix.cpp b/xpcom/io/nsLocalFileUnix.cpp --- a/xpcom/io/nsLocalFileUnix.cpp +++ b/xpcom/io/nsLocalFileUnix.cpp -@@ -91,16 +91,17 @@ +@@ -93,16 +93,17 @@ #include "prproces.h" #include "nsIDirectoryEnumerator.h" #include "nsISimpleEnumerator.h" @@ -3687,7 +3683,7 @@ #include "prmem.h" #include "plbase64.h" -@@ -1820,44 +1821,50 @@ nsLocalFile::Launch() +@@ -1822,44 +1823,50 @@ nsLocalFile::Launch() return NS_OK; } @@ -3752,7 +3748,7 @@ return rv; } return NS_ERROR_FAILURE; -@@ -1883,16 +1890,23 @@ nsLocalFile::Launch() +@@ -1885,16 +1892,23 @@ nsLocalFile::Launch() if (nsnull == connection) return NS_ERROR_FAILURE;