iphone - creating a reference to a MPMoviePlayerController
- by Mike
At some point in my code I am creating a MPMoviePlayerController object and playing it.
As I need to reference this object at some other methods in my code that runs asynchronously, I need to store a pointer to the movie object etc., so I can use that.
Declaring
MPMoviePlayerController * myMovie
on the header file is out of question, because the compiler will give me an error saying "expected specifier-qualifier-list before 'MPMoviePlayerController'".
If it was a view I could do something like
[self.view viewWithTag:99];
to get the object, but the MPMoviePlayerController does not allow this.
How can I obtain the movie object or store a reference to it, so I can call the object in other methods?
thanks for any help.