Module: wine Branch: master Commit: 5289cc85252b92d2a2e12ba91493a2d16cdab8fd URL: https://gitlab.winehq.org/wine/wine/-/commit/5289cc85252b92d2a2e12ba91493a2d...
Author: Jacek Caban jacek@codeweavers.com Date: Mon Nov 20 15:14:36 2023 +0100
mshtml: Use Gecko inner window in get_ns_selection.
---
dlls/mshtml/editor.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/dlls/mshtml/editor.c b/dlls/mshtml/editor.c index 478c30932c1..e4a16956e46 100644 --- a/dlls/mshtml/editor.c +++ b/dlls/mshtml/editor.c @@ -203,7 +203,10 @@ static nsISelection *get_ns_selection(HTMLDocumentNode *doc) nsISelection *nsselection = NULL; nsresult nsres;
- nsres = nsIDOMWindow_GetSelection(doc->outer_window->nswindow, &nsselection); + if(!doc->window) + return NULL; + + nsres = nsIDOMWindow_GetSelection(doc->window->dom_window, &nsselection); if(NS_FAILED(nsres)) ERR("GetSelection failed %08lx\n", nsres);