minor changes as per RN comments - add some comments and reorder a switch stmt.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@37200 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -2086,10 +2086,9 @@ public:
|
||||
void Notify()
|
||||
{
|
||||
// NB: Stop events could get triggered by the interface
|
||||
// if ShowPlayerControls is enabled,
|
||||
// so we need this hack here to make an attempt
|
||||
// at it not getting sent - but its far from ideal -
|
||||
// they can still get sent in some cases
|
||||
// if ShowPlayerControls is enabled, so the "GetPosition == GetDuration"
|
||||
// hack is needed here to make an attempt at it not getting sent
|
||||
// - but its far from ideal - they can still get sent in some cases
|
||||
if (m_parent->GetState() == wxMEDIASTATE_STOPPED &&
|
||||
m_parent->GetPosition() == m_parent->GetDuration())
|
||||
{
|
||||
@@ -2563,8 +2562,7 @@ bool wxAMMediaBackend::Stop()
|
||||
bool wxAMMediaBackend::SetPosition(wxLongLong where)
|
||||
{
|
||||
HRESULT hr = GetAM()->put_CurrentPosition(
|
||||
((LONGLONG)where.GetValue()) / 1000.0
|
||||
);
|
||||
((LONGLONG)where.GetValue()) / 1000.0 );
|
||||
if (FAILED(hr))
|
||||
{
|
||||
wxAMLOG(hr);
|
||||
@@ -4061,10 +4059,18 @@ Boolean wxQTMediaBackend::MCFilterProc(MovieController WXUNUSED(theController),
|
||||
void * WXUNUSED(params),
|
||||
LONG_PTR refCon)
|
||||
{
|
||||
// NB: potential optimisation
|
||||
// if (action == 1)
|
||||
// return 0;
|
||||
|
||||
wxQTMediaBackend* pThis = (wxQTMediaBackend*)refCon;
|
||||
|
||||
switch (action)
|
||||
{
|
||||
case 1:
|
||||
// don't process idle events
|
||||
break;
|
||||
|
||||
case 8:
|
||||
// play button triggered - MC will set movie to opposite state
|
||||
// of current - playing ? paused : playing
|
||||
@@ -4078,10 +4084,6 @@ Boolean wxQTMediaBackend::MCFilterProc(MovieController WXUNUSED(theController),
|
||||
// to help this unfortunately
|
||||
break;
|
||||
|
||||
case 1:
|
||||
// don't process idle events
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
Reference in New Issue
Block a user