Jacek Caban : mshtml: Access document object via browser object in update_window_doc.
Alexandre Julliard
julliard at winehq.org
Thu Mar 14 18:33:21 CDT 2019
Module: wine
Branch: master
Commit: aa96a8de36d9f4c82c13f0756c931b15a49acde4
URL: https://source.winehq.org/git/wine.git/?a=commit;h=aa96a8de36d9f4c82c13f0756c931b15a49acde4
Author: Jacek Caban <jacek at codeweavers.com>
Date: Thu Mar 14 14:13:29 2019 +0100
mshtml: Access document object via browser object in update_window_doc.
Signed-off-by: Jacek Caban <jacek at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
dlls/mshtml/htmlwindow.c | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
diff --git a/dlls/mshtml/htmlwindow.c b/dlls/mshtml/htmlwindow.c
index dc3f24a..fd18ce0 100644
--- a/dlls/mshtml/htmlwindow.c
+++ b/dlls/mshtml/htmlwindow.c
@@ -3672,10 +3672,11 @@ HRESULT update_window_doc(HTMLInnerWindow *window)
outer_window->base.inner_window = window;
outer_window->pending_window = NULL;
- if(outer_window->doc_obj->basedoc.window == outer_window || !outer_window->doc_obj->basedoc.window) {
- if(outer_window->doc_obj->basedoc.doc_node)
- htmldoc_release(&outer_window->doc_obj->basedoc.doc_node->basedoc);
- outer_window->doc_obj->basedoc.doc_node = window->doc;
+ if(is_main_content_window(outer_window) || !outer_window->browser->content_window) {
+ HTMLDocumentObj *doc_obj = outer_window->browser->doc;
+ if(doc_obj->basedoc.doc_node)
+ htmldoc_release(&doc_obj->basedoc.doc_node->basedoc);
+ doc_obj->basedoc.doc_node = window->doc;
htmldoc_addref(&window->doc->basedoc);
}
More information about the wine-cvs
mailing list