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
72165fc8
Commit
72165fc8
authored
Oct 12, 2023
by
Rémi Bernon
Committed by
Alexandre Julliard
Oct 17, 2023
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dmusic: Forward IDirectMusicPort_Activate to synth and sink.
parent
29a76fb5
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
24 additions
and
18 deletions
+24
-18
port.c
dlls/dmusic/port.c
+24
-18
No files found.
dlls/dmusic/port.c
View file @
72165fc8
...
...
@@ -274,30 +274,36 @@ static HRESULT WINAPI synth_port_GetNumChannelGroups(IDirectMusicPort *iface, DW
static
HRESULT
WINAPI
synth_port_Activate
(
IDirectMusicPort
*
iface
,
BOOL
active
)
{
struct
synth_port
*
This
=
synth_from_IDirectMusicPort
(
iface
);
HRESULT
hr
;
FIXME
(
"(%p/%p)->(%d): semi-stub
\n
"
,
iface
,
This
,
active
);
TRACE
(
"(%p/%p)->(%d)
\n
"
,
iface
,
This
,
active
);
if
(
This
->
active
==
active
)
return
S_FALSE
;
if
(
This
->
active
==
active
)
return
S_FALSE
;
if
(
active
)
{
/* Acquire the dsound */
if
(
!
This
->
dsound
)
{
IDirectSound_AddRef
(
This
->
parent
->
dsound
);
This
->
dsound
=
This
->
parent
->
dsound
;
}
IDirectSound_AddRef
(
This
->
dsound
);
}
else
{
/* Release the dsound */
IDirectSound_Release
(
This
->
dsound
);
IDirectSound_Release
(
This
->
parent
->
dsound
);
if
(
This
->
dsound
==
This
->
parent
->
dsound
)
This
->
dsound
=
NULL
;
if
(
active
)
{
if
(
!
This
->
dsound
&&
FAILED
(
hr
=
IDirectMusicPort_SetDirectSound
(
iface
,
This
->
parent
->
dsound
,
NULL
)))
return
hr
;
if
(
FAILED
(
hr
=
IDirectMusicSynthSink_SetDirectSound
(
This
->
synth_sink
,
This
->
dsound
,
This
->
dsbuffer
)))
return
hr
;
if
(
FAILED
(
hr
=
IDirectMusicSynth_Activate
(
This
->
synth
,
active
)))
return
hr
;
This
->
active
=
TRUE
;
}
else
{
if
(
FAILED
(
hr
=
IDirectMusicSynth_Activate
(
This
->
synth
,
FALSE
)))
return
hr
;
This
->
active
=
FALSE
;
This
->
active
=
active
;
if
(
FAILED
(
hr
=
IDirectMusicSynthSink_SetDirectSound
(
This
->
synth_sink
,
NULL
,
NULL
)))
return
hr
;
hr
=
IDirectMusicPort_SetDirectSound
(
iface
,
NULL
,
NULL
);
}
return
S_OK
;
return
hr
;
}
static
HRESULT
WINAPI
synth_port_SetChannelPriority
(
IDirectMusicPort
*
iface
,
DWORD
channel_group
,
...
...
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