am 6c9b0847: Merge "Update documentation for notifyTracksChanged() and notifyTrackSelected()" into lmp-mr1-dev

* commit '6c9b08478b9f3f69e6f9fa8a5d288ba780a58f3e':
  Update documentation for notifyTracksChanged() and notifyTrackSelected()
This commit is contained in:
Jae Seo
2014-10-23 07:55:53 +00:00
committed by Android Git Automerger

View File

@@ -332,8 +332,13 @@ public abstract class TvInputService extends Service {
} }
/** /**
* Sends the change on the track information. This is expected to be called whenever a track * Sends the list of all audio/video/subtitle tracks. The is used by the framework to
* is added/removed and the metadata of a track is modified. * maintain the track information for a given session, which in turn is used by
* {@link TvView#getTracks} for the application to retrieve metadata for a given track type.
* The TV input service must call this method as soon as the track information becomes
* available or is updated. Note that in a case where a part of the information for a
* certain track is updated, it is not necessary to create a new {@link TvTrackInfo} object
* with a different track ID.
* *
* @param tracks A list which includes track information. * @param tracks A list which includes track information.
* @throws IllegalArgumentException if {@code tracks} contains redundant tracks. * @throws IllegalArgumentException if {@code tracks} contains redundant tracks.
@@ -364,8 +369,12 @@ public abstract class TvInputService extends Service {
} }
/** /**
* Sends the ID of the selected track for a given track type. This is expected to be called * Sends the type and ID of a selected track. This is used to inform the application that a
* whenever there is a change on track selection. * specific track is selected. The TV input service must call this method as soon as a track
* is selected either by default or in response to a call to {@link #onSelectTrack}. The
* selected track ID for a given type is maintained in the framework until the next call to
* this method even after the entire track list is updated (but is reset when the session is
* tuned to a new channel), so care must be taken not to result in an obsolete track ID.
* *
* @param type The type of the selected track. The type can be * @param type The type of the selected track. The type can be
* {@link TvTrackInfo#TYPE_AUDIO}, {@link TvTrackInfo#TYPE_VIDEO} or * {@link TvTrackInfo#TYPE_AUDIO}, {@link TvTrackInfo#TYPE_VIDEO} or