Remove deprecated Player.DefaultEventListener
PiperOrigin-RevId: 356479682
This commit is contained in:
parent
30ad70bbd7
commit
50db2ee172
@ -14,10 +14,12 @@
|
|||||||
an ad media period before the ad URI was known then an ad state update
|
an ad media period before the ad URI was known then an ad state update
|
||||||
arrived that didn't set the ad URI.
|
arrived that didn't set the ad URI.
|
||||||
* Remove deprecated symbols:
|
* Remove deprecated symbols:
|
||||||
* Remove `extension-jobdispatcher` module. Use the `extension-workmanager`
|
* Remove `Player.DefaultEventListener`. Use `Player.EventListener`
|
||||||
module instead.
|
instead.
|
||||||
* Remove `DownloadNotificationUtil`. Use `DownloadNotificationHelper`
|
* Remove `DownloadNotificationUtil`. Use `DownloadNotificationHelper`
|
||||||
instead.
|
instead.
|
||||||
|
* Remove `extension-jobdispatcher` module. Use the `extension-workmanager`
|
||||||
|
module instead.
|
||||||
|
|
||||||
### 2.13.0 (2021-02-04)
|
### 2.13.0 (2021-02-04)
|
||||||
|
|
||||||
|
@ -665,32 +665,6 @@ public interface Player {
|
|||||||
default void onEvents(Player player, Events events) {}
|
default void onEvents(Player player, Events events) {}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* @deprecated Use {@link EventListener} interface directly for selective overrides as all methods
|
|
||||||
* are implemented as no-op default methods.
|
|
||||||
*/
|
|
||||||
@Deprecated
|
|
||||||
abstract class DefaultEventListener implements EventListener {
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void onTimelineChanged(Timeline timeline, @TimelineChangeReason int reason) {
|
|
||||||
Object manifest = null;
|
|
||||||
if (timeline.getWindowCount() == 1) {
|
|
||||||
// Legacy behavior was to report the manifest for single window timelines only.
|
|
||||||
Timeline.Window window = new Timeline.Window();
|
|
||||||
manifest = timeline.getWindow(0, window).manifest;
|
|
||||||
}
|
|
||||||
// Call deprecated version.
|
|
||||||
onTimelineChanged(timeline, manifest, reason);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void onTimelineChanged(
|
|
||||||
Timeline timeline, @Nullable Object manifest, @TimelineChangeReason int reason) {
|
|
||||||
// Do nothing.
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/** A set of {@link EventFlags}. */
|
/** A set of {@link EventFlags}. */
|
||||||
final class Events extends MutableFlags {
|
final class Events extends MutableFlags {
|
||||||
/**
|
/**
|
||||||
|
Loading…
x
Reference in New Issue
Block a user