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
5ea259e8
Commit
5ea259e8
authored
Nov 04, 2011
by
Nikolay Sivov
Committed by
Alexandre Julliard
Nov 07, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
msxml3: Support IDispatch in IXMLElement.
parent
c32db174
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
24 additions
and
5 deletions
+24
-5
xmldoc.c
dlls/msxml3/tests/xmldoc.c
+22
-4
xmlelem.c
dlls/msxml3/xmlelem.c
+2
-1
No files found.
dlls/msxml3/tests/xmldoc.c
View file @
5ea259e8
...
...
@@ -852,8 +852,10 @@ static void test_xmlelem(void)
IXMLElementCollection
*
children
;
VARIANT
vType
,
vName
;
VARIANT
vIndex
,
vValue
;
BSTR
str
,
val
;
BSTR
str
,
val
,
name
;
LONG
type
,
num_child
;
IDispatch
*
disp
;
ITypeInfo
*
ti
;
static
const
WCHAR
propName
[]
=
{
'p'
,
'r'
,
'o'
,
'p'
,
0
};
static
const
WCHAR
propVal
[]
=
{
'v'
,
'a'
,
'l'
,
0
};
...
...
@@ -864,17 +866,33 @@ static void test_xmlelem(void)
hr
=
CoCreateInstance
(
&
CLSID_XMLDocument
,
NULL
,
CLSCTX_INPROC_SERVER
,
&
IID_IXMLDocument
,
(
LPVOID
*
)
&
doc
);
ok
(
hr
==
S_OK
,
"Expected S_OK, got 0x%08x
\n
"
,
hr
);
EXPECT_HR
(
hr
,
S_OK
);
V_VT
(
&
vType
)
=
VT_I4
;
V_I4
(
&
vType
)
=
XMLELEMTYPE_ELEMENT
;
V_VT
(
&
vName
)
=
VT_NULL
;
hr
=
IXMLDocument_createElement
(
doc
,
vType
,
vName
,
&
element
);
ok
(
hr
==
S_OK
,
"Expected S_OK, got %08x
\n
"
,
hr
);
EXPECT_HR
(
hr
,
S_OK
);
ok
(
element
!=
NULL
,
"Expected non-NULL element
\n
"
);
/* test for IDispatch */
disp
=
NULL
;
hr
=
IXMLElement_QueryInterface
(
element
,
&
IID_IDispatch
,
(
void
**
)
&
disp
);
EXPECT_HR
(
hr
,
S_OK
);
hr
=
IDispatch_GetTypeInfo
(
disp
,
0
,
0
,
&
ti
);
EXPECT_HR
(
hr
,
S_OK
);
name
=
NULL
;
hr
=
ITypeInfo_GetDocumentation
(
ti
,
DISPID_XMLELEMENT_TAGNAME
,
&
name
,
NULL
,
NULL
,
NULL
);
EXPECT_HR
(
hr
,
S_OK
);
SysFreeString
(
name
);
ITypeInfo_Release
(
ti
);
IDispatch_Release
(
disp
);
hr
=
IXMLElement_get_tagName
(
element
,
&
str
);
ok
(
hr
==
S_OK
,
"Expected S_OK, got %08x
\n
"
,
hr
);
EXPECT_HR
(
hr
,
S_OK
);
ok
(
lstrlenW
(
str
)
==
0
,
"Expected empty tag name
\n
"
);
SysFreeString
(
str
);
...
...
dlls/msxml3/xmlelem.c
View file @
5ea259e8
...
...
@@ -67,7 +67,8 @@ static HRESULT WINAPI xmlelem_QueryInterface(IXMLElement *iface, REFIID riid, vo
TRACE
(
"(%p)->(%s %p)
\n
"
,
This
,
debugstr_guid
(
riid
),
ppvObject
);
if
(
IsEqualGUID
(
riid
,
&
IID_IUnknown
)
||
if
(
IsEqualGUID
(
riid
,
&
IID_IUnknown
)
||
IsEqualGUID
(
riid
,
&
IID_IDispatch
)
||
IsEqualGUID
(
riid
,
&
IID_IXMLElement
))
{
*
ppvObject
=
iface
;
...
...
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