ios - MPMoviePlayer how do you detect ONLY when a user seeks forward? -
thanks assistance, have movie player, , want prevent user scrubbing forward through movie, dont care if go backwards (rewind). detecting when playback state changing, , testing "mpmovieplayerdidseekingforward"
the problem playbackstate seeking forward when scrub regardless of direction.
for various reasons cant make own custom player, need work standard mpmovieplayer.
here code:
- (void)movieplayerplaybackstatedidchangenotificationreceived:(nsnotification *)notification {      //movie playback has started go full screen.      if(_player.fullscreen == no){         _player.fullscreen = yes;     }      //prevent user scrubbing through movie  //    #ifdef debug //     //       return; //    #else      if(_player.playbackstate == mpmovieplaybackstateseekingforward){           nsstring *alertmessage = [nsstring stringwithformat:@"you not allowed skip movies"          uialertview *alert =         [[uialertview alloc] initwithtitle: @"warning"                                    message: alertmessage                                   delegate: self                          cancelbuttontitle: @"continue"                          otherbuttontitles: @"stop", nil];         self.isshowing = yes;         [alert show];          [_player pause];         _player.fullscreen = no;     }    // #endif 
did try put [_player endseeking] in the
if(_player.playbackstate == mpmovieplaybackstateseekingforward){ statement?
Comments
Post a Comment