Jacek Caban : mshtml: Use stored nsdoc in IHTMLTxtRange::expand.
Alexandre Julliard
julliard at winehq.org
Fri Oct 10 08:06:35 CDT 2008
Module: wine
Branch: master
Commit: 08efe6de3e340429acfaefad787a566bb156e00e
URL: http://source.winehq.org/git/wine.git/?a=commit;h=08efe6de3e340429acfaefad787a566bb156e00e
Author: Jacek Caban <jacek at codeweavers.com>
Date: Thu Oct 9 15:25:15 2008 -0500
mshtml: Use stored nsdoc in IHTMLTxtRange::expand.
---
dlls/mshtml/txtrange.c | 14 +-------------
1 files changed, 1 insertions(+), 13 deletions(-)
diff --git a/dlls/mshtml/txtrange.c b/dlls/mshtml/txtrange.c
index c35834f..ff35568 100644
--- a/dlls/mshtml/txtrange.c
+++ b/dlls/mshtml/txtrange.c
@@ -1308,22 +1308,10 @@ static HRESULT WINAPI HTMLTxtRange_expand(IHTMLTxtRange *iface, BSTR Unit, VARIA
}
case RU_TEXTEDIT: {
- nsIDOMDocument *nsdoc;
- nsIDOMHTMLDocument *nshtmldoc;
nsIDOMHTMLElement *nsbody = NULL;
nsresult nsres;
- nsres = nsIWebNavigation_GetDocument(This->doc->nscontainer->navigation, &nsdoc);
- if(NS_FAILED(nsres) || !nsdoc) {
- ERR("GetDocument failed: %08x\n", nsres);
- break;
- }
-
- nsIDOMDocument_QueryInterface(nsdoc, &IID_nsIDOMHTMLDocument, (void**)&nshtmldoc);
- nsIDOMDocument_Release(nsdoc);
-
- nsres = nsIDOMHTMLDocument_GetBody(nshtmldoc, &nsbody);
- nsIDOMHTMLDocument_Release(nshtmldoc);
+ nsres = nsIDOMHTMLDocument_GetBody(This->doc->nsdoc, &nsbody);
if(NS_FAILED(nsres) || !nsbody) {
ERR("Could not get body: %08x\n", nsres);
break;
More information about the wine-cvs
mailing list