wxSOUND_SYNC is zero so it can't be used in a
(flags & wxSOUND_SYNC) test as it woudl always evaluate to false. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@28371 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -387,7 +387,13 @@ bool wxSound::DoPlay(unsigned flags) const
|
||||
//Start the movie!
|
||||
StartMovie(movie);
|
||||
|
||||
if (flags & wxSOUND_SYNC)
|
||||
if (flags & wxSOUND_ASYNC)
|
||||
{
|
||||
//Start timer and play movie asyncronously
|
||||
((wxQTTimer*&)m_pTimer) = new wxQTTimer(movie, flags & wxSOUND_LOOP ? 1 : 0);
|
||||
((wxQTTimer*)m_pTimer)->Start(MOVIE_DELAY, wxTIMER_CONTINUOUS);
|
||||
}
|
||||
else
|
||||
{
|
||||
wxASSERT_MSG(!(flags & wxSOUND_LOOP), "Can't loop and play syncronously at the same time");
|
||||
|
||||
@@ -397,12 +403,6 @@ bool wxSound::DoPlay(unsigned flags) const
|
||||
|
||||
DisposeMovie(movie);
|
||||
}
|
||||
else
|
||||
{
|
||||
//Start timer and play movie asyncronously
|
||||
((wxQTTimer*&)m_pTimer) = new wxQTTimer(movie, flags & wxSOUND_LOOP ? 1 : 0);
|
||||
((wxQTTimer*)m_pTimer)->Start(MOVIE_DELAY, wxTIMER_CONTINUOUS);
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
Reference in New Issue
Block a user