Skip to content

Commit

Permalink
Merge pull request xbmc#4534 from popcornmix/dvdplayer_merge
Browse files Browse the repository at this point in the history
[omxplayer] merge missed commits from dvdplayer
  • Loading branch information
t-nelson committed Apr 10, 2014
1 parent af8a18a commit 4c3700e
Showing 1 changed file with 15 additions and 13 deletions.
28 changes: 15 additions & 13 deletions xbmc/cores/omxplayer/OMXPlayer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -612,17 +612,9 @@ bool COMXPlayer::OpenFile(const CFileItem &file, const CPlayerOptions &options)
#endif

Create();
if(!m_ready.WaitMSec(g_advancedSettings.m_videoBusyDialogDelay_ms))
{
CGUIDialogBusy* dialog = (CGUIDialogBusy*)g_windowManager.GetWindow(WINDOW_DIALOG_BUSY);
if(dialog)
{
dialog->Show();
while(!m_ready.WaitMSec(1))
g_windowManager.ProcessRenderLoop(false);
dialog->Close();
}
}

// wait for the ready event
CGUIDialogBusy::WaitOnEvent(m_ready, g_advancedSettings.m_videoBusyDialogDelay_ms, false);

// Playback might have been stopped due to some error
if (m_bStop || m_bAbortRequest)
Expand Down Expand Up @@ -1075,7 +1067,7 @@ void COMXPlayer::Process()
if (CDVDInputStream::IMenus* ptr = dynamic_cast<CDVDInputStream::IMenus*>(m_pInputStream))
{
CLog::Log(LOGNOTICE, "OMXPlayer: playing a file with menu's");
if(CDVDInputStreamNavigator* nav = dynamic_cast<CDVDInputStreamNavigator*>(m_pInputStream))
if(dynamic_cast<CDVDInputStreamNavigator*>(m_pInputStream))
m_PlayerOptions.starttime = 0;

if(m_PlayerOptions.state.size() > 0)
Expand Down Expand Up @@ -3682,6 +3674,12 @@ int COMXPlayer::OnDVDNavResult(void* pData, int iMessage)
m_dvd.iDVDStillTime, time / 1000);
}
}
else if (iMessage == 6)
{
m_dvd.state = DVDSTATE_NORMAL;
CLog::Log(LOGDEBUG, "COMXPlayer::OnDVDNavResult - libbluray read error (DVDSTATE_NORMAL)");
CGUIDialogKaiToast::QueueNotification(g_localizeStrings.Get(25008), g_localizeStrings.Get(25009));
}

return 0;
}
Expand Down Expand Up @@ -4119,7 +4117,7 @@ bool COMXPlayer::HasMenu()
{
CDVDInputStream::IMenus* pStream = dynamic_cast<CDVDInputStream::IMenus*>(m_pInputStream);
if (pStream)
return true;
return pStream->HasMenu();
else
return false;
}
Expand Down Expand Up @@ -4322,6 +4320,10 @@ void COMXPlayer::UpdatePlayState(double timeout)
state.dts = m_CurrentVideo.dts;
else if(m_CurrentAudio.dts != DVD_NOPTS_VALUE)
state.dts = m_CurrentAudio.dts;
else if(m_CurrentVideo.startpts != DVD_NOPTS_VALUE)
state.dts = m_CurrentVideo.startpts;
else if(m_CurrentAudio.startpts != DVD_NOPTS_VALUE)
state.dts = m_CurrentAudio.startpts;

if(m_pDemuxer)
{
Expand Down

0 comments on commit 4c3700e

Please sign in to comment.