* commit '1b2cf3f8f64013441fc021db45e00381d4b2d19b': docs: b/18119632 isGame, b/18119595 banner
This commit is contained in:
@@ -41,6 +41,8 @@ page.title=UI Patterns for TV
|
|||||||
language, you must provide versions of the banner image for each supported language.</li>
|
language, you must provide versions of the banner image for each supported language.</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
|
<p>See <a href="{@docRoot}training/tv/start/start.html#banner">Provide a home screen banner</a>
|
||||||
|
in Get Started with TV Apps for more information.</p>
|
||||||
|
|
||||||
<h3>Recommendation Icons</h3>
|
<h3>Recommendation Icons</h3>
|
||||||
|
|
||||||
|
|||||||
@@ -9,6 +9,7 @@ parent.link=manifest-intro.html
|
|||||||
android:<a href="#reparent">allowTaskReparenting</a>=["true" | "false"]
|
android:<a href="#reparent">allowTaskReparenting</a>=["true" | "false"]
|
||||||
android:<a href="#always">alwaysRetainTaskState</a>=["true" | "false"]
|
android:<a href="#always">alwaysRetainTaskState</a>=["true" | "false"]
|
||||||
android:<a href="#autoremrecents">autoRemoveFromRecents</a>=["true" | "false"]
|
android:<a href="#autoremrecents">autoRemoveFromRecents</a>=["true" | "false"]
|
||||||
|
android:<a href="#banner">banner</a>="<i>drawable resource</i>"
|
||||||
android:<a href="#clear">clearTaskOnLaunch</a>=["true" | "false"]
|
android:<a href="#clear">clearTaskOnLaunch</a>=["true" | "false"]
|
||||||
android:<a href="#config">configChanges</a>=["mcc", "mnc", "locale",
|
android:<a href="#config">configChanges</a>=["mcc", "mnc", "locale",
|
||||||
"touchscreen", "keyboard", "keyboardHidden",
|
"touchscreen", "keyboard", "keyboardHidden",
|
||||||
@@ -153,6 +154,29 @@ automatically removed from the overview screen. This overrides the caller's use
|
|||||||
"{@code true}" or "{@code false}".</dd>
|
"{@code true}" or "{@code false}".</dd>
|
||||||
|
|
||||||
|
|
||||||
|
<dt><a name="banner"></a>{@code android:banner}</dt>
|
||||||
|
<dd>A <a href="{@docRoot}guide/topics/resources/drawable-resource.html">drawable resource</a>
|
||||||
|
providing an extended graphical banner for its associated item. Use with the
|
||||||
|
{@code <activity>} tag to supply a default banner for a specific activity, or with the
|
||||||
|
<a href="{@docRoot}guide/topics/manifest/application-element.html"><code><application></code></a>
|
||||||
|
tag to supply a banner for all application activities.
|
||||||
|
|
||||||
|
<p>The system uses the banner to represent an app in
|
||||||
|
the Android TV home screen. Since the banner is displayed only in the home screen, it
|
||||||
|
should only be specified by applications with an activity that handles the
|
||||||
|
{@link android.content.Intent#CATEGORY_LEANBACK_LAUNCHER} intent.</p>
|
||||||
|
|
||||||
|
<p>This attribute must be set as a reference to a drawable resource containing
|
||||||
|
the image (for example {@code "@drawable/banner"}). There is no default banner.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
See <a href="{@docRoot}design/tv/patterns.html#banner">
|
||||||
|
Banners</a> in the UI Patterns for TV design guide, and <a href="{@docRoot}training/tv/start/start.html#banner">
|
||||||
|
Provide a home screen banner</a> in Get Started with TV Apps for more information.
|
||||||
|
</p></dd>
|
||||||
|
|
||||||
|
|
||||||
<dt><a name="clear"></a>{@code android:clearTaskOnLaunch}</dt>
|
<dt><a name="clear"></a>{@code android:clearTaskOnLaunch}</dt>
|
||||||
<dd>Whether or not all activities will be removed from the task, except for
|
<dd>Whether or not all activities will be removed from the task, except for
|
||||||
the root activity, whenever it is re-launched from the home screen —
|
the root activity, whenever it is re-launched from the home screen —
|
||||||
|
|||||||
@@ -7,12 +7,14 @@ page.title=<application>
|
|||||||
<dd><pre class="stx"><application android:<a href="#reparent">allowTaskReparenting</a>=["true" | "false"]
|
<dd><pre class="stx"><application android:<a href="#reparent">allowTaskReparenting</a>=["true" | "false"]
|
||||||
android:<a href="#allowbackup">allowBackup</a>=["true" | "false"]
|
android:<a href="#allowbackup">allowBackup</a>=["true" | "false"]
|
||||||
android:<a href="#agent">backupAgent</a>="<i>string</i>"
|
android:<a href="#agent">backupAgent</a>="<i>string</i>"
|
||||||
|
android:<a href="#banner">banner</a>="<i>drawable resource</i>"
|
||||||
android:<a href="#debug">debuggable</a>=["true" | "false"]
|
android:<a href="#debug">debuggable</a>=["true" | "false"]
|
||||||
android:<a href="#desc">description</a>="<i>string resource</i>"
|
android:<a href="#desc">description</a>="<i>string resource</i>"
|
||||||
android:<a href="#enabled">enabled</a>=["true" | "false"]
|
android:<a href="#enabled">enabled</a>=["true" | "false"]
|
||||||
android:<a href="#code">hasCode</a>=["true" | "false"]
|
android:<a href="#code">hasCode</a>=["true" | "false"]
|
||||||
android:<a href="#hwaccel">hardwareAccelerated</a>=["true" | "false"]
|
android:<a href="#hwaccel">hardwareAccelerated</a>=["true" | "false"]
|
||||||
android:<a href="#icon">icon</a>="<i>drawable resource</i>"
|
android:<a href="#icon">icon</a>="<i>drawable resource</i>"
|
||||||
|
android:<a href="#isGame">isGame</a>=["true" | "false"]
|
||||||
android:<a href="#killrst">killAfterRestore</a>=["true" | "false"]
|
android:<a href="#killrst">killAfterRestore</a>=["true" | "false"]
|
||||||
android:<a href="#largeHeap">largeHeap</a>=["true" | "false"]
|
android:<a href="#largeHeap">largeHeap</a>=["true" | "false"]
|
||||||
android:<a href="#label">label</a>="<i>string resource</i>"
|
android:<a href="#label">label</a>="<i>string resource</i>"
|
||||||
@@ -103,6 +105,28 @@ element.
|
|||||||
There is no default. The name must be specified.
|
There is no default. The name must be specified.
|
||||||
</p></dd>
|
</p></dd>
|
||||||
|
|
||||||
|
<dt><a name="banner"></a>{@code android:banner}</dt>
|
||||||
|
<dd>A <a href="{@docRoot}guide/topics/resources/drawable-resource.html">drawable resource</a>
|
||||||
|
providing an extended graphical banner for its associated item. Use with the
|
||||||
|
{@code <application>} tag to supply a default banner for all application activities, or with the
|
||||||
|
<a href="{@docRoot}guide/topics/manifest/activity-element.html"><code><activity></code></a>
|
||||||
|
tag to supply a banner for a specific activity.
|
||||||
|
|
||||||
|
<p>The system uses the banner to represent an app in
|
||||||
|
the Android TV home screen. Since the banner is displayed only in the home screen, it
|
||||||
|
should only be specified by applications with an activity that handles the
|
||||||
|
{@link android.content.Intent#CATEGORY_LEANBACK_LAUNCHER} intent.</p>
|
||||||
|
|
||||||
|
<p>This attribute must be set as a reference to a drawable resource containing
|
||||||
|
the image (for example {@code "@drawable/banner"}). There is no default banner.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
See <a href="{@docRoot}design/tv/patterns.html#banner">
|
||||||
|
Banners</a> in the UI Patterns for TV design guide, and <a href="{@docRoot}training/tv/start/start.html#banner">
|
||||||
|
Provide a home screen banner</a> in Get Started with TV Apps for more information.
|
||||||
|
</p></dd>
|
||||||
|
|
||||||
<dt><a name="debug"></a>{@code android:debuggable}</dt>
|
<dt><a name="debug"></a>{@code android:debuggable}</dt>
|
||||||
<dd>Whether or not the application can be debugged, even when running
|
<dd>Whether or not the application can be debugged, even when running
|
||||||
on a device in user mode — {@code "true"} if it can be, and {@code "false"}
|
on a device in user mode — {@code "true"} if it can be, and {@code "false"}
|
||||||
@@ -172,9 +196,15 @@ each of the application's components. See the individual
|
|||||||
|
|
||||||
<p>
|
<p>
|
||||||
This attribute must be set as a reference to a drawable resource containing
|
This attribute must be set as a reference to a drawable resource containing
|
||||||
the image (for example {@code "@drawable/icon"}). There is no default icon.
|
the image (for example {@code "@drawable/icon"}). There is no default icon.
|
||||||
</p></dd>
|
</p></dd>
|
||||||
|
|
||||||
|
<dt><a name="isGame"></a>{@code android:isGame}</dt>
|
||||||
|
<dd>Whether or not the application is a game. The system may group together applications classifed
|
||||||
|
as games or display them separately from other applications.
|
||||||
|
|
||||||
|
<p>The default is {@code false}.</p></dd>
|
||||||
|
|
||||||
<dt><a name="killrst"></a>{@code android:killAfterRestore}</dt>
|
<dt><a name="killrst"></a>{@code android:killAfterRestore}</dt>
|
||||||
<dd>Whether the application in question should be terminated after its
|
<dd>Whether the application in question should be terminated after its
|
||||||
settings have been restored during a full-system restore operation.
|
settings have been restored during a full-system restore operation.
|
||||||
@@ -221,7 +251,7 @@ it can also be set as a raw string.
|
|||||||
<dt><a name="logo"></a>{@code android:logo}</dt>
|
<dt><a name="logo"></a>{@code android:logo}</dt>
|
||||||
<dd>A logo for the application as whole, and the default logo for activities.
|
<dd>A logo for the application as whole, and the default logo for activities.
|
||||||
<p>This attribute must be set as a reference to a drawable resource containing
|
<p>This attribute must be set as a reference to a drawable resource containing
|
||||||
the image (for example {@code "@drawable/logo"}). There is no default logo.</p></dd>
|
the image (for example {@code "@drawable/logo"}). There is no default logo.</p></dd>
|
||||||
|
|
||||||
<dt><a name="space"></a>{@code android:manageSpaceActivity}</dt>
|
<dt><a name="space"></a>{@code android:manageSpaceActivity}</dt>
|
||||||
<dd>The fully qualified name of an Activity subclass that the system
|
<dd>The fully qualified name of an Activity subclass that the system
|
||||||
|
|||||||
@@ -194,22 +194,22 @@ It includes a white controller on black background and a black controller on whi
|
|||||||
|
|
||||||
<p>There are a some special things games should include in the Android manifest.</p>
|
<p>There are a some special things games should include in the Android manifest.</p>
|
||||||
|
|
||||||
<h3 id="Launcher">Show your game in the launcher</h3>
|
<h3 id="Launcher">Show your game on the home screen</h3>
|
||||||
<p>
|
<p>
|
||||||
The Android TV launcher home screen displays games in a separate row from regular apps.
|
The Android TV home screen displays games in a separate row from regular apps.
|
||||||
To make your game appear in the list of games, add the
|
To make your game appear in the list of games, set the
|
||||||
<a href="{@docRoot}guide/topics/manifest/meta-data-element.html"
|
<a href="{@docRoot}guide/topics/manifest/application-element.html#isGame">
|
||||||
><code><meta-data></code></a> tag in your app manifest with <code>android:name</code>
|
{@code android:isGame}</a> attribute to <code>"true"</code> in your app manifest's
|
||||||
set to <code>"isGame"</code> and <code>android:value</code>
|
<a href="{@docRoot}guide/topics/manifest/application-element.html"><code><application></code>
|
||||||
set to <code>"true"</code>. For example:
|
</a> tag. For example:
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<pre class="fragment">
|
<pre class="fragment">
|
||||||
<application>
|
<application
|
||||||
...
|
...
|
||||||
<meta-data android:name="isGame" android:value="true" >
|
android:isGame="true"
|
||||||
...
|
...
|
||||||
</application>
|
>
|
||||||
</pre>
|
</pre>
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -100,7 +100,8 @@ startpage=true
|
|||||||
<p>The following code snippet shows how to include this intent filter in your manifest:</p>
|
<p>The following code snippet shows how to include this intent filter in your manifest:</p>
|
||||||
|
|
||||||
<pre>
|
<pre>
|
||||||
<application>
|
<application
|
||||||
|
android:banner="@drawable/banner" >
|
||||||
...
|
...
|
||||||
<activity
|
<activity
|
||||||
android:name="com.example.android.MainActivity"
|
android:name="com.example.android.MainActivity"
|
||||||
@@ -141,6 +142,34 @@ startpage=true
|
|||||||
"{@docRoot}training/tv/start/layouts.html">Building TV Layouts</a>.
|
"{@docRoot}training/tv/start/layouts.html">Building TV Layouts</a>.
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
|
<h3 id="banner">Provide a home screen banner</h3>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
An application must provide a home screen banner if it includes a Leanback launcher intent
|
||||||
|
filter. The banner is the app launch point that appears on the home screen in the apps and
|
||||||
|
games rows. Desribe the banner in the manifest as follows:
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<pre>
|
||||||
|
<application
|
||||||
|
. . .
|
||||||
|
android:banner="@drawable/banner" >
|
||||||
|
. . .
|
||||||
|
</application>
|
||||||
|
</pre>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
Use the <a href="{@docRoot}guide/topics/manifest/application-element.html#banner">{@code android:banner}</a>
|
||||||
|
attribute with the <a href="{@docRoot}guide/topics/manifest/application.html"><code><application></code></a>
|
||||||
|
tag to supply a default banner for all application activities, or with the
|
||||||
|
<a href="{@docRoot}guide/topics/manifest/activity-element.html"><code><activity></code></a>
|
||||||
|
tag to supply a banner for a specific activity.
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
See <a href="{@docRoot}design/tv/patterns.html#banner">Banners</a> in the UI Patterns for TV
|
||||||
|
design guide.
|
||||||
|
</p>
|
||||||
|
|
||||||
<h3 id="tv-libraries">Add TV support libraries</h3>
|
<h3 id="tv-libraries">Add TV support libraries</h3>
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user