689
689
SetCanPause (false);
690
690
SetCanSeek (false);
691
691
SetDownloadProgress (0);
693
SetState (MediaElement::Error);
693
// Always terminate the downloader, even if we will transition
694
// to the next item in the playlist in case of Surface::GetRelaxedMediaMode
695
695
DownloaderAbort ();
697
Emit (MediaFailedEvent, args);
697
if (!GetSurface ()->GetRelaxedMediaMode () ||
698
playlist == NULL || playlist->IsCurrentEntryLastEntry ()) {
699
// This will cause the entire playlist to stop playing, even if there
700
// are entries after the current item that may be consumable
701
SetState (MediaElement::Error);
702
Emit (MediaFailedEvent, args);
704
// This allows the playlist to continue playing
705
// even though the current item was invalid
706
Emit (MediaEndedEvent);
707
playlist->OnEntryEnded ();