//当前app被唤醒
NSNotificationCenter.DefaultCenter.AddObserver (UIApplication.DidBecomeActiveNotification,(notity)=>{
if (moviePlayerCtrl != null) {
//btnPlay.ReloadInputViews();
//btnPlay.SetNeedsDisplay();
string _url = CurrentCourseTag < 0 ? CourseWebUrl: RelationCourse [CurrentCourseTag, 1];
ResetPlayerElement (_url);
}
});
//当前app进入后台
NSNotificationCenter.DefaultCenter.AddObserver (UIApplication.DidEnterBackgroundNotification,(notity)=>{
if (moviePlayerCtrl != null) {
moviePlayerCtrl.Pause ();
if (CCTimer != null) {
CCTimer.Invalidate ();
CCTimer.Dispose ();
CCTimer = null;
}
PlayerCenter.SetLocalPlaybackProEnd (CourseNumber, CT);
}
});