Merge "docs: Fixes for Android TV Dev Guide" into klp-modular-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
4c4f8b32a0
@@ -153,8 +153,7 @@ page.tags="leanback","recyclerview","launcher"
|
||||
</p>
|
||||
|
||||
<p>If you decide to use the v17 leanback library for your app, you should note that it is
|
||||
dependent on the <a href="{@docRoot}tools/support-library/features.html#v7-appcompat">v7
|
||||
appcompat library</a>, which is, in turn, dependent on the
|
||||
dependent on the
|
||||
<a href="{@docRoot}tools/support-library/features.html#v4">v4 support library</a>. This means
|
||||
that apps that use the leanback support library should include all of these support
|
||||
libraries:</p>
|
||||
@@ -162,12 +161,11 @@ page.tags="leanback","recyclerview","launcher"
|
||||
<ul>
|
||||
<li>v17 leanback support library</li>
|
||||
<li>v7 recyclerview support library</li>
|
||||
<li>v7 appcompat support library</li>
|
||||
<li>v4 support library</li>
|
||||
</ul>
|
||||
|
||||
<p>Two of these libraries (v17 leanback and v7 appcompat) contain resources, which require
|
||||
you to take specific steps to include them in app projects. For instructions on
|
||||
<p>The v17 leanback library contain resources, which requires
|
||||
you to take specific steps to include it in app projects. For instructions on
|
||||
importing a support library with resources, see
|
||||
<a href="http://developer.android.com/tools/support-library/setup.html#libs-with-res">
|
||||
Support Library Setup</a>.
|
||||
|
||||
@@ -152,10 +152,9 @@ private void buildRowsAdapter() {
|
||||
image as users browse through content. This technique can make interaction with your app feel more
|
||||
cinematic and enjoyable for users.</p>
|
||||
|
||||
<p>The Leanback support library provides a {@link
|
||||
android.support.v17.leanback.app.BackgroundManager} class for changing the background of your TV
|
||||
app activity. The following example shows how to create a simple method for updating the
|
||||
background within your TV app activity:</p>
|
||||
<p>The Leanback support library provides a {@code BackgroundManager} class for changing the
|
||||
background of your TV app activity. The following example shows how to create a simple method
|
||||
for updating the background within your TV app activity:</p>
|
||||
|
||||
<pre>
|
||||
protected void updateBackground(Drawable drawable) {
|
||||
@@ -166,7 +165,7 @@ protected void updateBackground(Drawable drawable) {
|
||||
<p>Many of the existing media-browse apps automatically update the background as the user
|
||||
navigates through media listings. In order to do this, you can set up a selection listener to
|
||||
automatically update the background based on the user's current selection. The following example
|
||||
shows you how to set up an {@link android.support.v17.leanback.widget.OnItemSelectedListener}
|
||||
shows you how to set up an {@code OnItemSelectedListener}
|
||||
class to catch selection events and update the background:</p>
|
||||
|
||||
<pre>
|
||||
|
||||
Reference in New Issue
Block a user