mirror of
https://github.com/samsonjs/media.git
synced 2026-04-13 12:35:48 +00:00
Deprecate AnalyticsListener.onSeekStarted.
The new onPositionDiscontinuity callback contains sufficient information, so that this former workaround to obtain the position before a seek is no longer needed. PiperOrigin-RevId: 365993937
This commit is contained in:
parent
7aeb476812
commit
dc0ee7580e
2 changed files with 5 additions and 3 deletions
|
|
@ -170,6 +170,7 @@ public class AnalyticsCollector
|
|||
* Notify analytics collector that a seek operation will start. Should be called before the player
|
||||
* adjusts its state and position to the seek.
|
||||
*/
|
||||
@SuppressWarnings("deprecation") // Calling deprecated listener method.
|
||||
public final void notifySeekStarted() {
|
||||
if (!isSeeking) {
|
||||
EventTime eventTime = generateCurrentPlayerMediaPeriodEventTime();
|
||||
|
|
|
|||
|
|
@ -553,10 +553,11 @@ public interface AnalyticsListener {
|
|||
@DiscontinuityReason int reason) {}
|
||||
|
||||
/**
|
||||
* Called when a seek operation started.
|
||||
*
|
||||
* @param eventTime The event time.
|
||||
* @deprecated Use {@link #onPositionDiscontinuity(EventTime, Player.PositionInfo,
|
||||
* Player.PositionInfo, int)} instead, listening to changes with {@link
|
||||
* Player#DISCONTINUITY_REASON_SEEK}.
|
||||
*/
|
||||
@Deprecated
|
||||
default void onSeekStarted(EventTime eventTime) {}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Reference in a new issue