Final removal of VIEW_SOURCE_HTML define. Bug 81132,

r=rbs@maths.uq.edu.au, sr=jst
This commit is contained in:
bzbarsky%mit.edu 2001-09-30 23:48:07 +00:00
Родитель a8813d30ed
Коммит ceba997a92
2 изменённых файлов: 0 добавлений и 26 удалений

Просмотреть файл

@ -56,8 +56,6 @@
#include "nsIXULContentSink.h"
#include "nsIDocStreamLoaderFactory.h"
#define VIEW_SOURCE_HTML
// URL for the "user agent" style sheet
#define UA_CSS_URL "resource:/res/ua.css"
@ -206,23 +204,12 @@ nsContentDLF::CreateInstance(const char* aCommand,
}
if(0==PL_strcmp(aCommand,"view-source")) {
#ifdef VIEW_SOURCE_HTML
NS_ENSURE_ARG(aChannel);
// It's a view-source. Reset channel's content type to the original
// type so as not to choke the parser when it asks the channel
// for the content type during the parse phase
aChannel->SetContentType(aContentType);
aContentType=gHTMLTypes[0];
#else
if(0==PL_strcmp(aContentType,gHTMLTypes[1])) {
aContentType=gHTMLTypes[0];
}
else if(0==PL_strcmp(aContentType,gHTMLTypes[2])) {
aContentType=gHTMLTypes[0];
}
else
aContentType=gXMLTypes[0];
#endif
}
// Try html

Просмотреть файл

@ -56,8 +56,6 @@
#include "nsIXULContentSink.h"
#include "nsIDocStreamLoaderFactory.h"
#define VIEW_SOURCE_HTML
// URL for the "user agent" style sheet
#define UA_CSS_URL "resource:/res/ua.css"
@ -206,23 +204,12 @@ nsContentDLF::CreateInstance(const char* aCommand,
}
if(0==PL_strcmp(aCommand,"view-source")) {
#ifdef VIEW_SOURCE_HTML
NS_ENSURE_ARG(aChannel);
// It's a view-source. Reset channel's content type to the original
// type so as not to choke the parser when it asks the channel
// for the content type during the parse phase
aChannel->SetContentType(aContentType);
aContentType=gHTMLTypes[0];
#else
if(0==PL_strcmp(aContentType,gHTMLTypes[1])) {
aContentType=gHTMLTypes[0];
}
else if(0==PL_strcmp(aContentType,gHTMLTypes[2])) {
aContentType=gHTMLTypes[0];
}
else
aContentType=gXMLTypes[0];
#endif
}
// Try html