Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
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-winehq
Commits
a9a3c65c
Commit
a9a3c65c
authored
Jan 26, 2023
by
Gabriel Ivăncescu
Committed by
Alexandre Julliard
Jan 27, 2023
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mshtml: Set SCRIPTPROP_ABBREVIATE_GLOBALNAME_RESOLUTION properly.
Signed-off-by:
Gabriel Ivăncescu
<
gabrielopcode@gmail.com
>
parent
34209915
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
24 additions
and
0 deletions
+24
-0
script.c
dlls/mshtml/script.c
+24
-0
script.c
dlls/mshtml/tests/script.c
+0
-0
No files found.
dlls/mshtml/script.c
View file @
a9a3c65c
...
@@ -201,9 +201,33 @@ static BOOL init_script_engine(ScriptHost *script_host, IActiveScript *script)
...
@@ -201,9 +201,33 @@ static BOOL init_script_engine(ScriptHost *script_host, IActiveScript *script)
hres
=
IActiveScript_AddNamedItem
(
script
,
L"window"
,
hres
=
IActiveScript_AddNamedItem
(
script
,
L"window"
,
SCRIPTITEM_ISVISIBLE
|
SCRIPTITEM_ISSOURCE
|
SCRIPTITEM_GLOBALMEMBERS
);
SCRIPTITEM_ISVISIBLE
|
SCRIPTITEM_ISSOURCE
|
SCRIPTITEM_GLOBALMEMBERS
);
if
(
SUCCEEDED
(
hres
))
{
if
(
SUCCEEDED
(
hres
))
{
ScriptHost
*
first_host
;
V_VT
(
&
var
)
=
VT_BOOL
;
V_VT
(
&
var
)
=
VT_BOOL
;
V_BOOL
(
&
var
)
=
VARIANT_TRUE
;
V_BOOL
(
&
var
)
=
VARIANT_TRUE
;
LIST_FOR_EACH_ENTRY
(
first_host
,
&
script_host
->
window
->
script_hosts
,
ScriptHost
,
entry
)
{
if
(
first_host
->
script
)
{
V_BOOL
(
&
var
)
=
VARIANT_FALSE
;
break
;
}
}
set_script_prop
(
script
,
SCRIPTPROP_ABBREVIATE_GLOBALNAME_RESOLUTION
,
&
var
);
set_script_prop
(
script
,
SCRIPTPROP_ABBREVIATE_GLOBALNAME_RESOLUTION
,
&
var
);
/* if this was second engine initialized, also set it to first engine, since it used to be TRUE */
if
(
!
V_BOOL
(
&
var
))
{
struct
list
*
iter
=
&
first_host
->
entry
;
BOOL
is_second_init
=
TRUE
;
while
((
iter
=
list_next
(
&
script_host
->
window
->
script_hosts
,
iter
)))
{
if
(
LIST_ENTRY
(
iter
,
ScriptHost
,
entry
)
->
script
)
{
is_second_init
=
FALSE
;
break
;
}
}
if
(
is_second_init
)
set_script_prop
(
first_host
->
script
,
SCRIPTPROP_ABBREVIATE_GLOBALNAME_RESOLUTION
,
&
var
);
}
}
else
{
}
else
{
WARN
(
"AddNamedItem failed: %08lx
\n
"
,
hres
);
WARN
(
"AddNamedItem failed: %08lx
\n
"
,
hres
);
}
}
...
...
dlls/mshtml/tests/script.c
View file @
a9a3c65c
This diff is collapsed.
Click to expand it.
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