Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d48d029d authored by Jiabin's avatar Jiabin
Browse files

TIF: Unhide TvRecordingClient.tune(String, Uri, Bundle)

Bug: 27762945
Change-Id: I7f9757f8ca1eb92f892fb2961717125c8b909663
parent ef5577a1
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -23083,6 +23083,7 @@ package android.media.tv {
    method public abstract void onStartRecording(android.net.Uri);
    method public abstract void onStopRecording();
    method public abstract void onTune(android.net.Uri);
    method public void onTune(android.net.Uri, android.os.Bundle);
  }
  public static abstract class TvInputService.Session implements android.view.KeyEvent.Callback {
@@ -23132,6 +23133,7 @@ package android.media.tv {
    method public void startRecording(android.net.Uri);
    method public void stopRecording();
    method public void tune(java.lang.String, android.net.Uri);
    method public void tune(java.lang.String, android.net.Uri, android.os.Bundle);
  }
  public static abstract class TvRecordingClient.RecordingCallback {
+2 −0
Original line number Diff line number Diff line
@@ -23148,6 +23148,7 @@ package android.media.tv {
    method public abstract void onStartRecording(android.net.Uri);
    method public abstract void onStopRecording();
    method public abstract void onTune(android.net.Uri);
    method public void onTune(android.net.Uri, android.os.Bundle);
  }
  public static abstract class TvInputService.Session implements android.view.KeyEvent.Callback {
@@ -23197,6 +23198,7 @@ package android.media.tv {
    method public void startRecording(android.net.Uri);
    method public void stopRecording();
    method public void tune(java.lang.String, android.net.Uri);
    method public void tune(java.lang.String, android.net.Uri, android.os.Bundle);
  }
  public static abstract class TvRecordingClient.RecordingCallback {
+6 −5
Original line number Diff line number Diff line
@@ -1688,19 +1688,20 @@ public abstract class TvInputService extends Service {
        public abstract void onTune(Uri channelUri);

        /**
         * Called when the application requests to tune to a given channel for TV program recording.
         * Calls {@link #onTune(Uri)}. Override this method in order to handle domain-specific
         * features that are only known between certain TV inputs and their clients.
         *
         * <p>The application may call this method before starting or after stopping recording, but
         * not during recording.
         *
         * <p>The session must call {@link #notifyTuned()} if the tune request was fulfilled, or
         * <p>The session must call {@link #notifyTuned(Uri)} if the tune request was fulfilled, or
         * {@link #notifyError(int)} otherwise.
         *
         * @param channelUri The URI of a channel.
         * @param params Extra parameters.
         * @hide
         * @param params Domain-specific data for this tune request. Keys <em>must</em> be a scoped
         *            name, i.e. prefixed with a package name you own, so that different developers
         *            will not create conflicting keys.
         */
        @SystemApi
        public void onTune(Uri channelUri, Bundle params) {
            onTune(channelUri);
        }
+6 −5
Original line number Diff line number Diff line
@@ -91,22 +91,23 @@ public class TvRecordingClient {
     * Tunes to a given channel for TV program recording. The first tune request will create a new
     * recording session for the corresponding TV input and establish a connection between the
     * application and the session. If recording has already started in the current recording
     * session, this method throws an exception.
     * session, this method throws an exception. This can be used to provide domain-specific
     * features that are only known between certain client and their TV inputs.
     *
     * <p>The application may call this method before starting or after stopping recording, but not
     * during recording.
     *
     * <p>The recording session will respond by calling
     * {@link RecordingCallback#onTuned()} if the tune request was fulfilled, or
     * {@link RecordingCallback#onTuned(Uri)} if the tune request was fulfilled, or
     * {@link RecordingCallback#onError(int)} otherwise.
     *
     * @param inputId The ID of the TV input for the given channel.
     * @param channelUri The URI of a channel.
     * @param params Extra parameters.
     * @param params Domain-specific data for this tune request. Keys <em>must</em> be a scoped
     *            name, i.e. prefixed with a package name you own, so that different developers will
     *            not create conflicting keys.
     * @throws IllegalStateException If recording is already started.
     * @hide
     */
    @SystemApi
    public void tune(String inputId, Uri channelUri, Bundle params) {
        if (DEBUG) Log.d(TAG, "tune(" + channelUri + ")");
        if (TextUtils.isEmpty(inputId)) {