Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
8ccc38cb
Commit
8ccc38cb
authored
Jul 19, 2016
by
Jacek Caban
Committed by
Alexandre Julliard
Jul 20, 2016
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mshtml: Set interactive script ready state change in the right places.
Signed-off-by:
Jacek Caban
<
jacek@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
3a85711a
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
10 additions
and
8 deletions
+10
-8
htmlscript.c
dlls/mshtml/htmlscript.c
+2
-2
htmlscript.h
dlls/mshtml/htmlscript.h
+1
-1
mutation.c
dlls/mshtml/mutation.c
+2
-2
script.c
dlls/mshtml/script.c
+5
-3
No files found.
dlls/mshtml/htmlscript.c
View file @
8ccc38cb
...
...
@@ -203,7 +203,7 @@ static HRESULT WINAPI HTMLScriptElement_put_text(IHTMLScriptElement *iface, BSTR
}
nsIDOMNode_Release
(
parent
);
doc_insert_script
(
window
,
This
);
doc_insert_script
(
window
,
This
,
FALSE
);
return
S_OK
;
}
...
...
@@ -400,7 +400,7 @@ static HRESULT HTMLScriptElement_bind_to_tree(HTMLDOMNode *iface)
}
This
->
parse_on_bind
=
FALSE
;
doc_insert_script
(
This
->
element
.
node
.
doc
->
window
,
This
);
doc_insert_script
(
This
->
element
.
node
.
doc
->
window
,
This
,
FALSE
);
return
S_OK
;
}
...
...
dlls/mshtml/htmlscript.h
View file @
8ccc38cb
...
...
@@ -40,7 +40,7 @@ HRESULT load_script(HTMLScriptElement*,const WCHAR*) DECLSPEC_HIDDEN;
void
release_script_hosts
(
HTMLInnerWindow
*
)
DECLSPEC_HIDDEN
;
void
connect_scripts
(
HTMLInnerWindow
*
)
DECLSPEC_HIDDEN
;
void
doc_insert_script
(
HTMLInnerWindow
*
,
HTMLScriptElement
*
)
DECLSPEC_HIDDEN
;
void
doc_insert_script
(
HTMLInnerWindow
*
,
HTMLScriptElement
*
,
BOOL
)
DECLSPEC_HIDDEN
;
IDispatch
*
script_parse_event
(
HTMLInnerWindow
*
,
LPCWSTR
)
DECLSPEC_HIDDEN
;
HRESULT
exec_script
(
HTMLInnerWindow
*
,
const
WCHAR
*
,
const
WCHAR
*
,
VARIANT
*
)
DECLSPEC_HIDDEN
;
void
set_script_mode
(
HTMLOuterWindow
*
,
SCRIPTMODE
)
DECLSPEC_HIDDEN
;
...
...
dlls/mshtml/mutation.c
View file @
8ccc38cb
...
...
@@ -337,13 +337,13 @@ static nsresult run_insert_script(HTMLDocumentNode *doc, nsISupports *script_ifa
IHTMLWindow2_AddRef
(
&
window
->
base
.
IHTMLWindow2_iface
);
doc_insert_script
(
window
,
script_elem
);
doc_insert_script
(
window
,
script_elem
,
TRUE
);
while
(
!
list_empty
(
&
window
->
script_queue
))
{
iter
=
LIST_ENTRY
(
list_head
(
&
window
->
script_queue
),
script_queue_entry_t
,
entry
);
list_remove
(
&
iter
->
entry
);
if
(
!
iter
->
script
->
parsed
)
doc_insert_script
(
window
,
iter
->
script
);
doc_insert_script
(
window
,
iter
->
script
,
TRUE
);
IHTMLScriptElement_Release
(
&
iter
->
script
->
IHTMLScriptElement_iface
);
heap_free
(
iter
);
}
...
...
dlls/mshtml/script.c
View file @
8ccc38cb
...
...
@@ -786,8 +786,6 @@ static void parse_elem_text(ScriptHost *script_host, HTMLScriptElement *script_e
TRACE
(
"%s
\n
"
,
debugstr_w
(
text
));
set_script_elem_readystate
(
script_elem
,
READYSTATE_INTERACTIVE
);
VariantInit
(
&
var
);
memset
(
&
excepinfo
,
0
,
sizeof
(
excepinfo
));
TRACE
(
">>>
\n
"
);
...
...
@@ -1089,6 +1087,8 @@ static void parse_inline_script(ScriptHost *script_host, HTMLScriptElement *scri
nsres
=
nsIDOMHTMLScriptElement_GetText
(
script_elem
->
nsscript
,
&
text_str
);
nsAString_GetData
(
&
text_str
,
&
text
);
set_script_elem_readystate
(
script_elem
,
READYSTATE_INTERACTIVE
);
if
(
NS_FAILED
(
nsres
))
{
ERR
(
"GetText failed: %08x
\n
"
,
nsres
);
}
else
if
(
*
text
)
{
...
...
@@ -1257,7 +1257,7 @@ static ScriptHost *get_elem_script_host(HTMLInnerWindow *window, HTMLScriptEleme
return
get_script_host
(
window
,
&
guid
);
}
void
doc_insert_script
(
HTMLInnerWindow
*
window
,
HTMLScriptElement
*
script_elem
)
void
doc_insert_script
(
HTMLInnerWindow
*
window
,
HTMLScriptElement
*
script_elem
,
BOOL
from_parser
)
{
ScriptHost
*
script_host
;
BOOL
is_complete
=
FALSE
;
...
...
@@ -1268,6 +1268,8 @@ void doc_insert_script(HTMLInnerWindow *window, HTMLScriptElement *script_elem)
if
(
script_host
->
parse
)
{
if
(
script_elem
->
src_text
)
{
if
(
from_parser
)
set_script_elem_readystate
(
script_elem
,
READYSTATE_INTERACTIVE
);
script_elem
->
parsed
=
TRUE
;
parse_elem_text
(
script_host
,
script_elem
,
script_elem
->
src_text
);
is_complete
=
TRUE
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment