diff --git a/dlls/mshtml/mutation.c b/dlls/mshtml/mutation.c index dd3d119b0e0..a298ecbbbfb 100644 --- a/dlls/mshtml/mutation.c +++ b/dlls/mshtml/mutation.c @@ -729,6 +729,17 @@ static void NSAPI nsDocumentObserver_BindToDocument(nsIDocumentObserver *iface, return; } + if(This->document_mode == COMPAT_MODE_QUIRKS) { + nsIDOMDocumentType *nsdoctype; + nsres = nsIContent_QueryInterface(aContent, &IID_nsIDOMDocumentType, (void**)&nsdoctype); + if(NS_SUCCEEDED(nsres)) { + TRACE("doctype node\n"); + /* FIXME: We should set it to something higher for internet zone. */ + set_document_mode(This, COMPAT_MODE_IE7); + nsIDOMDocumentType_Release(nsdoctype); + } + } + nsres = nsIContent_QueryInterface(aContent, &IID_nsIDOMHTMLElement, (void**)&nselem); if(NS_FAILED(nsres)) return; diff --git a/dlls/mshtml/nsiface.idl b/dlls/mshtml/nsiface.idl index 1b6104af1a3..e9c717dbec9 100644 --- a/dlls/mshtml/nsiface.idl +++ b/dlls/mshtml/nsiface.idl @@ -134,7 +134,6 @@ typedef nsISupports nsISHistory; typedef nsISupports nsIWidget; typedef nsISupports nsIPrompt; typedef nsISupports nsIAuthPrompt; -typedef nsISupports nsIDOMDocumentType; typedef nsISupports nsIDOMDOMImplementation; typedef nsISupports nsIDOMCDATASection; typedef nsISupports nsIDOMProcessingInstruction; @@ -1199,6 +1198,20 @@ interface nsIDOMComment : nsIDOMCharacterData { } +[ + object, + uuid(cd7467b9-0f26-4787-a359-66e80ba8db92), + local +] +interface nsIDOMDocumentType : nsIDOMNode +{ + nsresult GetName(nsAString *aName); + nsresult GetPublicId(nsAString *aPublicId); + nsresult GetSystemId(nsAString *aSystemId); + nsresult GetInternalSubset(nsAString *aInternalSubset); + nsresult MozRemove(); +} + [ object, uuid(48eb8d72-95bb-402e-a8fc-f2b187abcbdb),