Compare commits
4 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| dd8b5b9dc6 | |||
| 5775bbc2af | |||
| 0a9707d68f | |||
| c1c2f93793 |
@@ -9,7 +9,7 @@
|
||||
Pod::Spec.new do |s|
|
||||
|
||||
s.name = "VIMVideoPlayer"
|
||||
s.version = "5.5"
|
||||
s.version = "5.5.3"
|
||||
s.summary = "A simple wrapper around the AVPlayer and AVPlayerLayer classes."
|
||||
s.description = <<-DESC
|
||||
VIMVideoPlayer is a simple wrapper around the AVPlayer and AVPlayerLayer classes. Check out the README for details. And the Pegasus project for a demo.
|
||||
|
||||
@@ -702,14 +702,29 @@ static void *VideoPlayer_PlayerItemLoadedTimeRangesContext = &VideoPlayer_Player
|
||||
}
|
||||
case AVPlayerItemStatusFailed:
|
||||
{
|
||||
NSLog(@"Video player Status Failed: error = %@", self.player.currentItem.error);
|
||||
NSLog(@"Video player Status Failed: player item error = %@", self.player.currentItem.error);
|
||||
NSLog(@"Video player Status Failed: player error = %@", self.player.error);
|
||||
|
||||
if ([self.delegate respondsToSelector:@selector(videoPlayer:didFailWithError:)])
|
||||
{
|
||||
[self reset];
|
||||
|
||||
dispatch_async(dispatch_get_main_queue(), ^{
|
||||
[self.delegate videoPlayer:self didFailWithError:self.player.currentItem.error];
|
||||
|
||||
if (self.player.error)
|
||||
{
|
||||
[self.delegate videoPlayer:self didFailWithError:self.player.error];
|
||||
}
|
||||
else if (self.player.currentItem.error)
|
||||
{
|
||||
[self.delegate videoPlayer:self didFailWithError:self.player.currentItem.error];
|
||||
}
|
||||
else
|
||||
{
|
||||
NSError *error = [NSError errorWithDomain:kVideoPlayerErrorDomain code:0 userInfo:@{NSLocalizedDescriptionKey : @"unknown player error, status == AVPlayerItemStatusFailed"}];
|
||||
[self.delegate videoPlayer:self didFailWithError:error];
|
||||
}
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user