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
4fc0f2aa
Commit
4fc0f2aa
authored
Nov 01, 2017
by
Jacek Caban
Committed by
Alexandre Julliard
Nov 01, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
jscript: Added support for VT_UI2 VARIANT types.
Signed-off-by:
Jacek Caban
<
jacek@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
25c78b61
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
2 deletions
+8
-2
jsutils.c
dlls/jscript/jsutils.c
+3
-0
run.c
dlls/jscript/tests/run.c
+5
-2
No files found.
dlls/jscript/jsutils.c
View file @
4fc0f2aa
...
...
@@ -297,6 +297,9 @@ HRESULT variant_to_jsval(VARIANT *var, jsval_t *r)
case
VT_I2
:
*
r
=
jsval_number
(
V_I2
(
var
));
return
S_OK
;
case
VT_UI2
:
*
r
=
jsval_number
(
V_UI2
(
var
));
return
S_OK
;
case
VT_INT
:
*
r
=
jsval_number
(
V_INT
(
var
));
return
S_OK
;
...
...
dlls/jscript/tests/run.c
View file @
4fc0f2aa
...
...
@@ -1315,7 +1315,7 @@ static HRESULT WINAPI Global_InvokeEx(IDispatchEx *iface, DISPID id, LCID lcid,
return
S_OK
;
case
DISPID_GLOBAL_TESTARGTYPES
:
{
VARIANT
args
[
7
],
v
;
VARIANT
args
[
8
],
v
;
DISPPARAMS
dp
=
{
args
,
NULL
,
sizeof
(
args
)
/
sizeof
(
*
args
),
0
};
HRESULT
hres
;
...
...
@@ -1357,6 +1357,8 @@ static HRESULT WINAPI Global_InvokeEx(IDispatchEx *iface, DISPID id, LCID lcid,
V_VARIANTREF
(
args
+
5
)
=
&
v
;
V_VT
(
args
+
6
)
=
VT_R4
;
V_R4
(
args
+
6
)
=
0
.
5
;
V_VT
(
args
+
7
)
=
VT_UI2
;
V_R4
(
args
+
7
)
=
3
;
V_VT
(
&
v
)
=
VT_I4
;
V_I4
(
&
v
)
=
2
;
hres
=
IDispatch_Invoke
(
V_DISPATCH
(
pdp
->
rgvarg
),
DISPID_VALUE
,
&
IID_NULL
,
0
,
DISPATCH_METHOD
,
&
dp
,
NULL
,
NULL
,
NULL
);
...
...
@@ -2647,7 +2649,7 @@ static BOOL run_tests(void)
SET_EXPECT
(
global_testargtypes_i
);
parse_script_a
(
"testArgTypes(dispUnk, intProp(), intProp, getShort(), shortProp,"
"function(r4,i4ref,ui4,nullunk,d,i,s) {"
"function(
ui2,
r4,i4ref,ui4,nullunk,d,i,s) {"
" ok(getVT(i) === 'VT_I4', 'getVT(i) = ' + getVT(i));"
" ok(getVT(s) === 'VT_I4', 'getVT(s) = ' + getVT(s));"
" ok(getVT(d) === 'VT_DISPATCH', 'getVT(d) = ' + getVT(d));"
...
...
@@ -2659,6 +2661,7 @@ static BOOL run_tests(void)
" ok(i4ref === 2, 'i4ref = ' + i4ref);"
" ok(r4 === 0.5, 'r4 = ' + r4);"
" ok(getVT(r4) === 'VT_R8', 'getVT(r4) = ' + getVT(r4));"
" ok(getVT(ui2) === 'VT_I4', 'getVT(ui2) = ' + getVT(ui2));"
"});"
);
CHECK_CALLED
(
global_testargtypes_i
);
...
...
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