0

I found "Modal View Controller" could have some changes in iOS4. Because, I used the example code below http://iosdevelopertips.com/video/getting-mpmovieplayercontroller-to-cooperate-with-ios4-3-2-ipad-and-earlier-versions-of-iphone-sdk.html

to perform the movie player controller using button. In iOS3, the page control still can work after dismiss modal view controller. But in iOS4 is not, I need to press the navigation bar on the upper-left corner to go back and then click the cell back to the view, then page control will work again.

What is the main reason causing this problem?

Cœur
  • 37,241
  • 25
  • 195
  • 267
Lee
  • 25
  • 7

1 Answers1

1

Below code copy and past the TestViewController ..Becoz Here AutoRelease the CustomMoviePlayer

- (void)loadMoviePlayer
{  
           // Play movie from the bundle

NSString *path = [[NSBundle mainBundle] pathForResource:@"Movie-1" ofType:@"mp4" inDirectory:nil];

// Create custom movie player   
   moviePlayer = [[CustomMoviePlayerViewController alloc] initWithPath:path];

// Show the movie player as modal
[self presentModalViewController:moviePlayer animated:YES];

// Prep and play the movie
    [moviePlayer readyPlayer];    
 }
Nag_iphone
  • 967
  • 7
  • 22