From 9bef35b5986b8e45b9dd1e395acc2322a85dfad2 Mon Sep 17 00:00:00 2001 From: Daniel Yu Date: Mon, 2 May 2016 10:40:57 -0700 Subject: [PATCH] docs: Updating TV recording API docs for N DP3 Updating TV recording docs: change for TvInputManager.updateTvInputInfo(), adding info on new android:canRecord attribute. Bug: 28451239 Change-Id: I11bdb41245c5aedec566211b853293ed079c140c --- .../html/preview/features/tv-recording-api.jd | 20 +++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-) diff --git a/docs/html/preview/features/tv-recording-api.jd b/docs/html/preview/features/tv-recording-api.jd index b62dd46fca83b..65ab340d199fa 100644 --- a/docs/html/preview/features/tv-recording-api.jd +++ b/docs/html/preview/features/tv-recording-api.jd @@ -37,7 +37,23 @@ experience for your TV input service.

Indicating Support for Recording

-

To tell the system that your TV input service supports recording, follow +

To tell the system that your TV input service supports recording, set +the android:canRecord attribute in your service metadata XML file +to true: +

+ +
+<tv-input xmlns:android="http://schemas.android.com/apk/res/android"
+  android:canRecord="true"
+  android:setupActivity="com.example.sampletvinput.SampleTvInputSetupActivity" />
+
+ +

For more information on the service metadata file, see +Declare Your TV Input +Service in the Manifest. +

+ +

Alternatively, you can indicate recording support in your code using these steps:

    @@ -48,7 +64,7 @@ class. setCanRecord(true) before calling build() to indicate your service supports recording.
  1. Register your TvInputInfo object with the system by calling -TvInputService.updateTvInputInfo().
  2. +TvInputManager.updateTvInputInfo().

Recording a Session