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
8e77be63
Commit
8e77be63
authored
Dec 08, 2010
by
Michael Stefaniuc
Committed by
Alexandre Julliard
Dec 09, 2010
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mmdevapi: Use an iface instead of a vtbl pointer in AEVImpl.
parent
31aec425
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
5 deletions
+10
-5
audiovolume.c
dlls/mmdevapi/audiovolume.c
+10
-5
No files found.
dlls/mmdevapi/audiovolume.c
View file @
8e77be63
...
...
@@ -54,10 +54,15 @@ WINE_DEFAULT_DEBUG_CHANNEL(mmdevapi);
static
const
IAudioEndpointVolumeExVtbl
AEVImpl_Vtbl
;
typedef
struct
AEVImpl
{
const
IAudioEndpointVolumeExVtbl
*
lpVtbl
;
IAudioEndpointVolumeEx
IAudioEndpointVolumeEx_iface
;
LONG
ref
;
}
AEVImpl
;
static
inline
AEVImpl
*
impl_from_IAudioEndpointVolumeEx
(
IAudioEndpointVolumeEx
*
iface
)
{
return
CONTAINING_RECORD
(
iface
,
AEVImpl
,
IAudioEndpointVolumeEx_iface
);
}
HRESULT
AudioEndpointVolume_Create
(
MMDevice
*
parent
,
IAudioEndpointVolume
**
ppv
)
{
AEVImpl
*
This
;
...
...
@@ -65,7 +70,7 @@ HRESULT AudioEndpointVolume_Create(MMDevice *parent, IAudioEndpointVolume **ppv)
*
ppv
=
(
IAudioEndpointVolume
*
)
This
;
if
(
!
This
)
return
E_OUTOFMEMORY
;
This
->
lpVtbl
=
&
AEVImpl_Vtbl
;
This
->
IAudioEndpointVolumeEx_iface
.
lpVtbl
=
&
AEVImpl_Vtbl
;
This
->
ref
=
1
;
return
S_OK
;
}
...
...
@@ -77,7 +82,7 @@ static void AudioEndpointVolume_Destroy(AEVImpl *This)
static
HRESULT
WINAPI
AEV_QueryInterface
(
IAudioEndpointVolumeEx
*
iface
,
REFIID
riid
,
void
**
ppv
)
{
AEVImpl
*
This
=
(
AEVImpl
*
)
iface
;
AEVImpl
*
This
=
impl_from_IAudioEndpointVolumeEx
(
iface
)
;
TRACE
(
"(%p)->(%s,%p)
\n
"
,
This
,
debugstr_guid
(
riid
),
ppv
);
if
(
!
ppv
)
return
E_POINTER
;
...
...
@@ -95,7 +100,7 @@ static HRESULT WINAPI AEV_QueryInterface(IAudioEndpointVolumeEx *iface, REFIID r
static
ULONG
WINAPI
AEV_AddRef
(
IAudioEndpointVolumeEx
*
iface
)
{
AEVImpl
*
This
=
(
AEVImpl
*
)
iface
;
AEVImpl
*
This
=
impl_from_IAudioEndpointVolumeEx
(
iface
)
;
ULONG
ref
=
InterlockedIncrement
(
&
This
->
ref
);
TRACE
(
"(%p) new ref %u
\n
"
,
This
,
ref
);
return
ref
;
...
...
@@ -103,7 +108,7 @@ static ULONG WINAPI AEV_AddRef(IAudioEndpointVolumeEx *iface)
static
ULONG
WINAPI
AEV_Release
(
IAudioEndpointVolumeEx
*
iface
)
{
AEVImpl
*
This
=
(
AEVImpl
*
)
iface
;
AEVImpl
*
This
=
impl_from_IAudioEndpointVolumeEx
(
iface
)
;
ULONG
ref
=
InterlockedDecrement
(
&
This
->
ref
);
TRACE
(
"(%p) new ref %u
\n
"
,
This
,
ref
);
if
(
!
ref
)
...
...
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