Anybody familiar with MPMoviePlayerController class? The Apple sample code begins playing the movie after allocating and initializing it like this:
Code:
MPMoviePlayerController *mp = [[MPMoviePlayerController alloc] initWithContentURL:movieURL];
...
[mp play]
This does not let the moviePreloadDidFinish notification to be called. If an error occurs in pre-loading then the movie will try to play anyways. I think it would be better to play the movie object when the notification is called:
Code:
- (void) moviePreloadDidFinish:(NSNotification*)notification {
NSDictionary *info = [notification userInfo];
// Check if info contains error
// Play object IF error did not occur
MPMoviePlayerController* moviePlayerObj=[notification object];
[moviePlayerObj play];
}
Thoughts?