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
87dba384
Commit
87dba384
authored
Oct 25, 2023
by
Rémi Bernon
Committed by
Alexandre Julliard
Nov 06, 2023
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dmime: Send notification messages with DMUS_PMSGF_TOOL_IMMEDIATE.
Then send them again with DMUS_PMSGF_TOOL_ATTIME for the notification queue.
parent
ae010a1a
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
3 deletions
+18
-3
performance.c
dlls/dmime/performance.c
+18
-3
No files found.
dlls/dmime/performance.c
View file @
87dba384
...
...
@@ -199,7 +199,7 @@ static HRESULT performance_send_notification_pmsg(struct performance *This, MUSI
return
hr
;
msg
->
mtTime
=
music_time
;
msg
->
dwFlags
=
DMUS_PMSGF_MUSICTIME
|
DMUS_PMSGF_TOOL_
QUEU
E
;
msg
->
dwFlags
=
DMUS_PMSGF_MUSICTIME
|
DMUS_PMSGF_TOOL_
IMMEDIAT
E
;
msg
->
dwType
=
DMUS_PMSGT_NOTIFICATION
;
if
((
msg
->
punkUser
=
object
))
IUnknown_AddRef
(
object
);
msg
->
guidNotificationType
=
type
;
...
...
@@ -1230,7 +1230,7 @@ static HRESULT WINAPI performance_PlaySegmentEx(IDirectMusicPerformance8 *iface,
hr
=
performance_send_notification_pmsg
(
This
,
start_time
,
This
->
notification_segment
,
GUID_NOTIFICATION_SEGMENT
,
DMUS_NOTIFICATION_SEGSTART
,
(
IUnknown
*
)
state
);
if
(
SUCCEEDED
(
hr
))
hr
=
performance_send_pmsg
(
This
,
start_time
,
DMUS_PMSGF_TOOL_
QUEU
E
,
DMUS_PMSGT_DIRTY
,
NULL
);
hr
=
performance_send_pmsg
(
This
,
start_time
,
DMUS_PMSGF_TOOL_
IMMEDIAT
E
,
DMUS_PMSGT_DIRTY
,
NULL
);
if
(
SUCCEEDED
(
hr
))
hr
=
segment_state_play
(
state
,
iface
);
...
...
@@ -1242,7 +1242,7 @@ static HRESULT WINAPI performance_PlaySegmentEx(IDirectMusicPerformance8 *iface,
hr
=
performance_send_notification_pmsg
(
This
,
start_time
+
length
,
This
->
notification_segment
,
GUID_NOTIFICATION_SEGMENT
,
DMUS_NOTIFICATION_SEGALMOSTEND
,
(
IUnknown
*
)
state
);
if
(
SUCCEEDED
(
hr
))
hr
=
performance_send_pmsg
(
This
,
start_time
+
length
,
DMUS_PMSGF_TOOL_
QUEU
E
,
DMUS_PMSGT_DIRTY
,
NULL
);
hr
=
performance_send_pmsg
(
This
,
start_time
+
length
,
DMUS_PMSGF_TOOL_
IMMEDIAT
E
,
DMUS_PMSGT_DIRTY
,
NULL
);
if
(
SUCCEEDED
(
hr
))
hr
=
performance_send_notification_pmsg
(
This
,
start_time
+
length
,
This
->
notification_performance
,
GUID_NOTIFICATION_PERFORMANCE
,
DMUS_NOTIFICATION_MUSICSTOPPED
,
NULL
);
...
...
@@ -1790,6 +1790,21 @@ static HRESULT WINAPI performance_tool_ProcessPMsg(IDirectMusicTool *iface,
enabled
=
This
->
notification_segment
;
if
(
!
enabled
)
return
DMUS_S_FREE
;
if
(
msg
->
dwFlags
&
DMUS_PMSGF_TOOL_IMMEDIATE
)
{
/* re-send the message for queueing at the expected time */
msg
->
dwFlags
&=
~
DMUS_PMSGF_TOOL_IMMEDIATE
;
msg
->
dwFlags
|=
DMUS_PMSGF_TOOL_ATTIME
;
if
(
FAILED
(
hr
=
IDirectMusicPerformance8_SendPMsg
(
performance
,
(
DMUS_PMSG
*
)
msg
)))
{
ERR
(
"Failed to send notification message, hr %#lx
\n
"
,
hr
);
return
DMUS_S_FREE
;
}
return
S_OK
;
}
list_add_tail
(
&
This
->
notifications
,
&
message
->
entry
);
/* discard old notification messages */
...
...
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