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
2d7a3bb4
Commit
2d7a3bb4
authored
Dec 17, 2012
by
Jacek Caban
Committed by
Alexandre Julliard
Dec 17, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
jscript: Fixed deleting properties by name from IDispatchEx interface.
parent
7202f1a3
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
23 additions
and
9 deletions
+23
-9
dispex.c
dlls/jscript/dispex.c
+2
-1
run.c
dlls/jscript/tests/run.c
+21
-8
No files found.
dlls/jscript/dispex.c
View file @
2d7a3bb4
...
...
@@ -1535,7 +1535,8 @@ HRESULT disp_delete_name(script_ctx_t *ctx, IDispatch *disp, jsstr_t *name, BOOL
if
(
bstr
)
{
hres
=
IDispatchEx_DeleteMemberByName
(
dispex
,
bstr
,
make_grfdex
(
ctx
,
fdexNameCaseSensitive
));
SysFreeString
(
bstr
);
*
ret
=
TRUE
;
if
(
SUCCEEDED
(
hres
))
*
ret
=
hres
==
S_OK
;
}
else
{
hres
=
E_OUTOFMEMORY
;
}
...
...
dlls/jscript/tests/run.c
View file @
2d7a3bb4
...
...
@@ -89,7 +89,8 @@ DEFINE_EXPECT(global_propargput_i);
DEFINE_EXPECT
(
global_testargtypes_i
);
DEFINE_EXPECT
(
puredisp_prop_d
);
DEFINE_EXPECT
(
puredisp_noprop_d
);
DEFINE_EXPECT
(
testobj_delete
);
DEFINE_EXPECT
(
testobj_delete_test
);
DEFINE_EXPECT
(
testobj_delete_nodelete
);
DEFINE_EXPECT
(
testobj_value
);
DEFINE_EXPECT
(
testobj_prop_d
);
DEFINE_EXPECT
(
testobj_withprop_d
);
...
...
@@ -402,11 +403,19 @@ static HRESULT WINAPI testObj_InvokeEx(IDispatchEx *iface, DISPID id, LCID lcid,
static
HRESULT
WINAPI
testObj_DeleteMemberByName
(
IDispatchEx
*
iface
,
BSTR
bstrName
,
DWORD
grfdex
)
{
CHECK_EXPECT
(
testobj_delete
);
if
(
!
strcmp_wa
(
bstrName
,
"deleteTest"
))
{
CHECK_EXPECT
(
testobj_delete_test
);
test_grfdex
(
grfdex
,
fdexNameCaseSensitive
);
return
S_OK
;
}
if
(
!
strcmp_wa
(
bstrName
,
"noDeleteTest"
))
{
CHECK_EXPECT
(
testobj_delete_nodelete
);
test_grfdex
(
grfdex
,
fdexNameCaseSensitive
);
return
S_FALSE
;
}
ok
(
!
strcmp_wa
(
bstrName
,
"deleteTest"
),
"unexpected name %s
\n
"
,
wine_dbgstr_w
(
bstrName
));
test_grfdex
(
grfdex
,
fdexNameCaseSensitive
);
return
S_OK
;
ok
(
0
,
"unexpected name %s
\n
"
,
wine_dbgstr_w
(
bstrName
));
return
E_FAIL
;
}
static
IDispatchExVtbl
testObjVtbl
=
{
...
...
@@ -1836,9 +1845,13 @@ static BOOL run_tests(void)
CHECK_CALLED
(
global_success_d
);
CHECK_CALLED
(
global_success_i
);
SET_EXPECT
(
testobj_delete
);
parse_script_a
(
"delete testObj.deleteTest;"
);
CHECK_CALLED
(
testobj_delete
);
SET_EXPECT
(
testobj_delete_test
);
parse_script_a
(
"ok((delete testObj.deleteTest) === true, 'delete testObj.deleteTest did not return true');"
);
CHECK_CALLED
(
testobj_delete_test
);
SET_EXPECT
(
testobj_delete_nodelete
);
parse_script_a
(
"ok((delete testObj.noDeleteTest) === false, 'delete testObj.noDeleteTest did not return false');"
);
CHECK_CALLED
(
testobj_delete_nodelete
);
SET_EXPECT
(
global_propdelete_d
);
SET_EXPECT
(
DeleteMemberByDispID
);
...
...
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