resume_time_.time = time_millisecond;
return true;
}
+ is_seek_done_need_drop = true;
LOG_DEBUG("[%p] > [ENTER] seek time [%" PRIu64 " ms]", this, time_millisecond);
for (const auto& track : track_) {
std::lock_guard<std::mutex> lock2(eos_mutex_);
return true;
};
es_event::Seek event{op};
- return state_manager_.ProcessEvent(event);
+
+ bool ret = state_manager_.ProcessEvent(event);
+ is_seek_done_need_drop = false;
+ LOG_DEBUG("%p, [LEAVE] seek end ", this);
+
+ return ret;
}
bool EsPlayer::SetPlaybackRate(const double rate, const bool audio_mute) {
return true;
};
es_event::PlaybackRate event{op};
- return state_manager_.ProcessEvent(event);
+ bool ret = state_manager_.ProcessEvent(event);
LOG_LEAVE_P(this);
- return true;
+ return ret;
}
bool EsPlayer::SetDisplay(const DisplayType& type, void* obj) {
void EsPlayer::TrackRendererEventListener::OnSeekDone() {
LOG_ENTER_P(handler_);
if (!handler_->eventlistener_) return;
+ if (handler_->is_seek_done_need_drop == true) return;
auto listener = std::bind(&plusplayer::EsEventListener::OnSeekDone,
handler_->eventlistener_, std::placeholders::_1);
auto msg = es_msg::Simple::Make(listener, handler_->eventlistener_userdata_);