Enabling NOLAYERS by default ( since we don't support LAYER tag ).
r=vidur Putting webshellservice into parser bundle for use by observer base. r=nisheeth
This commit is contained in:
@@ -530,6 +530,7 @@ nsHTMLDocument::StartDocumentLoad(const char* aCommand,
|
||||
|
||||
static NS_DEFINE_IID(kCParserIID, NS_IPARSER_IID);
|
||||
static NS_DEFINE_IID(kCParserCID, NS_PARSER_IID);
|
||||
static NS_DEFINE_IID(kParserBundleIID, NS_IPARSER_BUNDLE_IID);
|
||||
|
||||
if (needsParser)
|
||||
{
|
||||
@@ -554,6 +555,21 @@ nsHTMLDocument::StartDocumentLoad(const char* aCommand,
|
||||
NS_PRECONDITION(nsnull != aContainer, "No content viewer container");
|
||||
nsCOMPtr<nsIDocShell> docShell(do_QueryInterface(aContainer));
|
||||
|
||||
if(mParser) {
|
||||
nsCOMPtr<nsIWebShellServices> webShellServices(do_QueryInterface(docShell));
|
||||
nsISupportsParserBundle* parserBundle=nsnull;
|
||||
|
||||
nsresult result=mParser->QueryInterface(kParserBundleIID,(void**)&parserBundle);
|
||||
|
||||
if(NS_SUCCEEDED(result)) {
|
||||
// We do this to help consumers who don't have access to the webshell.
|
||||
nsAutoString theID;
|
||||
theID.AssignWithConversion("webshell");
|
||||
parserBundle->SetDataIntoBundle(theID,webShellServices);
|
||||
NS_IF_RELEASE(parserBundle);
|
||||
}
|
||||
}
|
||||
|
||||
//
|
||||
// The following logic is mirrored in nsWebShell::Embed!
|
||||
//
|
||||
|
||||
Reference in New Issue
Block a user