Package com.castlabs.android.subtitles
Class ExoSubtitlesStyleObserver
java.lang.Object
com.castlabs.android.subtitles.ExoSubtitlesStyleObserver
- All Implemented Interfaces:
SubtitlesStyleObserver
Implementation of the
SubtitlesStyleObserver
that is used to pass the current
subtitle style to the underlying ExoPlayer track renderer view.
This is an internal class and you usually do not need to interact with the class manually.- Since:
- 3.1.0
-
Constructor Summary
ConstructorsConstructorDescriptionExoSubtitlesStyleObserver
(com.google.android.exoplayer2.ui.SubtitleView view) -
Method Summary
Modifier and TypeMethodDescriptionvoid
onStyleChange
(com.castlabs.subtitles.presentation.SubtitlesStyle style) Called when a new style needs to be applied.
-
Constructor Details
-
ExoSubtitlesStyleObserver
public ExoSubtitlesStyleObserver(@NonNull com.google.android.exoplayer2.ui.SubtitleView view)
-
-
Method Details
-
onStyleChange
public void onStyleChange(@Nullable com.castlabs.subtitles.presentation.SubtitlesStyle style) Description copied from interface:SubtitlesStyleObserver
Called when a new style needs to be applied. If null is passed here, the default style should be applied.- Specified by:
onStyleChange
in interfaceSubtitlesStyleObserver
- Parameters:
style
- The style or null to use the default style
-