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
6ae3418a
Commit
6ae3418a
authored
Oct 08, 2012
by
Jacek Caban
Committed by
Alexandre Julliard
Oct 08, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mshtml: Return dispinterface from PHEventSink::QueryInterface.
parent
470137b6
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
19 additions
and
0 deletions
+19
-0
pluginhost.c
dlls/mshtml/pluginhost.c
+14
-0
activex.c
dlls/mshtml/tests/activex.c
+5
-0
No files found.
dlls/mshtml/pluginhost.c
View file @
6ae3418a
...
...
@@ -485,6 +485,7 @@ struct PHEventSink {
ITypeInfo
*
typeinfo
;
GUID
iid
;
DWORD
cookie
;
BOOL
is_dispiface
;
sink_entry_t
*
handlers
;
DWORD
handlers_cnt
;
...
...
@@ -548,6 +549,9 @@ static HRESULT WINAPI PHEventSink_QueryInterface(IDispatch *iface, REFIID riid,
}
else
if
(
IsEqualGUID
(
riid
,
&
IID_IDispatch
))
{
TRACE
(
"(%p)->(IID_IDispatch %p)
\n
"
,
This
,
ppv
);
*
ppv
=
&
This
->
IDispatch_iface
;
}
else
if
(
This
->
is_dispiface
&&
IsEqualGUID
(
riid
,
&
This
->
iid
))
{
TRACE
(
"(%p)->(%s %p)
\n
"
,
This
,
debugstr_guid
(
riid
),
ppv
);
*
ppv
=
&
This
->
IDispatch_iface
;
}
else
{
WARN
(
"(%p)->(%s %p)
\n
"
,
This
,
debugstr_guid
(
riid
),
ppv
);
*
ppv
=
NULL
;
...
...
@@ -670,6 +674,7 @@ static PHEventSink *create_event_sink(PluginHost *plugin_host, ITypeInfo *typein
PHEventSink
*
ret
;
IConnectionPoint
*
cp
;
TYPEATTR
*
typeattr
;
TYPEKIND
typekind
;
GUID
guid
;
HRESULT
hres
;
...
...
@@ -677,9 +682,17 @@ static PHEventSink *create_event_sink(PluginHost *plugin_host, ITypeInfo *typein
if
(
FAILED
(
hres
))
return
NULL
;
typekind
=
typeattr
->
typekind
;
guid
=
typeattr
->
guid
;
ITypeInfo_ReleaseTypeAttr
(
typeinfo
,
typeattr
);
TRACE
(
"guid %s typekind %d
\n
"
,
debugstr_guid
(
&
guid
),
typekind
);
if
(
typekind
!=
TKIND_INTERFACE
&&
typekind
!=
TKIND_DISPATCH
)
{
WARN
(
"invalid typekind %d
\n
"
,
typekind
);
return
NULL
;
}
hres
=
IUnknown_QueryInterface
(
plugin_host
->
plugin_unk
,
&
IID_IConnectionPointContainer
,
(
void
**
)
&
cp_container
);
if
(
FAILED
(
hres
))
{
WARN
(
"Could not get IConnectionPointContainer iface: %08x
\n
"
,
hres
);
...
...
@@ -699,6 +712,7 @@ static PHEventSink *create_event_sink(PluginHost *plugin_host, ITypeInfo *typein
ret
->
ref
=
1
;
ret
->
host
=
plugin_host
;
ret
->
iid
=
guid
;
ret
->
is_dispiface
=
typekind
==
TKIND_DISPATCH
;
ITypeInfo_AddRef
(
typeinfo
);
ret
->
typeinfo
=
typeinfo
;
...
...
dlls/mshtml/tests/activex.c
View file @
6ae3418a
...
...
@@ -331,6 +331,7 @@ static HRESULT WINAPI ConnectionPoint_GetConnectionPointContainer(IConnectionPoi
static
HRESULT
WINAPI
ConnectionPoint_Advise
(
IConnectionPoint
*
iface
,
IUnknown
*
pUnkSink
,
DWORD
*
pdwCookie
)
{
DispActiveXTest
*
ax_test
;
IDispatchEx
*
dispex
;
HRESULT
hres
;
...
...
@@ -342,6 +343,10 @@ static HRESULT WINAPI ConnectionPoint_Advise(IConnectionPoint *iface, IUnknown *
hres
=
IUnknown_QueryInterface
(
pUnkSink
,
&
IID_IDispatchEx
,
(
void
**
)
&
dispex
);
ok
(
hres
==
E_NOINTERFACE
,
"QueryInterface(IID_IDispatchEx) returned: %08x
\n
"
,
hres
);
hres
=
IUnknown_QueryInterface
(
pUnkSink
,
&
DIID_DispActiveXTest
,
(
void
**
)
&
ax_test
);
ok
(
hres
==
S_OK
,
"Could not get DispActiveXTest iface: %08x
\n
"
,
hres
);
DispActiveXTest_Release
(
ax_test
);
*
pdwCookie
=
0xdeadbeef
;
return
S_OK
;
}
...
...
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