mozilla-kde.patch
changeset 1020 d2c159cb9bf2
parent 1014 963651ec972e
child 1021 1307721d2345
equal deleted inserted replaced
1019:b0c883afdffa 1020:d2c159cb9bf2
     1 # HG changeset patch
     1 # HG changeset patch
     2 # Parent  2504512f9a9ba7b52dd99745d15f049f2a03f4f4
     2 # Parent  5be2231eadfb6de978e93c0ba95469e8a4d54cb0
     3 Description: Add KDE integration to Firefox (toolkit parts)
     3 Description: Add KDE integration to Firefox (toolkit parts)
     4 Author: Wolfgang Rosenauer <wolfgang@rosenauer.org>
     4 Author: Wolfgang Rosenauer <wolfgang@rosenauer.org>
     5 Author: Lubos Lunak <lunak@suse.com>
     5 Author: Lubos Lunak <lunak@suse.com>
     6 Bug: https://bugzilla.mozilla.org/show_bug.cgi?id=140751
     6 Bug: https://bugzilla.mozilla.org/show_bug.cgi?id=140751
     7      https://bugzilla.novell.com/show_bug.cgi?id=170055
     7      https://bugzilla.novell.com/show_bug.cgi?id=170055
     8 
     8 
     9 diff --git a/modules/libpref/Preferences.cpp b/modules/libpref/Preferences.cpp
     9 diff --git a/modules/libpref/Preferences.cpp b/modules/libpref/Preferences.cpp
    10 --- a/modules/libpref/Preferences.cpp
    10 --- a/modules/libpref/Preferences.cpp
    11 +++ b/modules/libpref/Preferences.cpp
    11 +++ b/modules/libpref/Preferences.cpp
    12 @@ -37,16 +37,17 @@
    12 @@ -75,16 +75,17 @@
    13  #include "nsIZipReader.h"
       
    14  #include "nsPrefBranch.h"
       
    15  #include "nsString.h"
       
    16  #include "nsCRT.h"
       
    17  #include "nsCOMArray.h"
       
    18  #include "nsXPCOMCID.h"
    13  #include "nsXPCOMCID.h"
    19  #include "nsAutoPtr.h"
    14  #include "nsXPCOM.h"
    20  #include "nsPrintfCString.h"
    15  #include "nsXULAppAPI.h"
       
    16  #include "nsZipArchive.h"
       
    17  #include "plbase64.h"
       
    18  #include "PLDHashTable.h"
       
    19  #include "plstr.h"
       
    20  #include "prlink.h"
    21 +#include "nsKDEUtils.h"
    21 +#include "nsKDEUtils.h"
    22  
    22  
    23  #include "nsQuickSort.h"
    23  #ifdef MOZ_CRASHREPORTER
    24  #include "PLDHashTable.h"
    24  #include "nsICrashReporter.h"
    25  
    25  #endif
    26  #include "prefapi.h"
    26  
    27  #include "prefread.h"
    27  #ifdef XP_WIN
    28  #include "prefapi_private_data.h"
    28  #include "windows.h"
    29  
    29  #endif
    30 @@ -1413,16 +1414,34 @@ pref_LoadPrefsInDir(nsIFile* aDir, char 
    30 @@ -4324,16 +4325,34 @@ pref_LoadPrefsInDirList(const char* aLis
    31  
       
    32  static nsresult pref_LoadPrefsInDirList(const char *listId)
       
    33  {
    31  {
    34    nsresult rv;
    32    nsresult rv;
    35    nsCOMPtr<nsIProperties> dirSvc(do_GetService(NS_DIRECTORY_SERVICE_CONTRACTID, &rv));
    33    nsCOMPtr<nsIProperties> dirSvc(
    36    if (NS_FAILED(rv))
    34      do_GetService(NS_DIRECTORY_SERVICE_CONTRACTID, &rv));
       
    35    if (NS_FAILED(rv)) {
    37      return rv;
    36      return rv;
       
    37    }
    38  
    38  
    39 +  // make sure we load these special files after all the others
    39 +  // make sure we load these special files after all the others
    40 +  static const char* specialFiles[] = {
    40 +  static const char* specialFiles[] = {
    41 +#if defined(XP_UNIX)
    41 +#if defined(XP_UNIX)
    42 +    ""
    42 +    ""
    53 +      }
    53 +      }
    54 +    }
    54 +    }
    55 +  }
    55 +  }
    56 +
    56 +
    57    nsCOMPtr<nsISimpleEnumerator> list;
    57    nsCOMPtr<nsISimpleEnumerator> list;
    58    dirSvc->Get(listId,
    58    dirSvc->Get(aListId, NS_GET_IID(nsISimpleEnumerator), getter_AddRefs(list));
    59                NS_GET_IID(nsISimpleEnumerator),
    59    if (!list) {
    60                getter_AddRefs(list));
       
    61    if (!list)
       
    62      return NS_OK;
    60      return NS_OK;
       
    61    }
    63  
    62  
    64    bool hasMore;
    63    bool hasMore;
    65 @@ -1438,17 +1457,17 @@ static nsresult pref_LoadPrefsInDirList(
    64    while (NS_SUCCEEDED(list->HasMoreElements(&hasMore)) && hasMore) {
    66  
    65 @@ -4344,17 +4363,17 @@ pref_LoadPrefsInDirList(const char* aLis
    67      nsAutoCString leaf;
    66      }
    68      path->GetNativeLeafName(leaf);
    67  
       
    68      nsCOMPtr<nsIFile> path = do_QueryInterface(elem);
       
    69      if (!path) {
       
    70        continue;
       
    71      }
    69  
    72  
    70      // Do we care if a file provided by this process fails to load?
    73      // Do we care if a file provided by this process fails to load?
    71      if (Substring(leaf, leaf.Length() - 4).EqualsLiteral(".xpi"))
    74 -    pref_LoadPrefsInDir(path, nullptr, 0);
    72        ReadExtensionPrefs(path);
    75 +    pref_LoadPrefsInDir(path, specialFiles, nullptr, 0);
    73      else
       
    74 -      pref_LoadPrefsInDir(path, nullptr, 0);
       
    75 +      pref_LoadPrefsInDir(path, specialFiles, MOZ_ARRAY_LENGTH(specialFiles));
       
    76    }
    76    }
       
    77  
    77    return NS_OK;
    78    return NS_OK;
    78  }
    79  }
    79  
    80  
    80  static nsresult pref_ReadPrefFromJar(nsZipArchive* jarReader, const char *name)
    81  static nsresult
       
    82  pref_ReadPrefFromJar(nsZipArchive* aJarReader, const char* aName)
    81  {
    83  {
    82    nsCString manifest;
    84 @@ -4461,25 +4480,37 @@ pref_InitInitialObjects()
    83    MOZ_TRY_VAR(manifest, URLPreloader::ReadZip(jarReader, nsDependentCString(name)));
    85    // application pref files for backwards compatibility.
    84 @@ -1544,24 +1563,36 @@ pref_InitInitialObjects()
       
    85    /* these pref file names should not be used: we process them after all other application pref files for backwards compatibility */
       
    86    static const char* specialFiles[] = {
    86    static const char* specialFiles[] = {
    87  #if defined(XP_MACOSX)
    87  #if defined(XP_MACOSX)
    88      "macprefs.js"
    88      "macprefs.js"
    89  #elif defined(XP_WIN)
    89  #elif defined(XP_WIN)
    90      "winpref.js"
    90      "winpref.js"
    91  #elif defined(XP_UNIX)
    91  #elif defined(XP_UNIX)
    92      "unix.js"
    92      "unix.js"
    93 +    , "" // placeholder for KDE  (empty is otherwise harmless)
    93 +    , "" // placeholder for KDE  (empty is otherwise harmless)
    94  #if defined(_AIX)
    94  #if defined(_AIX)
    95      , "aix.js"
    95      ,
       
    96      "aix.js"
    96  #endif
    97  #endif
    97  #elif defined(XP_BEOS)
    98  #elif defined(XP_BEOS)
    98      "beos.js"
    99      "beos.js"
    99  #endif
   100  #endif
   100    };
   101    };
   108 +        break;
   109 +        break;
   109 +      }
   110 +      }
   110 +    }
   111 +    }
   111 +  }
   112 +  }
   112 +
   113 +
   113    rv = pref_LoadPrefsInDir(defaultPrefDir, specialFiles, ArrayLength(specialFiles));
   114    rv = pref_LoadPrefsInDir(
   114    if (NS_FAILED(rv))
   115      defaultPrefDir, specialFiles, ArrayLength(specialFiles));
       
   116    if (NS_FAILED(rv)) {
   115      NS_WARNING("Error parsing application default preferences.");
   117      NS_WARNING("Error parsing application default preferences.");
       
   118    }
   116  
   119  
   117    // Load jar:$app/omni.jar!/defaults/preferences/*.js
   120    // Load jar:$app/omni.jar!/defaults/preferences/*.js
   118    // or jar:$gre/omni.jar!/defaults/preferences/*.js.
   121    // or jar:$gre/omni.jar!/defaults/preferences/*.js.
   119    RefPtr<nsZipArchive> appJarReader = mozilla::Omnijar::GetReader(mozilla::Omnijar::APP);
       
   120    // GetReader(mozilla::Omnijar::APP) returns null when $app == $gre, in which
       
   121 diff --git a/modules/libpref/moz.build b/modules/libpref/moz.build
   122 diff --git a/modules/libpref/moz.build b/modules/libpref/moz.build
   122 --- a/modules/libpref/moz.build
   123 --- a/modules/libpref/moz.build
   123 +++ b/modules/libpref/moz.build
   124 +++ b/modules/libpref/moz.build
   124 @@ -31,16 +31,20 @@ EXPORTS.mozilla += [
   125 @@ -27,16 +27,20 @@ XPIDL_MODULE = 'pref'
       
   126  EXPORTS.mozilla += [
       
   127      'Preferences.h',
       
   128  ]
       
   129  
   125  UNIFIED_SOURCES += [
   130  UNIFIED_SOURCES += [
   126      'nsPrefBranch.cpp',
       
   127      'nsPrefsFactory.cpp',
       
   128      'prefapi.cpp',
       
   129      'Preferences.cpp',
   131      'Preferences.cpp',
   130      'prefread.cpp',
       
   131  ]
   132  ]
   132  
   133  
   133 +LOCAL_INCLUDES += [
   134 +LOCAL_INCLUDES += [
   134 +     '/toolkit/xre'
   135 +     '/toolkit/xre'
   135 +]
   136 +]
   185          self.base = base
   186          self.base = base
   186          self.flags = Flags(*flags)
   187          self.flags = Flags(*flags)
   187 diff --git a/toolkit/components/downloads/moz.build b/toolkit/components/downloads/moz.build
   188 diff --git a/toolkit/components/downloads/moz.build b/toolkit/components/downloads/moz.build
   188 --- a/toolkit/components/downloads/moz.build
   189 --- a/toolkit/components/downloads/moz.build
   189 +++ b/toolkit/components/downloads/moz.build
   190 +++ b/toolkit/components/downloads/moz.build
   190 @@ -37,16 +37,17 @@ UNIFIED_SOURCES += [
   191 @@ -17,9 +17,13 @@ XPIDL_SOURCES += [
       
   192  XPIDL_MODULE = 'downloads'
       
   193  
       
   194  UNIFIED_SOURCES += [
   191      'nsDownloadManager.cpp'
   195      'nsDownloadManager.cpp'
   192  ]
   196  ]
   193  
   197  
   194  FINAL_LIBRARY = 'xul'
   198  FINAL_LIBRARY = 'xul'
   195  
   199  
   196  LOCAL_INCLUDES += [
   200 +LOCAL_INCLUDES += [
   197      '../protobuf',
   201 +    '/toolkit/xre'
   198      '/ipc/chromium/src',
   202 +]
   199 +    '/toolkit/xre',
   203 +
   200      'chromium'
       
   201  ]
       
   202  
       
   203  DEFINES['GOOGLE_PROTOBUF_NO_RTTI'] = True
       
   204  DEFINES['GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER'] = True
       
   205  
       
   206  CXXFLAGS += CONFIG['TK_CFLAGS']
   204  CXXFLAGS += CONFIG['TK_CFLAGS']
   207  
       
   208 diff --git a/toolkit/content/jar.mn b/toolkit/content/jar.mn
   205 diff --git a/toolkit/content/jar.mn b/toolkit/content/jar.mn
   209 --- a/toolkit/content/jar.mn
   206 --- a/toolkit/content/jar.mn
   210 +++ b/toolkit/content/jar.mn
   207 +++ b/toolkit/content/jar.mn
   211 @@ -75,29 +75,33 @@ toolkit.jar:
   208 @@ -75,29 +75,33 @@ toolkit.jar:
   212     content/global/bindings/colorpicker.xml     (widgets/colorpicker.xml)
   209     content/global/bindings/colorpicker.xml     (widgets/colorpicker.xml)
   244     content/global/bindings/scrollbox.xml       (widgets/scrollbox.xml)
   241     content/global/bindings/scrollbox.xml       (widgets/scrollbox.xml)
   245 diff --git a/toolkit/content/widgets/dialog-kde.xml b/toolkit/content/widgets/dialog-kde.xml
   242 diff --git a/toolkit/content/widgets/dialog-kde.xml b/toolkit/content/widgets/dialog-kde.xml
   246 new file mode 100644
   243 new file mode 100644
   247 --- /dev/null
   244 --- /dev/null
   248 +++ b/toolkit/content/widgets/dialog-kde.xml
   245 +++ b/toolkit/content/widgets/dialog-kde.xml
   249 @@ -0,0 +1,455 @@
   246 @@ -0,0 +1,459 @@
   250 +<?xml version="1.0"?>
   247 +<?xml version="1.0"?>
   251 +<!-- This Source Code Form is subject to the terms of the Mozilla Public
   248 +<!-- This Source Code Form is subject to the terms of the Mozilla Public
   252 +   - License, v. 2.0. If a copy of the MPL was not distributed with this
   249 +   - License, v. 2.0. If a copy of the MPL was not distributed with this
   253 +   - file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
   250 +   - file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
   254 +
   251 +
   432 +                var initialFocusedElt = focusedElt;
   429 +                var initialFocusedElt = focusedElt;
   433 +                while (focusedElt.localName == "tab" ||
   430 +                while (focusedElt.localName == "tab" ||
   434 +                       focusedElt.getAttribute("noinitialfocus") == "true") {
   431 +                       focusedElt.getAttribute("noinitialfocus") == "true") {
   435 +                  document.commandDispatcher.advanceFocusIntoSubtree(focusedElt);
   432 +                  document.commandDispatcher.advanceFocusIntoSubtree(focusedElt);
   436 +                  focusedElt = document.commandDispatcher.focusedElement;
   433 +                  focusedElt = document.commandDispatcher.focusedElement;
   437 +                  if (focusedElt == initialFocusedElt)
   434 +                  if (focusedElt == initialFocusedElt) {
       
   435 +                    if (focusedElt.getAttribute("noinitialfocus") == "true") {
       
   436 +                      focusedElt.blur();
       
   437 +                    }
   438 +                    break;
   438 +                    break;
       
   439 +                  }
   439 +                }
   440 +                }
   440 +
   441 +
   441 +                if (initialFocusedElt.localName == "tab") {
   442 +                if (initialFocusedElt.localName == "tab") {
   442 +                  if (focusedElt.hasAttribute("dlgtype")) {
   443 +                  if (focusedElt.hasAttribute("dlgtype")) {
   443 +                    // We don't want to focus on anonymous OK, Cancel, etc. buttons,
   444 +                    // We don't want to focus on anonymous OK, Cancel, etc. buttons,
  2117 +#    PrefWindow I   (June 4, 1999)
  2118 +#    PrefWindow I   (June 4, 1999)
  2118 +#
  2119 +#
  2119 diff --git a/toolkit/mozapps/downloads/nsHelperAppDlg.js b/toolkit/mozapps/downloads/nsHelperAppDlg.js
  2120 diff --git a/toolkit/mozapps/downloads/nsHelperAppDlg.js b/toolkit/mozapps/downloads/nsHelperAppDlg.js
  2120 --- a/toolkit/mozapps/downloads/nsHelperAppDlg.js
  2121 --- a/toolkit/mozapps/downloads/nsHelperAppDlg.js
  2121 +++ b/toolkit/mozapps/downloads/nsHelperAppDlg.js
  2122 +++ b/toolkit/mozapps/downloads/nsHelperAppDlg.js
  2122 @@ -628,17 +628,17 @@ nsUnknownContentTypeDialog.prototype = {
  2123 @@ -626,17 +626,17 @@ nsUnknownContentTypeDialog.prototype = {
  2123        else
  2124        else
  2124          typeString = mimeInfo.MIMEType;
  2125          typeString = mimeInfo.MIMEType;
  2125      }
  2126      }
  2126      // When the length is unknown, contentLength would be -1
  2127      // When the length is unknown, contentLength would be -1
  2127      if (this.mLauncher.contentLength >= 0) {
  2128      if (this.mLauncher.contentLength >= 0) {
  2136        type.value = typeString;
  2137        type.value = typeString;
  2137      }
  2138      }
  2138    },
  2139    },
  2139  
  2140  
  2140    // Returns true if opening the default application makes sense.
  2141    // Returns true if opening the default application makes sense.
  2141 @@ -802,17 +802,17 @@ nsUnknownContentTypeDialog.prototype = {
  2142 @@ -800,17 +800,17 @@ nsUnknownContentTypeDialog.prototype = {
  2142        switch (this.dialogElement("openHandler").selectedIndex) {
  2143        switch (this.dialogElement("openHandler").selectedIndex) {
  2143        case 0:
  2144        case 0:
  2144          // No app need be specified in this case.
  2145          // No app need be specified in this case.
  2145          ok = true;
  2146          ok = true;
  2146          break;
  2147          break;
  2155  
  2156  
  2156      // Enable Ok button if ok to press.
  2157      // Enable Ok button if ok to press.
  2157      this.mDialog.document.documentElement.getButton("accept").disabled = !ok;
  2158      this.mDialog.document.documentElement.getButton("accept").disabled = !ok;
  2158    },
  2159    },
  2159  
  2160  
  2160 @@ -1067,30 +1067,57 @@ nsUnknownContentTypeDialog.prototype = {
  2161 @@ -1065,30 +1065,57 @@ nsUnknownContentTypeDialog.prototype = {
  2161  
  2162  
  2162        if (params.handlerApp &&
  2163        if (params.handlerApp &&
  2163            params.handlerApp.executable &&
  2164            params.handlerApp.executable &&
  2164            params.handlerApp.executable.isFile()) {
  2165            params.handlerApp.executable.isFile()) {
  2165          // Remember the file they chose to run.
  2166          // Remember the file they chose to run.
  2768      UNIFIED_SOURCES += [
  2769      UNIFIED_SOURCES += [
  2769          'android/nsAndroidHandlerApp.cpp',
  2770          'android/nsAndroidHandlerApp.cpp',
  2770          'android/nsExternalSharingAppService.cpp',
  2771          'android/nsExternalSharingAppService.cpp',
  2771          'android/nsExternalURLHandlerService.cpp',
  2772          'android/nsExternalURLHandlerService.cpp',
  2772          'android/nsMIMEInfoAndroid.cpp',
  2773          'android/nsMIMEInfoAndroid.cpp',
  2773 @@ -125,16 +127,17 @@ include('/ipc/chromium/chromium-config.m
  2774 @@ -129,16 +131,17 @@ include('/ipc/chromium/chromium-config.m
  2774  
       
  2775  FINAL_LIBRARY = 'xul'
  2775  FINAL_LIBRARY = 'xul'
  2776  
  2776  
  2777  LOCAL_INCLUDES += [
  2777  LOCAL_INCLUDES += [
       
  2778      '/docshell/base',
  2778      '/dom/base',
  2779      '/dom/base',
  2779      '/dom/ipc',
  2780      '/dom/ipc',
  2780      '/netwerk/base',
  2781      '/netwerk/base',
  2781      '/netwerk/protocol/http',
  2782      '/netwerk/protocol/http',
  2782 +    '/toolkit/xre',
  2783 +    '/toolkit/xre',
  3107    nsresult rv;
  3108    nsresult rv;
  3108    nsCOMPtr<nsIIOService> ioservice = do_GetService(NS_IOSERVICE_CONTRACTID, &rv);
  3109    nsCOMPtr<nsIIOService> ioservice = do_GetService(NS_IOSERVICE_CONTRACTID, &rv);
  3109 diff --git a/uriloader/exthandler/unix/nsOSHelperAppService.cpp b/uriloader/exthandler/unix/nsOSHelperAppService.cpp
  3110 diff --git a/uriloader/exthandler/unix/nsOSHelperAppService.cpp b/uriloader/exthandler/unix/nsOSHelperAppService.cpp
  3110 --- a/uriloader/exthandler/unix/nsOSHelperAppService.cpp
  3111 --- a/uriloader/exthandler/unix/nsOSHelperAppService.cpp
  3111 +++ b/uriloader/exthandler/unix/nsOSHelperAppService.cpp
  3112 +++ b/uriloader/exthandler/unix/nsOSHelperAppService.cpp
  3112 @@ -10,17 +10,17 @@
  3113 @@ -5,17 +5,17 @@
  3113  #if defined(MOZ_ENABLE_CONTENTACTION)
  3114   * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
  3114  #include <contentaction/contentaction.h>
  3115  
  3115  #include <QString>
  3116  #include <sys/types.h>
  3116  #endif
  3117  #include <sys/stat.h>
  3117  
  3118  
  3118  #include "nsOSHelperAppService.h"
  3119  #include "nsOSHelperAppService.h"
  3119  #include "nsMIMEInfoUnix.h"
  3120  #include "nsMIMEInfoUnix.h"
  3120  #ifdef MOZ_WIDGET_GTK
  3121  #ifdef MOZ_WIDGET_GTK
  3121 -#include "nsGNOMERegistry.h"
  3122 -#include "nsGNOMERegistry.h"
  3126  #include "nsReadableUtils.h"
  3127  #include "nsReadableUtils.h"
  3127  #include "nsUnicharUtils.h"
  3128  #include "nsUnicharUtils.h"
  3128  #include "nsIURL.h"
  3129  #include "nsIURL.h"
  3129  #include "nsIFileStreams.h"
  3130  #include "nsIFileStreams.h"
  3130  #include "nsILineInputStream.h"
  3131  #include "nsILineInputStream.h"
  3131 @@ -1142,26 +1142,26 @@ nsresult nsOSHelperAppService::OSProtoco
  3132 @@ -1128,17 +1128,17 @@ nsOSHelperAppService::GetHandlerAndDescr
  3132      ContentAction::Action::defaultActionForScheme(QString(aProtocolScheme) + ':');
  3133  
  3133  
  3134  nsresult nsOSHelperAppService::OSProtocolHandlerExists(const char * aProtocolScheme, bool * aHandlerExists)
  3134    if (action.isValid())
  3135  {
  3135      *aHandlerExists = true;
  3136    nsresult rv = NS_OK;
       
  3137  
       
  3138    if (!XRE_IsContentProcess()) {
       
  3139  #ifdef MOZ_WIDGET_GTK
       
  3140      // Check the GNOME registry for a protocol handler
       
  3141 -    *aHandlerExists = nsGNOMERegistry::HandlerExists(aProtocolScheme);
       
  3142 +    *aHandlerExists = nsCommonRegistry::HandlerExists(aProtocolScheme);
       
  3143  #else
       
  3144      *aHandlerExists = false;
  3136  #endif
  3145  #endif
  3137  
  3146    } else {
  3138  #ifdef MOZ_WIDGET_GTK
  3147      *aHandlerExists = false;
  3139    // Check the GNOME registry for a protocol handler
  3148      nsCOMPtr<nsIHandlerService> handlerSvc = do_GetService(NS_HANDLERSERVICE_CONTRACTID, &rv);
  3140 -  *aHandlerExists = nsGNOMERegistry::HandlerExists(aProtocolScheme);
  3149      if (NS_SUCCEEDED(rv) && handlerSvc) {
  3141 +  *aHandlerExists = nsCommonRegistry::HandlerExists(aProtocolScheme);
  3150        rv = handlerSvc->ExistsForProtocol(nsCString(aProtocolScheme), aHandlerExists);
  3142  #endif
  3151 @@ -1146,17 +1146,17 @@ nsresult nsOSHelperAppService::OSProtoco
  3143  
  3152    }
  3144    return NS_OK;
  3153  
       
  3154    return rv;
  3145  }
  3155  }
  3146  
  3156  
  3147  NS_IMETHODIMP nsOSHelperAppService::GetApplicationDescription(const nsACString& aScheme, nsAString& _retval)
  3157  NS_IMETHODIMP nsOSHelperAppService::GetApplicationDescription(const nsACString& aScheme, nsAString& _retval)
  3148  {
  3158  {
  3149  #ifdef MOZ_WIDGET_GTK
  3159  #ifdef MOZ_WIDGET_GTK
  3155  #endif
  3165  #endif
  3156  }
  3166  }
  3157  
  3167  
  3158  nsresult nsOSHelperAppService::GetFileTokenForPath(const char16_t * platformAppPath, nsIFile ** aFile)
  3168  nsresult nsOSHelperAppService::GetFileTokenForPath(const char16_t * platformAppPath, nsIFile ** aFile)
  3159  {
  3169  {
  3160 @@ -1248,17 +1248,17 @@ nsOSHelperAppService::GetFromExtension(c
  3170 @@ -1243,17 +1243,17 @@ nsOSHelperAppService::GetFromExtension(c
  3161                                           mime_types_description,
  3171                                           mime_types_description,
  3162                                           true);
  3172                                           true);
  3163  
  3173  
  3164    if (NS_FAILED(rv) || majorType.IsEmpty()) {
  3174    if (NS_FAILED(rv) || majorType.IsEmpty()) {
  3165  
  3175  
  3174      }
  3184      }
  3175  #endif
  3185  #endif
  3176  
  3186  
  3177      rv = LookUpTypeAndDescription(NS_ConvertUTF8toUTF16(aFileExt),
  3187      rv = LookUpTypeAndDescription(NS_ConvertUTF8toUTF16(aFileExt),
  3178                                    majorType,
  3188                                    majorType,
  3179 @@ -1369,17 +1369,17 @@ nsOSHelperAppService::GetFromType(const 
  3189 @@ -1364,17 +1364,17 @@ nsOSHelperAppService::GetFromType(const 
  3180    nsAutoString extensions, mime_types_description;
  3190    nsAutoString extensions, mime_types_description;
  3181    LookUpExtensionsAndDescription(majorType,
  3191    LookUpExtensionsAndDescription(majorType,
  3182                                   minorType,
  3192                                   minorType,
  3183                                   extensions,
  3193                                   extensions,
  3184                                   mime_types_description);
  3194                                   mime_types_description);