mozilla-kde.patch
branchmozilla-1.9.2
changeset 174 b3f909e83302
parent 95 37558f4844c0
child 246 ea1f88b778f7
equal deleted inserted replaced
160:2a08bb18befb 174:b3f909e83302
  3451      nsCAutoString ext;
  3451      nsCAutoString ext;
  3452      GetPrimaryExtension(ext);
  3452      GetPrimaryExtension(ext);
  3453 -    mimeInfo = nsGNOMERegistry::GetFromExtension(ext);
  3453 -    mimeInfo = nsGNOMERegistry::GetFromExtension(ext);
  3454 +    mimeInfo = nsCommonRegistry::GetFromExtension(ext);
  3454 +    mimeInfo = nsCommonRegistry::GetFromExtension(ext);
  3455    }
  3455    }
  3456  
       
  3457    if (mimeInfo)
  3456    if (mimeInfo)
  3458      *_retval = PR_TRUE;
  3457      *_retval = PR_TRUE;
  3459  
  3458  
  3460    if (*_retval)
  3459    if (*_retval)
  3461      return NS_OK;
  3460      return NS_OK;
  3462  
  3461  
  3463 @@ -107,25 +110,42 @@ nsMIMEInfoUnix::LaunchDefaultWithFile(ns
  3462  #if (MOZ_PLATFORM_MAEMO == 5) && defined (MOZ_ENABLE_GNOMEVFS)
       
  3463 @@ -106,26 +109,43 @@ nsMIMEInfoUnix::LaunchDefaultWithFile(ns
  3464    nsCAutoString nativePath;
  3464    nsCAutoString nativePath;
  3465    aFile->GetNativePath(nativePath);
  3465    aFile->GetNativePath(nativePath);
  3466  
  3466  
  3467  #if (MOZ_PLATFORM_MAEMO == 5) && defined (MOZ_ENABLE_GNOMEVFS)
  3467  #if (MOZ_PLATFORM_MAEMO == 5) && defined (MOZ_ENABLE_GNOMEVFS)
  3468    if(NS_SUCCEEDED(LaunchDefaultWithDBus(PromiseFlatCString(nativePath).get())))
  3468    if(NS_SUCCEEDED(LaunchDefaultWithDBus(PromiseFlatCString(nativePath).get())))
  3489    nsCOMPtr<nsIGnomeVFSService> vfs = do_GetService(NS_GNOMEVFSSERVICE_CONTRACTID);
  3489    nsCOMPtr<nsIGnomeVFSService> vfs = do_GetService(NS_GNOMEVFSSERVICE_CONTRACTID);
  3490    if (vfs) {
  3490    if (vfs) {
  3491      nsCOMPtr<nsIGnomeVFSMimeApp> app;
  3491      nsCOMPtr<nsIGnomeVFSMimeApp> app;
  3492      if (NS_SUCCEEDED(vfs->GetAppForMimeType(mType, getter_AddRefs(app))) && app)
  3492      if (NS_SUCCEEDED(vfs->GetAppForMimeType(mType, getter_AddRefs(app))) && app)
  3493        return app->Launch(nativePath);
  3493        return app->Launch(nativePath);
  3494  
  3494    }
  3495      // If we haven't got an app we try to get a valid one by searching for the
  3495  
  3496      // extension mapped type
  3496    // If we haven't got an app we try to get a valid one by searching for the
  3497 -    nsRefPtr<nsMIMEInfoBase> mimeInfo = nsGNOMERegistry::GetFromExtension(nativePath);
  3497    // extension mapped type
  3498 +    nsRefPtr<nsMIMEInfoBase> mimeInfo = nsCommonRegistry::GetFromExtension(nativePath);
  3498 -  nsRefPtr<nsMIMEInfoBase> mimeInfo = nsGNOMERegistry::GetFromExtension(nativePath);
  3499      if (mimeInfo) {
  3499 +  nsRefPtr<nsMIMEInfoBase> mimeInfo = nsCommonRegistry::GetFromExtension(nativePath);
  3500        nsCAutoString type;
  3500    if (mimeInfo) {
  3501        mimeInfo->GetType(type);
  3501      nsCAutoString type;
       
  3502      mimeInfo->GetType(type);
       
  3503      if (vfs) {
       
  3504        nsCOMPtr<nsIGnomeVFSMimeApp> app;
  3502        if (NS_SUCCEEDED(vfs->GetAppForMimeType(type, getter_AddRefs(app))) && app)
  3505        if (NS_SUCCEEDED(vfs->GetAppForMimeType(type, getter_AddRefs(app))) && app)
  3503          return app->Launch(nativePath);
  3506          return app->Launch(nativePath);
  3504      }
  3507      }
  3505    }
       
  3506  
       
  3507 diff --git a/uriloader/exthandler/unix/nsOSHelperAppService.cpp b/uriloader/exthandler/unix/nsOSHelperAppService.cpp
  3508 diff --git a/uriloader/exthandler/unix/nsOSHelperAppService.cpp b/uriloader/exthandler/unix/nsOSHelperAppService.cpp
  3508 --- a/uriloader/exthandler/unix/nsOSHelperAppService.cpp
  3509 --- a/uriloader/exthandler/unix/nsOSHelperAppService.cpp
  3509 +++ b/uriloader/exthandler/unix/nsOSHelperAppService.cpp
  3510 +++ b/uriloader/exthandler/unix/nsOSHelperAppService.cpp
  3510 @@ -39,17 +39,17 @@
  3511 @@ -39,17 +39,17 @@
  3511   * ***** END LICENSE BLOCK ***** */
  3512   * ***** END LICENSE BLOCK ***** */
  3960  
  3961  
  3961  LOCAL_INCLUDES	= -I..
  3962  LOCAL_INCLUDES	= -I..
  3962 +LOCAL_INCLUDES += -I$(topsrcdir)/toolkit/xre
  3963 +LOCAL_INCLUDES += -I$(topsrcdir)/toolkit/xre
  3963  
  3964  
  3964  ifeq ($(MOZ_PLATFORM_MAEMO), 5)
  3965  ifeq ($(MOZ_PLATFORM_MAEMO), 5)
  3965  CFLAGS          += $(MOZ_DBUS_GLIB_CFLAGS) $(MOZ_PLATFORM_MAEMO_CFLAGS)
  3966  CFLAGS          += $(MOZ_DBUS_CFLAGS) $(MOZ_PLATFORM_MAEMO_CFLAGS)
  3966  CXXFLAGS        += $(MOZ_DBUS_GLIB_CFLAGS) $(MOZ_PLATFORM_MAEMO_CFLAGS)
  3967  CXXFLAGS        += $(MOZ_DBUS_CFLAGS) $(MOZ_PLATFORM_MAEMO_CFLAGS)
  3967  endif
  3968  endif
  3968  
  3969  
  3969 diff --git a/xpcom/io/nsLocalFileUnix.cpp b/xpcom/io/nsLocalFileUnix.cpp
  3970 diff --git a/xpcom/io/nsLocalFileUnix.cpp b/xpcom/io/nsLocalFileUnix.cpp
  3970 --- a/xpcom/io/nsLocalFileUnix.cpp
  3971 --- a/xpcom/io/nsLocalFileUnix.cpp
  3971 +++ b/xpcom/io/nsLocalFileUnix.cpp
  3972 +++ b/xpcom/io/nsLocalFileUnix.cpp