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
32fe620c
Commit
32fe620c
authored
Dec 08, 2010
by
Michael Stefaniuc
Committed by
Alexandre Julliard
Dec 09, 2010
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ole32: Use ifaces instead of vtbl pointers in Context.
parent
e362c67a
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
14 deletions
+14
-14
compobj.c
dlls/ole32/compobj.c
+14
-14
No files found.
dlls/ole32/compobj.c
View file @
32fe620c
...
...
@@ -3742,26 +3742,26 @@ HRESULT WINAPI CoRegisterChannelHook(REFGUID guidExtension, IChannelHook *pChann
typedef
struct
Context
{
const
IComThreadingInfoVtbl
*
lpVtbl
;
const
IContextCallbackVtbl
*
lpCallbackVtbl
;
const
IObjContextVtbl
*
lpContextVtbl
;
IComThreadingInfo
IComThreadingInfo_iface
;
IContextCallback
IContextCallback_iface
;
IObjContext
IObjContext_iface
;
LONG
refs
;
APTTYPE
apttype
;
}
Context
;
static
inline
Context
*
impl_from_IComThreadingInfo
(
IComThreadingInfo
*
iface
)
{
return
(
Context
*
)((
char
*
)
iface
-
FIELD_OFFSET
(
Context
,
lpVtbl
)
);
return
CONTAINING_RECORD
(
iface
,
Context
,
IComThreadingInfo_iface
);
}
static
inline
Context
*
impl_from_IContextCallback
(
IContextCallback
*
iface
)
{
return
(
Context
*
)((
char
*
)
iface
-
FIELD_OFFSET
(
Context
,
lpCallbackVtbl
)
);
return
CONTAINING_RECORD
(
iface
,
Context
,
IContextCallback_iface
);
}
static
inline
Context
*
impl_from_IObjContext
(
IObjContext
*
iface
)
{
return
(
Context
*
)((
char
*
)
iface
-
FIELD_OFFSET
(
Context
,
lpContextVtbl
)
);
return
CONTAINING_RECORD
(
iface
,
Context
,
IObjContext_iface
);
}
static
HRESULT
Context_QueryInterface
(
Context
*
iface
,
REFIID
riid
,
LPVOID
*
ppv
)
...
...
@@ -3771,15 +3771,15 @@ static HRESULT Context_QueryInterface(Context *iface, REFIID riid, LPVOID *ppv)
if
(
IsEqualIID
(
riid
,
&
IID_IComThreadingInfo
)
||
IsEqualIID
(
riid
,
&
IID_IUnknown
))
{
*
ppv
=
&
iface
->
lpVtbl
;
*
ppv
=
&
iface
->
IComThreadingInfo_iface
;
}
else
if
(
IsEqualIID
(
riid
,
&
IID_IContextCallback
))
{
*
ppv
=
&
iface
->
lpCallbackVtbl
;
*
ppv
=
&
iface
->
IContextCallback_iface
;
}
else
if
(
IsEqualIID
(
riid
,
&
IID_IObjContext
))
{
*
ppv
=
&
iface
->
lpContextVtbl
;
*
ppv
=
&
iface
->
IObjContext_iface
;
}
if
(
*
ppv
)
...
...
@@ -4056,9 +4056,9 @@ HRESULT WINAPI CoGetObjectContext(REFIID riid, void **ppv)
if
(
!
context
)
return
E_OUTOFMEMORY
;
context
->
lpVtbl
=
&
Context_Threading_Vtbl
;
context
->
lpCallback
Vtbl
=
&
Context_Callback_Vtbl
;
context
->
lpContext
Vtbl
=
&
Context_Object_Vtbl
;
context
->
IComThreadingInfo_iface
.
lpVtbl
=
&
Context_Threading_Vtbl
;
context
->
IContextCallback_iface
.
lp
Vtbl
=
&
Context_Callback_Vtbl
;
context
->
IObjContext_iface
.
lp
Vtbl
=
&
Context_Object_Vtbl
;
context
->
refs
=
1
;
if
(
apt
->
multi_threaded
)
context
->
apttype
=
APTTYPE_MTA
;
...
...
@@ -4067,8 +4067,8 @@ HRESULT WINAPI CoGetObjectContext(REFIID riid, void **ppv)
else
context
->
apttype
=
APTTYPE_STA
;
hr
=
IUnknown_QueryInterface
((
IUnknown
*
)
&
context
->
lpVtbl
,
riid
,
ppv
);
IUnknown_Release
((
IUnknown
*
)
&
context
->
lpVtbl
);
hr
=
IUnknown_QueryInterface
((
IUnknown
*
)
&
context
->
IComThreadingInfo_iface
,
riid
,
ppv
);
IUnknown_Release
((
IUnknown
*
)
&
context
->
IComThreadingInfo_iface
);
return
hr
;
}
...
...
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