зеркало из https://github.com/mozilla/pjs.git
Removing non-compliant text/xul mimetype, replacing with application/vnd.mozilla.xul+xml (28237, patch by gerv@gerv.net). r=blake sr=hyatt
This commit is contained in:
Родитель
491440dfba
Коммит
7b5a59b32d
|
@ -327,7 +327,7 @@ nsCachedChromeChannel::SetNotificationCallbacks(nsIInterfaceRequestor * aNotific
|
|||
NS_IMETHODIMP
|
||||
nsCachedChromeChannel::GetContentType(char * *aContentType)
|
||||
{
|
||||
*aContentType = nsXPIDLCString::Copy("text/cached-xul");
|
||||
*aContentType = nsXPIDLCString::Copy("mozilla.application/cached-xul");
|
||||
return *aContentType ? NS_OK : NS_ERROR_OUT_OF_MEMORY;
|
||||
}
|
||||
|
||||
|
|
|
@ -73,8 +73,8 @@ static char* gXMLTypes[] = {
|
|||
|
||||
static char* gRDFTypes[] = {
|
||||
"text/rdf",
|
||||
"text/xul",
|
||||
"text/cached-xul",
|
||||
"application/vnd.mozilla.xul+xml",
|
||||
"mozilla.application/cached-xul",
|
||||
0
|
||||
};
|
||||
|
||||
|
|
|
@ -339,7 +339,7 @@ static Components gComponents[] = {
|
|||
{ "HTML content serializer", NS_HTMLCONTENTSERIALIZER_CID,
|
||||
NS_CONTENTSERIALIZER_CONTRACTID_PREFIX "text/html", },
|
||||
{ "XUL content serializer", NS_XMLCONTENTSERIALIZER_CID,
|
||||
NS_CONTENTSERIALIZER_CONTRACTID_PREFIX "text/xul", },
|
||||
NS_CONTENTSERIALIZER_CONTRACTID_PREFIX "application/vnd.mozilla.xul+xml", },
|
||||
{ "plaintext content serializer", NS_PLAINTEXTSERIALIZER_CID,
|
||||
NS_CONTENTSERIALIZER_CONTRACTID_PREFIX "text/plain", },
|
||||
{ "plaintext sink", NS_PLAINTEXTSERIALIZER_CID,
|
||||
|
|
|
@ -613,7 +613,7 @@ nsXULDocument::GetArena()
|
|||
NS_IMETHODIMP
|
||||
nsXULDocument::GetContentType(nsAWritableString& aContentType) const
|
||||
{
|
||||
aContentType.Assign(NS_LITERAL_STRING("text/xul"));
|
||||
aContentType.Assign(NS_LITERAL_STRING("application/vnd.mozilla.xul+xml"));
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
|
@ -707,7 +707,8 @@ nsXULDocument::StartDocumentLoad(const char* aCommand,
|
|||
nsXPIDLCString contentType;
|
||||
aChannel->GetContentType(getter_Copies(contentType));
|
||||
|
||||
if (contentType && PL_strcmp(contentType, "text/cached-xul") == 0) {
|
||||
if (contentType &&
|
||||
PL_strcmp(contentType, "mozilla.application/cached-xul") == 0) {
|
||||
// Look in the chrome cache: we've got this puppy loaded
|
||||
// already.
|
||||
nsCOMPtr<nsIXULPrototypeDocument> proto;
|
||||
|
|
|
@ -152,7 +152,7 @@ NS_IMETHODIMP nsDSURIContentListener::CanHandleContent(const char* aContentType,
|
|||
// from the registry and in addition, we want to
|
||||
// incoming Type Preferred type
|
||||
// text/html
|
||||
// text/xul
|
||||
// application/vnd.mozilla.xul+xml
|
||||
// text/rdf
|
||||
// text/xml
|
||||
// text/css
|
||||
|
@ -161,14 +161,14 @@ NS_IMETHODIMP nsDSURIContentListener::CanHandleContent(const char* aContentType,
|
|||
// image/png
|
||||
// image/tiff
|
||||
// application/http-index-format
|
||||
// message/rfc822 text/xul
|
||||
// message/rfc822 application/vnd.mozilla.xul+xml
|
||||
|
||||
if (aContentType)
|
||||
{
|
||||
// (1) list all content types we want to be the primary handler for....
|
||||
// and suggest a desired content type if appropriate...
|
||||
if (nsCRT::strcasecmp(aContentType, "text/html") == 0
|
||||
|| nsCRT::strcasecmp(aContentType, "text/xul") == 0
|
||||
|| nsCRT::strcasecmp(aContentType, "application/vnd.mozilla.xul+xml") == 0
|
||||
|| nsCRT::strcasecmp(aContentType, "text/rdf") == 0
|
||||
|| nsCRT::strcasecmp(aContentType, "text/xml") == 0
|
||||
|| nsCRT::strcasecmp(aContentType, "text/css") == 0
|
||||
|
|
|
@ -96,7 +96,7 @@ EmbedContentListener::IsPreferred(const char *aContentType,
|
|||
if (aContentType &&
|
||||
(!strcasecmp(aContentType, "text/html") ||
|
||||
!strcasecmp(aContentType, "text/plain") ||
|
||||
!strcasecmp(aContentType, "text/xul") ||
|
||||
!strcasecmp(aContentType, "application/vnd.mozilla.xul+xml") ||
|
||||
!strcasecmp(aContentType, "text/rdf") ||
|
||||
!strcasecmp(aContentType, "text/xml") ||
|
||||
!strcasecmp(aContentType, "text/css") ||
|
||||
|
|
|
@ -501,7 +501,7 @@ NS_IMETHODIMP PhMozEmbedChrome::IsPreferred(const char *aContentType, nsURILoadC
|
|||
{
|
||||
PR_LOG(mozEmbedLm, PR_LOG_DEBUG, ("checking content type %s\n", aContentType));
|
||||
if (nsCRT::strcasecmp(aContentType, "text/html") == 0
|
||||
|| nsCRT::strcasecmp(aContentType, "text/xul") == 0
|
||||
|| nsCRT::strcasecmp(aContentType, "application/vnd.mozilla.xul+xml") == 0
|
||||
|| nsCRT::strcasecmp(aContentType, "text/rdf") == 0
|
||||
|| nsCRT::strcasecmp(aContentType, "text/xml") == 0
|
||||
|| nsCRT::strcasecmp(aContentType, "text/css") == 0
|
||||
|
|
|
@ -1,210 +0,0 @@
|
|||
/* -*- Mode: C++; tab-width: 3; indent-tabs-mode: nil; c-basic-offset: 2 -*-
|
||||
*
|
||||
* The contents of this file are subject to the Mozilla Public
|
||||
* License Version 1.1 (the "License"); you may not use this file
|
||||
* except in compliance with the License. You may obtain a copy of
|
||||
* the License at http://www.mozilla.org/MPL/
|
||||
*
|
||||
* Software distributed under the License is distributed on an "AS
|
||||
* IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
|
||||
* implied. See the License for the specific language governing
|
||||
* rights and limitations under the License.
|
||||
*
|
||||
* The Original Code is the Mozilla browser.
|
||||
*
|
||||
* The Initial Developer of the Original Code is Netscape
|
||||
* Communications, Inc. Portions created by Netscape are
|
||||
* Copyright (C) 1999, Mozilla. All Rights Reserved.
|
||||
*
|
||||
* Contributor(s):
|
||||
* Travis Bogard <travis@netscape.com>
|
||||
*/
|
||||
|
||||
// Local Includes
|
||||
#include "nsWebBrowser.h"
|
||||
#include "nsWBURIContentListener.h"
|
||||
|
||||
// Interfaces Needed
|
||||
#include "nsIChannel.h"
|
||||
|
||||
//*****************************************************************************
|
||||
//*** nsWBURIContentListener: Object Management
|
||||
//*****************************************************************************
|
||||
|
||||
nsWBURIContentListener::nsWBURIContentListener() : mWebBrowser(nsnull),
|
||||
mParentContentListener(nsnull)
|
||||
{
|
||||
NS_INIT_REFCNT();
|
||||
}
|
||||
|
||||
nsWBURIContentListener::~nsWBURIContentListener()
|
||||
{
|
||||
}
|
||||
|
||||
//*****************************************************************************
|
||||
// nsWBURIContentListener::nsISupports
|
||||
//*****************************************************************************
|
||||
|
||||
NS_IMPL_ADDREF(nsWBURIContentListener)
|
||||
NS_IMPL_RELEASE(nsWBURIContentListener)
|
||||
|
||||
NS_INTERFACE_MAP_BEGIN(nsWBURIContentListener)
|
||||
NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, nsIURIContentListener)
|
||||
NS_INTERFACE_MAP_ENTRY(nsIURIContentListener)
|
||||
NS_INTERFACE_MAP_END
|
||||
|
||||
//*****************************************************************************
|
||||
// nsWBURIContentListener::nsIURIContentListener
|
||||
//*****************************************************************************
|
||||
|
||||
NS_IMETHODIMP nsWBURIContentListener::OnStartURIOpen(nsIURI* aURI,
|
||||
const char* aWindowTarget, PRBool* aAbortOpen)
|
||||
{
|
||||
if(mParentContentListener)
|
||||
{
|
||||
nsresult rv = mParentContentListener->OnStartURIOpen(aURI, aWindowTarget,
|
||||
aAbortOpen);
|
||||
|
||||
if(NS_ERROR_NOT_IMPLEMENTED != rv)
|
||||
return rv;
|
||||
}
|
||||
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP nsWBURIContentListener::GetProtocolHandler(nsIURI* aURI,
|
||||
nsIProtocolHandler** aProtocolHandler)
|
||||
{
|
||||
NS_ENSURE_ARG_POINTER(aProtocolHandler);
|
||||
NS_ENSURE_ARG(aURI);
|
||||
|
||||
if(mParentContentListener)
|
||||
{
|
||||
nsresult rv = mParentContentListener->GetProtocolHandler(aURI,
|
||||
aProtocolHandler);
|
||||
|
||||
if(NS_ERROR_NOT_IMPLEMENTED != rv)
|
||||
return rv;
|
||||
}
|
||||
*aProtocolHandler = nsnull;
|
||||
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP nsWBURIContentListener::DoContent(const char* aContentType,
|
||||
nsURILoadCommand aCommand, const char* aWindowTarget,
|
||||
nsIRequest* request, nsIStreamListener** aContentHandler,
|
||||
PRBool* aAbortProcess)
|
||||
{
|
||||
NS_ERROR("Hmmmm, why is this getting called on this object?");
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP nsWBURIContentListener::IsPreferred(const char* aContentType,
|
||||
nsURILoadCommand aCommand, const char* aWindowTarget, char ** aDesiredContentType,
|
||||
PRBool* aCanHandle)
|
||||
{
|
||||
NS_ENSURE_ARG_POINTER(aCanHandle);
|
||||
NS_ENSURE_ARG_POINTER(aDesiredContentType);
|
||||
|
||||
if(mParentContentListener)
|
||||
{
|
||||
nsresult rv = mParentContentListener->IsPreferred(aContentType,
|
||||
aCommand, aWindowTarget, aDesiredContentType, aCanHandle);
|
||||
|
||||
if(NS_ERROR_NOT_IMPLEMENTED != rv)
|
||||
return rv;
|
||||
}
|
||||
|
||||
*aCanHandle = PR_FALSE;
|
||||
// the webbrowser object is the primary content handler for the following types:
|
||||
// If we are asked to handle any of these types, we will always say Yes!
|
||||
// regardlesss of the uri load command.
|
||||
// incoming Type Preferred type
|
||||
// text/html
|
||||
// text/xul
|
||||
// text/rdf
|
||||
// text/xml
|
||||
// text/css
|
||||
// image/gif
|
||||
// image/jpeg
|
||||
// image/png
|
||||
// image/tiff
|
||||
// application/http-index-format
|
||||
|
||||
if(aContentType)
|
||||
{
|
||||
// (1) list all content types we want to be the primary handler for....
|
||||
// and suggest a desired content type if appropriate...
|
||||
if(nsCRT::strcasecmp(aContentType, "text/html") == 0
|
||||
|| nsCRT::strcasecmp(aContentType, "text/xul") == 0
|
||||
|| nsCRT::strcasecmp(aContentType, "text/rdf") == 0
|
||||
|| nsCRT::strcasecmp(aContentType, "text/xml") == 0
|
||||
|| nsCRT::strcasecmp(aContentType, "text/css") == 0
|
||||
|| nsCRT::strcasecmp(aContentType, "image/gif") == 0
|
||||
|| nsCRT::strcasecmp(aContentType, "image/jpeg") == 0
|
||||
|| nsCRT::strcasecmp(aContentType, "image/png") == 0
|
||||
|| nsCRT::strcasecmp(aContentType, "image/tiff") == 0
|
||||
|| nsCRT::strcasecmp(aContentType, "application/http-index-format") == 0)
|
||||
*aCanHandle = PR_TRUE;
|
||||
}
|
||||
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP nsWBURIContentListener::CanHandleContent(const char* aContentType,
|
||||
nsURILoadCommand aCommand, const char* aWindowTarget, char ** aDesiredContentType,
|
||||
PRBool* aCanHandleContent)
|
||||
{
|
||||
NS_ERROR("Hmmmm, why is this getting called?");
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP nsWBURIContentListener::GetLoadCookie(nsISupports ** aLoadCookie)
|
||||
{
|
||||
NS_ENSURE_ARG_POINTER(aLoadCookie);
|
||||
*aLoadCookie = nsnull;
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP nsWBURIContentListener::SetLoadCookie(nsISupports * aLoadCookie)
|
||||
{
|
||||
NS_ERROR("Hmmmm, why is this getting called?");
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP nsWBURIContentListener::GetParentContentListener(nsIURIContentListener**
|
||||
aParentListener)
|
||||
{
|
||||
NS_ENSURE_ARG_POINTER(aParentListener);
|
||||
|
||||
*aParentListener = mParentContentListener;
|
||||
NS_IF_ADDREF(*aParentListener);
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP nsWBURIContentListener::SetParentContentListener(nsIURIContentListener*
|
||||
aParentListener)
|
||||
{
|
||||
// Weak Reference, don't addref
|
||||
mParentContentListener = aParentListener;
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
//*****************************************************************************
|
||||
// nsWBURIContentListener: Helpers
|
||||
//*****************************************************************************
|
||||
|
||||
//*****************************************************************************
|
||||
// nsWBURIContentListener: Accessors
|
||||
//*****************************************************************************
|
||||
|
||||
void nsWBURIContentListener::WebBrowser(nsWebBrowser* aWebBrowser)
|
||||
{
|
||||
mWebBrowser = aWebBrowser;
|
||||
}
|
||||
|
||||
nsWebBrowser* nsWBURIContentListener::WebBrowser()
|
||||
{
|
||||
return mWebBrowser;
|
||||
}
|
|
@ -251,7 +251,7 @@ ImageConsumer::CanHandleContent(const char * aContentType,
|
|||
// if we had a webshell or doc shell around, we'd pass this call
|
||||
// through to it...but we don't =(
|
||||
if (!nsCRT::strcasecmp(aContentType, "message/rfc822"))
|
||||
*aDesiredContentType = nsCRT::strdup("text/xul");
|
||||
*aDesiredContentType = nsCRT::strdup("application/vnd.mozilla.xul+xml");
|
||||
// since we explicilty loaded the url, we always want to handle it!
|
||||
*aCanHandleContent = PR_TRUE;
|
||||
|
||||
|
|
|
@ -354,7 +354,7 @@ const PRUnichar kNullCh = '\0';
|
|||
|
||||
#define kHTMLTextContentType "text/html"
|
||||
#define kXMLTextContentType "text/xml"
|
||||
#define kXULTextContentType "text/xul"
|
||||
#define kXULTextContentType "application/vnd.mozilla.xul+xml"
|
||||
#define kRDFTextContentType "text/rdf"
|
||||
#define kXIFTextContentType "text/xif"
|
||||
#define kPlainTextContentType "text/plain"
|
||||
|
|
|
@ -73,8 +73,8 @@ static char* gXMLTypes[] = {
|
|||
|
||||
static char* gRDFTypes[] = {
|
||||
"text/rdf",
|
||||
"text/xul",
|
||||
"text/cached-xul",
|
||||
"application/vnd.mozilla.xul+xml",
|
||||
"mozilla.application/cached-xul",
|
||||
0
|
||||
};
|
||||
|
||||
|
|
|
@ -75,8 +75,8 @@ static char* gXMLTypes[] = {
|
|||
|
||||
static char* gRDFTypes[] = {
|
||||
"text/rdf",
|
||||
"text/xul",
|
||||
"text/cached-xul",
|
||||
"application/vnd.mozilla.xul+xml",
|
||||
"mozilla.application/cached-xul",
|
||||
0
|
||||
};
|
||||
|
||||
|
|
|
@ -598,7 +598,7 @@ nsMessenger::SaveAttachment(nsIFileSpec * fileSpec,
|
|||
if (NS_FAILED(rv)) goto done;
|
||||
|
||||
from.AssignWithConversion(MESSAGE_RFC822);
|
||||
to.AssignWithConversion("text/xul");
|
||||
to.AssignWithConversion("application/vnd.mozilla.xul+xml");
|
||||
|
||||
channelSupport = do_QueryInterface(aListener->m_channel);
|
||||
|
||||
|
|
|
@ -214,7 +214,7 @@ nsMsgQuote::QuoteMessage(const char *msgURI, PRBool quoteHeaders, nsIStreamListe
|
|||
|
||||
nsCOMPtr<nsIStreamListener> convertedListener;
|
||||
rv = streamConverterService->AsyncConvertData(NS_LITERAL_STRING("message/rfc822").get(),
|
||||
NS_LITERAL_STRING("text/xul").get(),
|
||||
NS_LITERAL_STRING("application/vnd.mozilla.xul+xml").get(),
|
||||
mStreamListener,
|
||||
quoteSupport,
|
||||
getter_AddRefs(convertedListener));
|
||||
|
|
|
@ -27,7 +27,7 @@
|
|||
"@mozilla.org/messenger/headerparser;1"
|
||||
|
||||
#define NS_MAILNEWS_MIME_STREAM_CONVERTER_CONTRACTID \
|
||||
NS_ISTREAMCONVERTER_KEY "?from=message/rfc822&to=text/xul"
|
||||
NS_ISTREAMCONVERTER_KEY "?from=message/rfc822&to=application/vnd.mozilla.xul+xml"
|
||||
|
||||
#define NS_MAILNEWS_MIME_STREAM_CONVERTER_CONTRACTID1 \
|
||||
NS_ISTREAMCONVERTER_KEY "?from=message/rfc822&to=text/html"
|
||||
|
|
|
@ -52,7 +52,7 @@
|
|||
{ 0xa4, 0x11, 0x0, 0x80, 0x5f, 0x61, 0x3c, 0x79 } }
|
||||
|
||||
#define NS_XUL_MIME_EMITTER_CONTRACTID \
|
||||
NS_MIME_EMITTER_CONTRACTID_PREFIX "text/xul"
|
||||
NS_MIME_EMITTER_CONTRACTID_PREFIX "application/vnd.mozilla.xul+xml"
|
||||
// {FAA8AF16-DCFF-11d2-A411-00805F613C19}
|
||||
#define NS_XUL_MIME_EMITTER_CID \
|
||||
{ 0xfaa8af16, 0xdcff, 0x11d2, \
|
||||
|
|
|
@ -425,13 +425,14 @@ nsStreamConverter::DetermineOutputFormat(const char *url, nsMimeOutputType *aNe
|
|||
{
|
||||
// okay, we are just doing a regular message display url
|
||||
// since we didn't have any special extensions after the url...
|
||||
// we need to know if we need to use the text/xul or text/html emitter.
|
||||
// we need to know if we need to use the application/vnd.mozilla.xul+xml
|
||||
// or text/html emitter.
|
||||
// check the desired output content type that was passed into AsyncConvertData.
|
||||
|
||||
if (mDesiredOutputType && nsCRT::strcasecmp(mDesiredOutputType, "text/xul") == 0)
|
||||
if (mDesiredOutputType && nsCRT::strcasecmp(mDesiredOutputType, "application/vnd.mozilla.xul+xml") == 0)
|
||||
{
|
||||
CRTFREEIF(mOutputFormat);
|
||||
mOutputFormat = nsCRT::strdup("text/xul");
|
||||
mOutputFormat = nsCRT::strdup("application/vnd.mozilla.xul+xml");
|
||||
*aNewType = nsMimeOutput::nsMimeMessageXULDisplay;
|
||||
}
|
||||
else
|
||||
|
@ -557,7 +558,7 @@ NS_IMETHODIMP nsStreamConverter::Init(nsIURI *aURI, nsIStreamListener * aOutList
|
|||
{
|
||||
case nsMimeOutput::nsMimeMessageXULDisplay:
|
||||
CRTFREEIF(mOutputFormat);
|
||||
mOutputFormat = nsCRT::strdup("text/xul");
|
||||
mOutputFormat = nsCRT::strdup("application/vnd.mozilla.xul+xml");
|
||||
break;
|
||||
case nsMimeOutput::nsMimeMessageSplitDisplay: // the wrapper HTML output to produce the split header/body display
|
||||
mWrapperOutput = PR_TRUE;
|
||||
|
|
|
@ -112,7 +112,7 @@
|
|||
#define TEXT_JSSS "text/jsss"
|
||||
#define TEXT_XML "text/xml"
|
||||
#define TEXT_RDF "text/rdf"
|
||||
#define TEXT_XUL "text/xul"
|
||||
#define TEXT_XUL "application/vnd.mozilla.xul+xml"
|
||||
#define TEXT_RTF "text/rtf"
|
||||
#define TEXT_CPP "text/cpp"
|
||||
|
||||
|
|
|
@ -354,7 +354,7 @@ const PRUnichar kNullCh = '\0';
|
|||
|
||||
#define kHTMLTextContentType "text/html"
|
||||
#define kXMLTextContentType "text/xml"
|
||||
#define kXULTextContentType "text/xul"
|
||||
#define kXULTextContentType "application/vnd.mozilla.xul+xml"
|
||||
#define kRDFTextContentType "text/rdf"
|
||||
#define kXIFTextContentType "text/xif"
|
||||
#define kPlainTextContentType "text/plain"
|
||||
|
|
|
@ -327,7 +327,7 @@ nsCachedChromeChannel::SetNotificationCallbacks(nsIInterfaceRequestor * aNotific
|
|||
NS_IMETHODIMP
|
||||
nsCachedChromeChannel::GetContentType(char * *aContentType)
|
||||
{
|
||||
*aContentType = nsXPIDLCString::Copy("text/cached-xul");
|
||||
*aContentType = nsXPIDLCString::Copy("mozilla.application/cached-xul");
|
||||
return *aContentType ? NS_OK : NS_ERROR_OUT_OF_MEMORY;
|
||||
}
|
||||
|
||||
|
|
|
@ -1088,7 +1088,7 @@ nsBrowserInstance::IsPreferred(const char * aContentType,
|
|||
// regardlesss of the uri load command.
|
||||
// incoming Type Preferred type
|
||||
// text/html
|
||||
// text/xul
|
||||
// application/vnd.mozilla.xul+xml
|
||||
// text/rdf
|
||||
// text/xml
|
||||
// text/css
|
||||
|
@ -1103,7 +1103,7 @@ nsBrowserInstance::IsPreferred(const char * aContentType,
|
|||
// (1) list all content types we want to be the primary handler for....
|
||||
// and suggest a desired content type if appropriate...
|
||||
if (nsCRT::strcasecmp(aContentType, "text/html") == 0
|
||||
|| nsCRT::strcasecmp(aContentType, "text/xul") == 0
|
||||
|| nsCRT::strcasecmp(aContentType, "application/vnd.mozilla.xul+xml") == 0
|
||||
|| nsCRT::strcasecmp(aContentType, "text/rdf") == 0
|
||||
|| nsCRT::strcasecmp(aContentType, "text/xml") == 0
|
||||
|| nsCRT::strcasecmp(aContentType, "text/css") == 0
|
||||
|
@ -1551,7 +1551,7 @@ static nsModuleComponentInfo components[] = {
|
|||
},
|
||||
{ "Browser Content Handler",
|
||||
NS_BROWSERCONTENTHANDLER_CID,
|
||||
NS_CONTENT_HANDLER_CONTRACTID_PREFIX"text/xul",
|
||||
NS_CONTENT_HANDLER_CONTRACTID_PREFIX"application/vnd.mozilla.xul+xml",
|
||||
nsBrowserContentHandlerConstructor
|
||||
},
|
||||
{ "Browser Content Handler",
|
||||
|
|
|
@ -1778,7 +1778,7 @@ nsDirectoryViewerFactory::CreateInstance(const char *aCommand,
|
|||
|
||||
// Create a dummy loader that will load a stub XUL document.
|
||||
nsCOMPtr<nsIDocumentLoaderFactory> factory;
|
||||
rv = nsComponentManager::CreateInstance(NS_DOCUMENT_LOADER_FACTORY_CONTRACTID_PREFIX "view;1?type=text/xul",
|
||||
rv = nsComponentManager::CreateInstance(NS_DOCUMENT_LOADER_FACTORY_CONTRACTID_PREFIX "view;1?type=application/vnd.mozilla.xul+xml",
|
||||
nsnull,
|
||||
NS_GET_IID(nsIDocumentLoaderFactory),
|
||||
getter_AddRefs(factory));
|
||||
|
@ -1793,7 +1793,7 @@ nsDirectoryViewerFactory::CreateInstance(const char *aCommand,
|
|||
if (NS_FAILED(rv)) return rv;
|
||||
|
||||
nsCOMPtr<nsIStreamListener> listener;
|
||||
rv = factory->CreateInstance("view", channel, aLoadGroup, "text/xul",
|
||||
rv = factory->CreateInstance("view", channel, aLoadGroup, "application/vnd.mozilla.xul+xml",
|
||||
aContainer, aExtraInfo, getter_AddRefs(listener),
|
||||
aDocViewerResult);
|
||||
if (NS_FAILED(rv)) return rv;
|
||||
|
|
Загрузка…
Ссылка в новой задаче