4

次のコードで通知を追加しました。

  [[NSNotificationCenter defaultCenter] addObserver:self
                                         selector:@selector(videoLoadingComplete)
                                           name:MPMovieNaturalSizeAvailableNotification
                                          object:self.streamPlayer];

videoLoadingCompleteしかし、ビデオスターが再生された後でも、それは機能に入りませんでした。

4

1 に答える 1

1

次のコードを使用できます

[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(moviestart:)   name:MPMoviePlayerLoadStateDidChangeNotification object:nil];
 -(void)moviestart
{
//your code here
}
于 2012-10-09T07:56:37.933 に答える