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
d7aee26d
Commit
d7aee26d
authored
Mar 07, 2014
by
Nikolay Sivov
Committed by
Alexandre Julliard
Mar 07, 2014
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
msxml3: Make propputref methods invocable with DISPATCH_PROPERTYPUT.
parent
8d5b1dd5
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
65 additions
and
2 deletions
+65
-2
dispex.c
dlls/msxml3/dispex.c
+27
-0
saxreader.c
dlls/msxml3/tests/saxreader.c
+38
-2
No files found.
dlls/msxml3/dispex.c
View file @
d7aee26d
...
@@ -32,6 +32,7 @@
...
@@ -32,6 +32,7 @@
#include "winnls.h"
#include "winnls.h"
#include "ole2.h"
#include "ole2.h"
#include "msxml6.h"
#include "msxml6.h"
#include "msxml6did.h"
#include "wininet.h"
#include "wininet.h"
#include "urlmon.h"
#include "urlmon.h"
#include "winreg.h"
#include "winreg.h"
...
@@ -519,6 +520,30 @@ static HRESULT WINAPI DispatchEx_GetDispID(IDispatchEx *iface, BSTR bstrName, DW
...
@@ -519,6 +520,30 @@ static HRESULT WINAPI DispatchEx_GetDispID(IDispatchEx *iface, BSTR bstrName, DW
return
DISP_E_UNKNOWNNAME
;
return
DISP_E_UNKNOWNNAME
;
}
}
static
BOOL
is_propputref_id
(
DISPID
id
)
{
switch
(
id
)
{
case
DISPID_DOM_DOCUMENT_DOCUMENTELEMENT
:
case
DISPID_XMLDOM_DOCUMENT2_SCHEMAS
:
case
DISPID_XMLDOM_SELECTION_CONTEXT
:
case
DISPID_XMLDOM_TEMPLATE_STYLESHEET
:
case
DISPID_SAX_CONTENTHANDLER_DOCUMENTLOCATOR
:
case
DISPID_SAX_XMLFILTER_PARENT
:
case
DISPID_SAX_XMLREADER_ENTITYRESOLVER
:
case
DISPID_SAX_XMLREADER_CONTENTHANDLER
:
case
DISPID_SAX_XMLREADER_DTDHANDLER
:
case
DISPID_SAX_XMLREADER_ERRORHANDLER
:
case
DISPID_MXXML_FILTER_ENTITYRESOLVER
:
case
DISPID_MXXML_FILTER_CONTENTHANDLER
:
case
DISPID_MXXML_FILTER_DTDHANDLER
:
case
DISPID_MXXML_FILTER_ERRORHANDLER
:
return
TRUE
;
default:
return
FALSE
;
}
}
static
HRESULT
WINAPI
DispatchEx_InvokeEx
(
IDispatchEx
*
iface
,
DISPID
id
,
LCID
lcid
,
WORD
wFlags
,
DISPPARAMS
*
pdp
,
static
HRESULT
WINAPI
DispatchEx_InvokeEx
(
IDispatchEx
*
iface
,
DISPID
id
,
LCID
lcid
,
WORD
wFlags
,
DISPPARAMS
*
pdp
,
VARIANT
*
pvarRes
,
EXCEPINFO
*
pei
,
IServiceProvider
*
pspCaller
)
VARIANT
*
pvarRes
,
EXCEPINFO
*
pei
,
IServiceProvider
*
pspCaller
)
{
{
...
@@ -601,6 +626,8 @@ static HRESULT WINAPI DispatchEx_InvokeEx(IDispatchEx *iface, DISPID id, LCID lc
...
@@ -601,6 +626,8 @@ static HRESULT WINAPI DispatchEx_InvokeEx(IDispatchEx *iface, DISPID id, LCID lc
return
E_FAIL
;
return
E_FAIL
;
}
}
if
(
is_propputref_id
(
id
)
&&
wFlags
==
DISPATCH_PROPERTYPUT
)
wFlags
=
DISPATCH_PROPERTYPUTREF
;
hres
=
ITypeInfo_Invoke
(
ti
,
unk
,
id
,
wFlags
,
pdp
,
pvarRes
,
pei
,
&
argerr
);
hres
=
ITypeInfo_Invoke
(
ti
,
unk
,
id
,
wFlags
,
pdp
,
pvarRes
,
pei
,
&
argerr
);
ITypeInfo_Release
(
ti
);
ITypeInfo_Release
(
ti
);
...
...
dlls/msxml3/tests/saxreader.c
View file @
d7aee26d
...
@@ -4432,11 +4432,14 @@ static void test_obj_dispex(IUnknown *obj)
...
@@ -4432,11 +4432,14 @@ static void test_obj_dispex(IUnknown *obj)
IDispatchEx_Release
(
dispex
);
IDispatchEx_Release
(
dispex
);
}
}
static
void
test_dispex
(
void
)
static
void
test_
saxreader_
dispex
(
void
)
{
{
IVBSAXXMLReader
*
vbreader
;
IVBSAXXMLReader
*
vbreader
;
ISAXXMLReader
*
reader
;
ISAXXMLReader
*
reader
;
DISPPARAMS
dispparams
;
DISPID
dispid
;
IUnknown
*
unk
;
IUnknown
*
unk
;
VARIANT
arg
;
HRESULT
hr
;
HRESULT
hr
;
hr
=
CoCreateInstance
(
&
CLSID_SAXXMLReader
,
NULL
,
CLSCTX_INPROC_SERVER
,
hr
=
CoCreateInstance
(
&
CLSID_SAXXMLReader
,
NULL
,
CLSCTX_INPROC_SERVER
,
...
@@ -4454,6 +4457,39 @@ static void test_dispex(void)
...
@@ -4454,6 +4457,39 @@ static void test_dispex(void)
EXPECT_HR
(
hr
,
S_OK
);
EXPECT_HR
(
hr
,
S_OK
);
test_obj_dispex
(
unk
);
test_obj_dispex
(
unk
);
IUnknown_Release
(
unk
);
IUnknown_Release
(
unk
);
dispid
=
DISPID_PROPERTYPUT
;
dispparams
.
cArgs
=
1
;
dispparams
.
cNamedArgs
=
1
;
dispparams
.
rgdispidNamedArgs
=
&
dispid
;
dispparams
.
rgvarg
=
&
arg
;
V_VT
(
&
arg
)
=
VT_DISPATCH
;
V_DISPATCH
(
&
arg
)
=
NULL
;
/* propputref is callable as PROPERTYPUT and PROPERTYPUTREF */
hr
=
IVBSAXXMLReader_Invoke
(
vbreader
,
DISPID_SAX_XMLREADER_CONTENTHANDLER
,
&
IID_NULL
,
0
,
DISPATCH_PROPERTYPUT
,
&
dispparams
,
NULL
,
NULL
,
NULL
);
ok
(
hr
==
S_OK
,
"got 0x%08x
\n
"
,
hr
);
hr
=
IVBSAXXMLReader_Invoke
(
vbreader
,
DISPID_SAX_XMLREADER_CONTENTHANDLER
,
&
IID_NULL
,
0
,
DISPATCH_PROPERTYPUTREF
,
&
dispparams
,
NULL
,
NULL
,
NULL
);
ok
(
hr
==
S_OK
,
"got 0x%08x
\n
"
,
hr
);
IVBSAXXMLReader_Release
(
vbreader
);
IVBSAXXMLReader_Release
(
vbreader
);
ISAXXMLReader_Release
(
reader
);
ISAXXMLReader_Release
(
reader
);
...
@@ -5518,7 +5554,7 @@ START_TEST(saxreader)
...
@@ -5518,7 +5554,7 @@ START_TEST(saxreader)
test_saxreader_properties
();
test_saxreader_properties
();
test_saxreader_features
();
test_saxreader_features
();
test_saxreader_encoding
();
test_saxreader_encoding
();
test_dispex
();
test_
saxreader_
dispex
();
/* MXXMLWriter tests */
/* MXXMLWriter tests */
get_class_support_data
(
mxwriter_support_data
,
&
IID_IMXWriter
);
get_class_support_data
(
mxwriter_support_data
,
&
IID_IMXWriter
);
...
...
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