mshtml: Implement IHTMLElement get_document

Jacek Caban jacek at codeweavers.com
Thu Oct 30 07:14:10 CDT 2008


Hi Alistair,

Alistair Leslie-Hughes wrote:
> Hi,
>
> Changelog:
>     mshtml: Implement IHTMLElement get_document
>

+    *p = NULL;
+
+    if(!This->node.doc->nsdoc) {
+        WARN("NULL nsdoc\n");
+        return E_UNEXPECTED;
+    }


You don't use nsdoc so there is no reason to test it.

+    hr = IHTMLDocument2_QueryInterface(HTMLDOC(This->node.doc), &IID_IHTMLDocument, (void**)p);
+
+    return hr;



You could just cast This->node.doc to IHTMLDocument and call AddRef on result.


Jacek




More information about the wine-devel mailing list