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

Commit b0df0859 authored by Dongwon Kang's avatar Dongwon Kang Committed by Android (Google) Code Review
Browse files

Merge "TIF: Address API review comments" into nyc-dev

parents bfce110c ee564881
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -23025,6 +23025,7 @@ package android.media.tv {
    method public boolean isRatingBlocked(android.media.tv.TvContentRating);
    method public void registerCallback(android.media.tv.TvInputManager.TvInputCallback, android.os.Handler);
    method public void unregisterCallback(android.media.tv.TvInputManager.TvInputCallback);
    method public void updateTvInputInfo(android.media.tv.TvInputInfo);
    field public static final java.lang.String ACTION_BLOCKED_RATINGS_CHANGED = "android.media.tv.action.BLOCKED_RATINGS_CHANGED";
    field public static final java.lang.String ACTION_PARENTAL_CONTROLS_ENABLED_CHANGED = "android.media.tv.action.PARENTAL_CONTROLS_ENABLED_CHANGED";
    field public static final java.lang.String ACTION_QUERY_CONTENT_RATING_SYSTEMS = "android.media.tv.action.QUERY_CONTENT_RATING_SYSTEMS";
@@ -23062,7 +23063,6 @@ package android.media.tv {
    method public final android.os.IBinder onBind(android.content.Intent);
    method public android.media.tv.TvInputService.RecordingSession onCreateRecordingSession(java.lang.String);
    method public abstract android.media.tv.TvInputService.Session onCreateSession(java.lang.String);
    method public static final void updateTvInputInfo(android.content.Context, android.media.tv.TvInputInfo);
    field public static final java.lang.String SERVICE_INTERFACE = "android.media.tv.TvInputService";
    field public static final java.lang.String SERVICE_META_DATA = "android.media.tv.input";
  }
+1 −1
Original line number Diff line number Diff line
@@ -24711,6 +24711,7 @@ package android.media.tv {
    method public void removeBlockedRating(android.media.tv.TvContentRating);
    method public void setParentalControlsEnabled(boolean);
    method public void unregisterCallback(android.media.tv.TvInputManager.TvInputCallback);
    method public void updateTvInputInfo(android.media.tv.TvInputInfo);
    field public static final java.lang.String ACTION_BLOCKED_RATINGS_CHANGED = "android.media.tv.action.BLOCKED_RATINGS_CHANGED";
    field public static final java.lang.String ACTION_PARENTAL_CONTROLS_ENABLED_CHANGED = "android.media.tv.action.PARENTAL_CONTROLS_ENABLED_CHANGED";
    field public static final java.lang.String ACTION_QUERY_CONTENT_RATING_SYSTEMS = "android.media.tv.action.QUERY_CONTENT_RATING_SYSTEMS";
@@ -24765,7 +24766,6 @@ package android.media.tv {
    method public java.lang.String onHardwareRemoved(android.media.tv.TvInputHardwareInfo);
    method public android.media.tv.TvInputInfo onHdmiDeviceAdded(android.hardware.hdmi.HdmiDeviceInfo);
    method public java.lang.String onHdmiDeviceRemoved(android.hardware.hdmi.HdmiDeviceInfo);
    method public static final void updateTvInputInfo(android.content.Context, android.media.tv.TvInputInfo);
    field public static final java.lang.String SERVICE_INTERFACE = "android.media.tv.TvInputService";
    field public static final java.lang.String SERVICE_META_DATA = "android.media.tv.input";
  }
+1 −1
Original line number Diff line number Diff line
@@ -23093,6 +23093,7 @@ package android.media.tv {
    method public boolean isRatingBlocked(android.media.tv.TvContentRating);
    method public void registerCallback(android.media.tv.TvInputManager.TvInputCallback, android.os.Handler);
    method public void unregisterCallback(android.media.tv.TvInputManager.TvInputCallback);
    method public void updateTvInputInfo(android.media.tv.TvInputInfo);
    field public static final java.lang.String ACTION_BLOCKED_RATINGS_CHANGED = "android.media.tv.action.BLOCKED_RATINGS_CHANGED";
    field public static final java.lang.String ACTION_PARENTAL_CONTROLS_ENABLED_CHANGED = "android.media.tv.action.PARENTAL_CONTROLS_ENABLED_CHANGED";
    field public static final java.lang.String ACTION_QUERY_CONTENT_RATING_SYSTEMS = "android.media.tv.action.QUERY_CONTENT_RATING_SYSTEMS";
@@ -23130,7 +23131,6 @@ package android.media.tv {
    method public final android.os.IBinder onBind(android.content.Intent);
    method public android.media.tv.TvInputService.RecordingSession onCreateRecordingSession(java.lang.String);
    method public abstract android.media.tv.TvInputService.Session onCreateSession(java.lang.String);
    method public static final void updateTvInputInfo(android.content.Context, android.media.tv.TvInputInfo);
    field public static final java.lang.String SERVICE_INTERFACE = "android.media.tv.TvInputService";
    field public static final java.lang.String SERVICE_META_DATA = "android.media.tv.input";
  }
+2 −2
Original line number Diff line number Diff line
@@ -8083,11 +8083,11 @@ i
        <attr name="settingsActivity" />
        <!-- Attribute whether the TV input service can record programs. This value can be changed
             at runtime by calling
             {@link android.media.tv.TvInputService#updateTvInputInfo(android.content.Context, android.media.tv.TvInputInfo)}. -->
             {@link android.media.tv.TvInputManager#updateTvInputInfo(android.media.tv.TvInputInfo)}. -->
        <attr name="canRecord" format="boolean" />
        <!-- The number of tuners that the TV input service is associated with. This value can be
             changed at runtime by calling
             {@link android.media.tv.TvInputService#updateTvInputInfo(android.content.Context, android.media.tv.TvInputInfo)}. -->
             {@link android.media.tv.TvInputManager#updateTvInputInfo(android.media.tv.TvInputInfo)}. -->
        <attr name="tunerCount" format="integer" />
    </declare-styleable>

+15 −4
Original line number Diff line number Diff line
@@ -191,7 +191,9 @@ public final class TvInputManager {
    /**
     * Error for {@link TvInputService.RecordingSession#notifyError(int)} and
     * {@link TvRecordingClient.RecordingCallback#onError(int)}: The requested operation cannot be
     * completed due to a problem that does not fit under any other error codes.
     * completed due to a problem that does not fit under any other error codes, or the error code
     * for the problem is defined on the higher version than application's
     * <code>android:targetSdkVersion</code>.
     */
    public static final int RECORDING_ERROR_UNKNOWN = 0;

@@ -1181,14 +1183,23 @@ public final class TvInputManager {
    }

    /**
     * Updates information about an existing TV input.
     * Updates the <code>TvInputInfo</code> for an existing TV input. A TV input service
     * implementation may call this method to pass the application and system an up-to-date
     * <code>TvInputInfo</code> object that describes itself.
     *
     * <p>This is called internally only by {@link TvInputService}.
     * <p>The system automatically creates a <code>TvInputInfo</code> object for each TV input,
     * based on the information collected from the <code>AndroidManifest.xml</code>, thus it is not
     * necessary to call this method unless such information has changed dynamically.
     * Use {@link TvInputInfo.Builder} to build a new <code>TvInputInfo</code> object.
     *
     * <p>Attempting to change information about a TV input that the calling package does not own
     * does nothing.
     *
     * @param inputInfo The <code>TvInputInfo</code> object that contains new information.
     * @throws IllegalArgumentException if the argument is {@code null}.
     * @see TvInputCallback#onTvInputInfoUpdated(TvInputInfo)
     */
    void updateTvInputInfo(@NonNull TvInputInfo inputInfo) {
    public void updateTvInputInfo(@NonNull TvInputInfo inputInfo) {
        Preconditions.checkNotNull(inputInfo);
        try {
            mService.updateTvInputInfo(inputInfo, mUserId);
Loading