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
66a515ae
Commit
66a515ae
authored
Dec 04, 2010
by
Michael Stefaniuc
Committed by
Alexandre Julliard
Dec 05, 2010
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
devenum: Use an iface instead of an vtbl pointer in RegPropBagImpl.
parent
d335af1e
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
8 deletions
+13
-8
mediacatenum.c
dlls/devenum/mediacatenum.c
+13
-8
No files found.
dlls/devenum/mediacatenum.c
View file @
66a515ae
...
...
@@ -36,18 +36,23 @@ static ULONG WINAPI DEVENUM_IPropertyBag_AddRef(LPPROPERTYBAG iface);
typedef
struct
{
const
IPropertyBagVtbl
*
lpVtbl
;
IPropertyBag
IPropertyBag_iface
;
LONG
ref
;
HKEY
hkey
;
}
RegPropBagImpl
;
static
inline
RegPropBagImpl
*
impl_from_IPropertyBag
(
IPropertyBag
*
iface
)
{
return
CONTAINING_RECORD
(
iface
,
RegPropBagImpl
,
IPropertyBag_iface
);
}
static
HRESULT
WINAPI
DEVENUM_IPropertyBag_QueryInterface
(
LPPROPERTYBAG
iface
,
REFIID
riid
,
LPVOID
*
ppvObj
)
{
RegPropBagImpl
*
This
=
(
RegPropBagImpl
*
)
iface
;
RegPropBagImpl
*
This
=
impl_from_IPropertyBag
(
iface
)
;
TRACE
(
"(%p)->(%s, %p)
\n
"
,
iface
,
debugstr_guid
(
riid
),
ppvObj
);
...
...
@@ -70,7 +75,7 @@ static HRESULT WINAPI DEVENUM_IPropertyBag_QueryInterface(
*/
static
ULONG
WINAPI
DEVENUM_IPropertyBag_AddRef
(
LPPROPERTYBAG
iface
)
{
RegPropBagImpl
*
This
=
(
RegPropBagImpl
*
)
iface
;
RegPropBagImpl
*
This
=
impl_from_IPropertyBag
(
iface
)
;
TRACE
(
"(%p)->() AddRef from %d
\n
"
,
iface
,
This
->
ref
);
...
...
@@ -82,7 +87,7 @@ static ULONG WINAPI DEVENUM_IPropertyBag_AddRef(LPPROPERTYBAG iface)
*/
static
ULONG
WINAPI
DEVENUM_IPropertyBag_Release
(
LPPROPERTYBAG
iface
)
{
RegPropBagImpl
*
This
=
(
RegPropBagImpl
*
)
iface
;
RegPropBagImpl
*
This
=
impl_from_IPropertyBag
(
iface
)
;
ULONG
ref
;
TRACE
(
"(%p)->() ReleaseThis->ref from %d
\n
"
,
iface
,
This
->
ref
);
...
...
@@ -105,7 +110,7 @@ static HRESULT WINAPI DEVENUM_IPropertyBag_Read(
LPVOID
pData
=
NULL
;
DWORD
received
;
DWORD
type
=
0
;
RegPropBagImpl
*
This
=
(
RegPropBagImpl
*
)
iface
;
RegPropBagImpl
*
This
=
impl_from_IPropertyBag
(
iface
)
;
HRESULT
res
=
S_OK
;
LONG
reswin32
;
...
...
@@ -212,7 +217,7 @@ static HRESULT WINAPI DEVENUM_IPropertyBag_Write(
LPCOLESTR
pszPropName
,
VARIANT
*
pVar
)
{
RegPropBagImpl
*
This
=
(
RegPropBagImpl
*
)
iface
;
RegPropBagImpl
*
This
=
impl_from_IPropertyBag
(
iface
)
;
LPVOID
lpData
=
NULL
;
DWORD
cbData
=
0
;
DWORD
dwType
=
0
;
...
...
@@ -277,10 +282,10 @@ static HRESULT DEVENUM_IPropertyBag_Construct(HANDLE hkey, IPropertyBag **ppBag)
RegPropBagImpl
*
rpb
=
CoTaskMemAlloc
(
sizeof
(
RegPropBagImpl
));
if
(
!
rpb
)
return
E_OUTOFMEMORY
;
rpb
->
lpVtbl
=
&
IPropertyBag_Vtbl
;
rpb
->
IPropertyBag_iface
.
lpVtbl
=
&
IPropertyBag_Vtbl
;
rpb
->
ref
=
1
;
rpb
->
hkey
=
hkey
;
*
ppBag
=
(
IPropertyBag
*
)
rpb
;
*
ppBag
=
&
rpb
->
IPropertyBag_iface
;
DEVENUM_LockModule
();
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