summaryrefslogtreecommitdiffstats
path: root/docs
diff options
context:
space:
mode:
Diffstat (limited to 'docs')
-rw-r--r--docs/html-ndk/ndk/guides/abis.jd2
-rw-r--r--docs/html-ndk/ndk/guides/android_mk.jd9
-rw-r--r--docs/html-ndk/ndk/guides/index.jd10
-rw-r--r--docs/html-ndk/ndk/guides/ndk-build.jd6
-rw-r--r--docs/html-ndk/ndk/guides/prebuilts.jd2
-rw-r--r--docs/html-ndk/ndk/guides/standalone_toolchain.jd2
-rw-r--r--docs/html/distribute/googleplay/work/about.jd2
-rw-r--r--docs/html/distribute/index.jd4
-rw-r--r--docs/html/distribute/users/app-invites.jd2
-rw-r--r--docs/html/distribute/users/house-ads.jd2
-rw-r--r--docs/html/distribute/users/index.jd6
-rw-r--r--docs/html/images/cards/card-app-invites_16-9_2x.pngbin0 -> 11769 bytes
-rw-r--r--docs/html/images/cards/card-app-linking_2x.pngbin0 -> 82867 bytes
-rw-r--r--docs/html/images/cards/card-auto-backup_2x.pngbin0 -> 86310 bytes
-rw-r--r--docs/html/images/cards/card-test-performance_2x.pngbin0 -> 99188 bytes
-rw-r--r--docs/html/images/permissions_check.pngbin63920 -> 31042 bytes
-rw-r--r--docs/html/jd_collections.js18
-rw-r--r--docs/html/preview/api-changes.jd338
-rw-r--r--docs/html/preview/api-overview.jd4
-rw-r--r--docs/html/preview/backup/index.jd2
-rw-r--r--docs/html/preview/behavior-changes.jd4
-rw-r--r--docs/html/preview/data-binding/guide.jd908
-rw-r--r--docs/html/preview/download.jd15
-rw-r--r--docs/html/preview/features/app-linking.jd4
-rw-r--r--docs/html/preview/index.jd33
-rw-r--r--docs/html/preview/overview.jd25
-rw-r--r--docs/html/preview/preview_toc.cs2
-rw-r--r--docs/html/preview/samples.jd1
-rw-r--r--docs/html/preview/setup-sdk.jd8
-rw-r--r--docs/html/preview/testing/guide.jd14
-rw-r--r--docs/html/preview/testing/performance.jd16
-rw-r--r--docs/html/tools/data-binding/guide.jd42
-rw-r--r--docs/html/tools/data-binding/index.jd18
-rw-r--r--docs/html/training/training_toc.cs18
-rw-r--r--docs/html/training/tv/index.jd3
35 files changed, 132 insertions, 1388 deletions
diff --git a/docs/html-ndk/ndk/guides/abis.jd b/docs/html-ndk/ndk/guides/abis.jd
index ee55898..f4819b2 100644
--- a/docs/html-ndk/ndk/guides/abis.jd
+++ b/docs/html-ndk/ndk/guides/abis.jd
@@ -373,7 +373,7 @@ further information
<h3 id="mips64">mips64</h3>
<p>This ABI is for MIPS64 R6. For more information, see
-<a href="http://www.imgtec.com/mips/architectures/mips64.asp">MIPS Architecture</a>.</p>
+<a href="http://www.imgtec.com/mips/architectures/mips64.asp">MIPS64 Architecture</a>.</p>
<h2 id="gc">Generating Code for a Specific ABI</h2>
<p>By default, the NDK generates machine code for the armeabi ABI. You can
diff --git a/docs/html-ndk/ndk/guides/android_mk.jd b/docs/html-ndk/ndk/guides/android_mk.jd
index 8d0a8b1..47fefc3 100644
--- a/docs/html-ndk/ndk/guides/android_mk.jd
+++ b/docs/html-ndk/ndk/guides/android_mk.jd
@@ -114,7 +114,7 @@ script determines what to build, and how to do it.</p>
<p>There are more complex examples in the samples directories, with commented
{@code Android.mk} files that you can look at. In addition,
-<a href="{@docRoot}ndk/guides/sample_na.html">Sample: native-activity</a> provides
+<a href="{@docRoot}ndk/samples/sample_na.html">Sample: native-activity</a> provides
a detailed explanation of that sample's {@code Android.mk} file. Finally, <a href="#var">
Variables and Macros</a> provides further information on the variables from this section.
@@ -217,7 +217,7 @@ The following example shows the syntax for using this variable:</p>
TARGET_PLATFORM := android-22
</pre>
-<h4>TARGET_ARCH_ABI</h4>
+<h4 id="taa">TARGET_ARCH_ABI</h4>
<p>This variable stores the name of the CPU and architecture to target when the build system
parses this {@code Android.mk} file. You can specify one or more of the following values, using
a space as a delimiter between multiple targets. Table 1 shows the ABI setting to use for each
@@ -872,7 +872,4 @@ $(call import-module,&lt;name&gt;)
<p>In this example, the build system looks for the module tagged {@code &lt;name&gt;} in the list of
directories referenced that your {@code NDK_MODULE_PATH} environment variable references, and
-includes its {@code Android.mk} file automatically for you.</p>
-
-<p>For more information, see <a href="import.html">Android Module Paths (Sharing Code)</a>.
-</p>
+includes its {@code Android.mk} file automatically for you.</p> \ No newline at end of file
diff --git a/docs/html-ndk/ndk/guides/index.jd b/docs/html-ndk/ndk/guides/index.jd
index febeaab..465ce13 100644
--- a/docs/html-ndk/ndk/guides/index.jd
+++ b/docs/html-ndk/ndk/guides/index.jd
@@ -17,9 +17,9 @@ development process. However, it can be useful in cases in which you need to:</p
<p>This guide gives you the information you need to get up and running with the NDK. It starts by
explaining the <a href="{@docRoot}ndk/guides/concepts.html">concepts</a> underpinning the NDK, and
-how to <a href="{@docRoot}ndk/guides/setup.html">set it up</a>. Next, it explains how to use
-the NDK to <a href="{@docRoot}ndk/guides/build.html">build</a> and
-<a href="{@docRoot}ndk/guides/debug.html">debug</a> your app. Then, it continues with information
+how to <a href="{@docRoot}ndk/guides/setup.html">set it up</a>. Next, it continues with information
about targeting <a href="{@docRoot}ndk/guides/arch.html">different hardware platforms</a> in your
-builds. Finally, it discusses how to use your own and other prebuilt
-<a href="{@docRoot}ndk/guides/libs.html">libraries</a>.</p>
+builds. Then, it explains how to use
+the NDK to <a href="{@docRoot}ndk/guides/build.html">build</a> and
+<a href="{@docRoot}ndk/guides/debug.html">debug</a> your app. Finally, it discusses how to use your
+own and other prebuilt <a href="{@docRoot}ndk/guides/libs.html">libraries</a>.</p>
diff --git a/docs/html-ndk/ndk/guides/ndk-build.jd b/docs/html-ndk/ndk/guides/ndk-build.jd
index 9e3edda..18ca2d8 100644
--- a/docs/html-ndk/ndk/guides/ndk-build.jd
+++ b/docs/html-ndk/ndk/guides/ndk-build.jd
@@ -46,10 +46,8 @@ $ &lt;ndk&gt;/ndk-build
<p>In this example, <code>&lt;project&gt;</code> points to your
project’s root directory, and <code>&lt;ndk&gt;</code> is the directory where
-you installed the NDK. As noted in <a
-href="{@docRoot}ndk/guides/setup.html#install">Setup</a>, you can add {@code $NDK} to your
-{@code PATH} to avoid having to type the whole filepath every time you use ndk-build.
-Alternatively, you can create an alias.</p>
+you installed the NDK.</p>
+
<p><a class="anchor" id="options"></a> </p>
<h3>Options</h3>
<p>All parameters to ndk-build are passed directly to the underlying GNU {@code make}
diff --git a/docs/html-ndk/ndk/guides/prebuilts.jd b/docs/html-ndk/ndk/guides/prebuilts.jd
index f13e70e..52eb437 100644
--- a/docs/html-ndk/ndk/guides/prebuilts.jd
+++ b/docs/html-ndk/ndk/guides/prebuilts.jd
@@ -39,7 +39,7 @@ use cases for this functionality:</p>
library appropriate to your target ABI. For more information on ensuring library support for
ABIs, see <a href="#sa">Selecting ABIs for Prebuilt Libraries.</a></p></li>
<li>Include {@code PREBUILT_SHARED_LIBRARY} or {@code PREBUILT_STATIC_LIBRARY}, depending on
- whether you are using a shared ({@code .so}) or static {@code .a}) library.</li>
+ whether you are using a shared ({@code .so}) or static ({@code .a}) library.</li>
</ol>
<p>Here is a trivial example that assumes the prebuilt library {@code libfoo.so} resides in
diff --git a/docs/html-ndk/ndk/guides/standalone_toolchain.jd b/docs/html-ndk/ndk/guides/standalone_toolchain.jd
index 895f0fc..3b6f7f1 100644
--- a/docs/html-ndk/ndk/guides/standalone_toolchain.jd
+++ b/docs/html-ndk/ndk/guides/standalone_toolchain.jd
@@ -485,7 +485,7 @@ NEON functions.</p>
<p>You don't have to use any specific compiler flag when targeting the MIPS ABI.</p>
-<p>To learn more about ABI support, see <a href="{@docRoot}ndk/guides/x86.html">x86</a>.</p>
+<p>To learn more about ABI support, see <a href="{@docRoot}ndk/guides/x86.html">x86 Support</a>.</p>
<h2 id="war">Warnings and Limitations</h2>
<h3>Windows support</h3>
diff --git a/docs/html/distribute/googleplay/work/about.jd b/docs/html/distribute/googleplay/work/about.jd
index bd0f72b..20fec7a 100644
--- a/docs/html/distribute/googleplay/work/about.jd
+++ b/docs/html/distribute/googleplay/work/about.jd
@@ -55,7 +55,7 @@ page.image=images/distribute/gpfw.jpg
<li>Follow best practices for security and manage user data properly. Businesses
are more conscious of data security and employee productivity, especially when it
comes to features that share information with other services.</li>
- <li>Support the <a href="{@docRoot}training/enterprise/app-restrictions.html">App Configuration framework to let an administrator remotely configure app settings such as:
+ <li>Support the <a href="{@docRoot}training/enterprise/app-restrictions.html">App Configuration framework</a> to let an administrator remotely configure app settings such as:
<ul>
<li>Server address and protocol settings</li>
<li>The ability to switch features on and off</li>
diff --git a/docs/html/distribute/index.jd b/docs/html/distribute/index.jd
index c8928df..a6ece63 100644
--- a/docs/html/distribute/index.jd
+++ b/docs/html/distribute/index.jd
@@ -43,11 +43,11 @@ page.metaDescription=The most visited store in the world for Android apps. Cloud
<span class="dac-sprite dac-auto-chevron"></span>
Get started
</a></li>
- <li class="dac-section-link"><a href="/distribute/essentials/index.html#quality-guidelines">
+ <li class="dac-section-link"><a href="/distribute/essentials/index.html#guidelines">
<span class="dac-sprite dac-auto-chevron"></span>
Quality guidelines
</a></li>
- <li class="dac-section-link"><a href="/distribute/essentials/index.html#tools-and-resources">
+ <li class="dac-section-link"><a href="/distribute/essentials/index.html#tools">
<span class="dac-sprite dac-auto-chevron"></span>
Resources &amp; tools
</a></li>
diff --git a/docs/html/distribute/users/app-invites.jd b/docs/html/distribute/users/app-invites.jd
index ec9579d..e19e6eb 100644
--- a/docs/html/distribute/users/app-invites.jd
+++ b/docs/html/distribute/users/app-invites.jd
@@ -1,7 +1,7 @@
page.title=Smarter App Invites
page.metaDescription=Tap into your existing user base to increase downloads and increase conversions.
page.tags="google", "identity", "signin"
-page.image=distribute/images/advertising.jpg
+page.image=images/cards/card-app-invites_16-9_2x.png
@jd:body
diff --git a/docs/html/distribute/users/house-ads.jd b/docs/html/distribute/users/house-ads.jd
index d662fb2..ec73393 100644
--- a/docs/html/distribute/users/house-ads.jd
+++ b/docs/html/distribute/users/house-ads.jd
@@ -1,4 +1,4 @@
-page.title=Cross-Sell to Users with House Ads
+page.title=Cross-Sell with House Ads
page.metaDescription=Tap into your existing user base to increase downloads and increase conversions.
page.tags="google", "identity", "signin"
page.image=distribute/images/advertising.jpg
diff --git a/docs/html/distribute/users/index.jd b/docs/html/distribute/users/index.jd
index 4da4077..23f08c4 100644
--- a/docs/html/distribute/users/index.jd
+++ b/docs/html/distribute/users/index.jd
@@ -13,13 +13,13 @@ nonavpage=true
<div class="resource-widget resource-flow-layout landing col-16"
data-query="collection:distribute/users"
data-cardSizes="6x6"
- data-maxResults="9">
+ data-maxResults="15">
</div>
-<div class="resource-widget resource-flow-layout landing col-16"
+<!--<div class="resource-widget resource-flow-layout landing col-16"
data-query="collection:distribute/users"
data-cardSizes="9x3"
data-maxResults="16">
-</div>
+</div>-->
<!-- <h2>Related resources</h2>
diff --git a/docs/html/images/cards/card-app-invites_16-9_2x.png b/docs/html/images/cards/card-app-invites_16-9_2x.png
new file mode 100644
index 0000000..e0da07e
--- /dev/null
+++ b/docs/html/images/cards/card-app-invites_16-9_2x.png
Binary files differ
diff --git a/docs/html/images/cards/card-app-linking_2x.png b/docs/html/images/cards/card-app-linking_2x.png
new file mode 100644
index 0000000..abff805
--- /dev/null
+++ b/docs/html/images/cards/card-app-linking_2x.png
Binary files differ
diff --git a/docs/html/images/cards/card-auto-backup_2x.png b/docs/html/images/cards/card-auto-backup_2x.png
new file mode 100644
index 0000000..3c79ba9
--- /dev/null
+++ b/docs/html/images/cards/card-auto-backup_2x.png
Binary files differ
diff --git a/docs/html/images/cards/card-test-performance_2x.png b/docs/html/images/cards/card-test-performance_2x.png
new file mode 100644
index 0000000..fd949c8
--- /dev/null
+++ b/docs/html/images/cards/card-test-performance_2x.png
Binary files differ
diff --git a/docs/html/images/permissions_check.png b/docs/html/images/permissions_check.png
index bbbba4f..376d0fa 100644
--- a/docs/html/images/permissions_check.png
+++ b/docs/html/images/permissions_check.png
Binary files differ
diff --git a/docs/html/jd_collections.js b/docs/html/jd_collections.js
index d39bb0f..073feb8 100644
--- a/docs/html/jd_collections.js
+++ b/docs/html/jd_collections.js
@@ -125,7 +125,7 @@ var RESOURCE_COLLECTIONS = {
"https://developers.google.com/maps/documentation/android/",
"https://developers.google.com/identity/sign-in/android/",
"https://developers.google.com/mobile-ads-sdk/download",
- "https://devsite.googleplex.com/cloud-messaging/gcm",
+ "https://developers.google.com/cloud-messaging/gcm",
"https://developers.google.com/app-indexing/"
]
},
@@ -160,12 +160,15 @@ var RESOURCE_COLLECTIONS = {
"https://www.udacity.com/course/gradle-for-android-and-java--ud867"
]
},
- "preview/landing/herolinks": {
+ "preview/landing/more": {
"title": "",
"resources": [
- "https://www.udacity.com/course/ux-design-for-mobile-developers--ud849",
- "https://www.udacity.com/course/developing-android-apps--ud853",
- "https://www.udacity.com/course/android-performance--ud825"
+ "preview/features/runtime-permissions.html",
+ "preview/behavior-changes.html",
+ "preview/backup/index.html",
+ "preview/features/app-linking.html",
+ "preview/testing/guide.html",
+ "preview/testing/performance.html",
]
},
"distribute/landing/carousel": {
@@ -974,9 +977,8 @@ var RESOURCE_COLLECTIONS = {
"distribute/engage/gcm": {
"title": "",
"resources": [
- "https://devsite.googleplex.com/cloud-messaging/gcm",
- "http://developer.chrome.com/apps/cloudMessagingV2",
- "http://www.youtube.com/watch?v=y76rjidm8cU"
+ "https://developers.google.com/cloud-messaging/gcm",
+ "https://developers.google.com/cloud-messaging/android/client",
]
},
"distribute/engage/googleplaygames": {
diff --git a/docs/html/preview/api-changes.jd b/docs/html/preview/api-changes.jd
deleted file mode 100644
index 8ea91dd..0000000
--- a/docs/html/preview/api-changes.jd
+++ /dev/null
@@ -1,338 +0,0 @@
-page.title=Behavior Changes
-page.keywords=preview,sdk,compatibility
-page.tags=previewresources, androidm
-@jd:body
-
-<div id="qv-wrapper">
-<div id="qv">
-
-<h2>In this document</h2>
-
-<ol id="toc44" class="hide-nested">
- <li><a href="#behavior-runtime-permissions">Runtime Permissions</a></li>
- <li><a href="#behavior-notifications">Notifications</a></li>
- <li><a href="#behavior-openssl">OpenSSL</a></li>
- <li><a href="#behavior-project-volta">Project Volta</a>
- <ol>
- <li><a href="#behavior-doze">Doze Mode</a></li>
- <li><a href="#behavior-app-standby">App Standby Mode</a></li>
- </ol>
- </li>
- <li><a href="#behavior-adoptable-storage">Adoptable Storage Devices</a></li>
- <li><a href="#behavior-apache-http-client">Apache HTTP Client Removal</a></li>
- <li><a href="#behavior-audiomanager-Changes">AudioManager Changes</a></li>
- <li><a href="#behavior-test-selection">Text Selection</a></li>
- <li><a href="#behavior-keystore">Android Keystore Changes</a></li>
- <li><a href="#behavior-themeable-colorstatelists">Themeable ColorStateLists</a></li>
- <li><a href="#night-mode">Night Mode</a></li>
- <li><a href="#behavior-art-runtime">ART Runtime</a></li>
- <li><a href="#behavior-afw">Android for Work Changes</a></li>
-</ol>
-
-<h2>API Differences</h2>
-<ol>
-<li><a href="">API level 22 to M &raquo;</a> </li>
-</ol>
-
-
-<h2>See Also</h2>
-<ol>
-<li><a href="{@docRoot}preview/api-overview.html">M Developer Preview API Overview</a> </li>
-</ol>
-
-</div>
-</div>
-
-<p>API Level: M</p>
-<p>Along with new features and capabilities, M includes a variety of
-system changes and API behavior changes. This document highlights
-some of the key changes that you should be understand and account for in your apps.</p>
-
-<p>If you have previously published an app for Android, be aware that your app
- might be affected by these changes in M.</p>
-
-<h2 id="behavior-runtime-permissions">Runtime Permissions</h1>
-<p>This release introduces a new runtime permissions model, where users can now directly manage
-their app permissions at runtime. This model gives users improved visibility and control over
-permissions, while streamlining the installation and auto-update processes for app developers.
-Users can set permissions on or off for all apps running on Android M. However, apps that don’t
-target M cannot request permissions at runtime.</p>
-
-<p>On your apps that target M, make sure to check and request for permissions at
-runtime. To determine if your app has been granted a permission, call the
-new {@code Context.checkSelfPermission()} method. To request for a permission, call the new
-{@code Activity.requestPermission()} method.</p>
-
-<p>For more information on supporting the new permissions model in your app, see the
-<a href="{@docRoot}preview/features/runtime-permissions.html">
-Android M Runtime Permissions guide</a>.</p>
-
-<h2 id="behavior-openssl">OpenSSL</h2>
-<p>Android is moving away from OpenSSL to the
-<a href="https://boringssl.googlesource.com/boringssl/" class="external-link">BoringSSL</a>
-library. If you’re using the Android NDK in your app, don't link against cryptographic libraries
-that are not a part of the NDK API, such as {@code libcrypto.so} and {@code libssl.so}. These
-libraries are not public APIs, and may change or break without notice across releases and devices.
-In addition, you may expose yourself to security vulnerabilities. Instead, modify your
-native code to call the Java cryptography APIs via JNI or to statically link against a
-cryptography library of your choice.</p>
-
-<h2 id="behavior-project-volta">Project Volta</h2>
-<p>This release introduces new power-saving optimizations for idle devices and apps.</p>
-
-<h3 id="behavior-doze">Doze mode</h3>
-<p>If a device is unplugged and not used for up to an hour, it goes into <em>doze</em> mode where
-it attempts to keep the system in a sleep state. In this mode, devices may briefly resume normal
-operations for up to 5 minutes every few hours so that app syncing can occur and the system can
-perform any pending operations.</p>
-
-<p>The following restrictions apply to your apps while in device doze mode:</p>
-<ul>
-<li>Network access is disabled</li>
-<li>Alarms scheduled with the {@link android.app.AlarmManager} class are disabled, except for
-alarms that you've set with the
-{@link android.app.AlarmManager#setAlarmClock(android.app.AlarmManager.AlarmClockInfo,android.app.PendingIntent) setAlarmClock()}
-method</li>
-<li>WiFi scans are not performed</li>
-<li>Syncs and jobs for your sync adapters and {@link android.app.job.JobScheduler} are not
-permitted to run</li>
-</ul>
-</p>
-<p>When the system comes out of doze mode, it executes jobs and syncs that are pending.</p>
-
-<h3 id="behavior-app-standby">App standby mode</h3>
-<p>In M, the system may determine that apps are idle when they are not in active use by the user.
-Your app goes into <em>app standby</em> mode after two days unless the system detects any of these
-signals:</p>
-
-<ul>
-<li>The app has a process currently in the foreground (either as an activity or foreground service,
-or in use by another activity or foreground service)</li>
-<li>The app generates a notification that the user can see</li>
-<li>The user explicitly asks for the app to remain running</li>
-</ul>
-
-<p>If the system is running on battery power, apps that are in standby mode will have their
-network access disabled and their syncs and jobs suspended. When the system is plugged into a power
-supply, it brings an app out of standby mode and executes any jobs and syncs that are pending.</p>
-
-<p>Apps that use <a href="{@docRoot}google/gcm/index.html">Google Cloud Messaging</a> will
-continue to receive messages even if they are idle. When the system is plugged into a power
-supply, apps resume normal operations and can run any pending syncs and jobs.</p>
-
-<p>You can test this feature by connecting a device running M to your development machine and
-calling the following commands:
-</p>
-<pre>
-$ adb shell am broadcast -a android.os.action.DISCHARGING
-$ adb shell am set-idle &lt;packageName&gt; true
-$ adb shell am set-idle &lt;packageName&gt; false
-$ adb shell am get-idle &lt;packageName&gt;
-</pre>
-
-<h2 id="behavior-adoptable-storage">Adoptable Storage Devices</h2>
-<p>
-In M, users can adopt external storage devices such as SD cards. Adopting an external storage
-device encrypts and formats the device to behave like internal storage. This feature allows users
-to move both apps and private data of those apps between storage devices. When moving apps, the
-system respects the <a href="{@docRoot}guide/topics/manifest/manifest-element.html#install">
-{@code android:installLocation}</a> preference in the manifest.</p>
-
-<p>If your app accesses the following APIs or fields, be aware that the file paths they return
-will dynamically change when the app is moved between internal and external storage devices.
-When building file paths, it is strongly recommended that you always call these APIs dynamically.
-Don’t use hardcoded file paths or persist fully-qualified file paths that were built previously.</p>
-
-<ul>
-<li>{@link android.content.Context} methods:
- <ul>
- <li>{@link android.content.Context#getFilesDir() getFilesDir()}</li>
- <li>{@link android.content.Context#getCacheDir() getCacheDir()}</li>
- <li>{@link android.content.Context#getCodeCacheDir() getCodeCacheDir()}</li>
- <li>{@link android.content.Context#getDatabasePath(java.lang.String) getDatabasePath()}</li>
- <li>{@link android.content.Context#getDir(java.lang.String,int) getDir()}</li>
- <li>{@link android.content.Context#getNoBackupFilesDir() getNoBackupFilesDir()}</li>
- <li>{@link android.content.Context#getFileStreamPath(java.lang.String) getFileStreamPath()}</li>
- <li>{@link android.content.Context#getPackageCodePath() getPackageCodePath()}</li>
- <li>{@link android.content.Context#getPackageResourcePath() getPackageResourcePath()}</li>
- </ul>
-</li>
-<li>{@link android.content.pm.ApplicationInfo} fields:
- <ul>
- <li>{@link android.content.pm.ApplicationInfo#dataDir dataDir}</li>
- <li>{@link android.content.pm.ApplicationInfo#sourceDir sourceDir}</li>
- <li>{@link android.content.pm.ApplicationInfo#nativeLibraryDir nativeLibraryDir}</li>
- <li>{@link android.content.pm.ApplicationInfo#publicSourceDir publicSourceDir}</li>
- <li>{@link android.content.pm.ApplicationInfo#splitSourceDirs splitSourceDirs}</li>
- <li>{@link android.content.pm.ApplicationInfo#splitPublicSourceDirs splitPublicSourceDirs}</li>
- </ul>
-</li>
-</ul>
-
-<p>To debug this feature in the developer preview, you can enable adoption of a USB drive that is
-connected to an Android device through a USB On-The-Go (OTG) cable, by running these
-commands:</p>
-
-<pre>
-$ adb root
-$ sleep 2
-$ adb shell setprop persist.fw.force_adoptable 1
-$ adb reboot
-</pre>
-
-<h2 id="behavior-apache-http-client">Apache HTTP Client Removal</h2>
-<p>This release removes support for the Apache HTTP client. If your app is using this client and
-targets Android 2.3 (API level 9) or higher, use the {@link java.net.HttpURLConnection} class
-instead. This API is more efficient because it reduces network use through transparent compression
-and response caching, and minimizes power consumption. To continue using the Apache HTTP APIs, you
-must first declare the following compile-time dependency in your {@code build.gradle} file:
-</p>
-<pre>
-android {
- compileSdkVersion M
- useLibrary 'org.apache.http.legacy'
-}
-</pre>
-
-<h2 id="behavior-audiomanager-Changes">AudioManager Changes</h2>
-<p>Setting the volume directly or muting specific streams via the {@link android.media.AudioManager}
-class is no longer supported. The {@link android.media.AudioManager#setStreamSolo(int,boolean)
-setStreamSolo()} method is deprecated, and you should call the
-{@code AudioManager.requestAudioFocus()} method instead. Similarly, the
-{@link android.media.AudioManager#setStreamMute(int,boolean) setStreamMute()} method is
-deprecated; instead, call the {@code AudioManager.adjustStreamVolume()} method
-and pass in the direction value {@code ADJUST_MUTE} or {@code ADJUST_UNMUTE}.</p>
-
-<h2 id="behavior-test-selection">Text Selection</h2>
-
-<img src="{@docRoot}preview/images/text-selection.gif"
-style="float:right; margin:0 0 20px 30px" width="270" height="480" />
-
-<p>When users selects text in your app, you can now display text selection actions such as
-<em>Cut</em>, <em>Copy</em>, and <em>Paste</em> in a
-<a href="http://www.google.com/design/spec/patterns/selection.html#selection-text-selection"
-class="external-link">floating toolbar</a>. The user interaction implementation is similar to that
-for the contextual action bar, as described in
-<a href="{@docRoot}guide/topics/ui/menus.html#CABforViews">
-Enabling the contextual action mode for individual views</a>.</p>
-
-<p>To implement a floating toolbar for text selection, make the following changes in your existing
-apps:</p>
-<ol>
-<li>In your {@link android.view.View} or {@link android.app.Activity} object, change your
-{@link android.view.ActionMode} calls from
-{@code startActionMode(Callback)} to {@code startActionMode(Callback, ActionMode.TYPE_FLOATING)}.</li>
-<li>Take your existing implementation of ActionMode.Callback and make it extend
-{@code ActionMode.Callback2} instead.</li>
-<li>Override the {@code Callback2.onGetContentRect()} method to provide the coordinates of the
-content {@link android.graphics.Rect} object (such as a text selection rectangle) in the view.</li>
-<li>If the rectangle positioning is no longer valid, and this is the only element to be invalidated,
-call the {@code ActionMode.invalidateContentRect()} method.</li>
-</ol>
-
-<p>If you are using <a href="{@docRoot}tools/support-library/index.html">
-Android Support Library</a> revision 22.2, be aware that floating toolbars are not
-backward-compatible and appcompat takes control over {@link android.view.ActionMode} objects by
-default. This prevents floating toolbars from being displayed in M. To enable
-{@link android.view.ActionMode} support in an
-{@link android.support.v7.app.AppCompatActivity}, call
-{@code android.support.v7.app.AppCompatActivity.getDelegate()}, then call
-{@code android.support.v7.app.AppCompatDelegate.setHandleNativeActionModesEnabled()} on the returned
-{@link android.support.v7.app.AppCompatDelegate} object and set the input
-parameter to {@code false}. This call returns control of {@link android.view.ActionMode} objects to
-the framework. In devices running M, that allows the framework to support
-{@link android.support.v7.app.ActionBar} or floating toolbar modes, while on pre-M devices, only the
-{@link android.support.v7.app.ActionBar} modes are supported.</p>
-
-<h2 id="behavior-keystore">Android Keystore Changes</h2>
-<p>Starting this release, the
-<a href="{@docRoot}training/articles/keystore.html">Android Keystore provider</a> no longer supports
-DSA. ECDSA is still supported.</p>
-
-<p>Keys which do not require encryption at rest will no longer be deleted when secure lock screen
-is disabled or reset (for example, by the user or a Device Administrator). Keys which require
-encryption at rest will be deleted during these events.</p>
-
-<h2 id="behavior-themeable-colorstatelists">Themeable ColorStateLists</h2>
-<p>Theme attributes are now supported in
-{@link android.content.res.ColorStateList} for devices running M. The
-{@link android.content.res.Resources#getColorStateList(int) getColorStateList()} and
-{@link android.content.res.Resources#getColor(int) getColor()} methods have been deprecated. If
-you are calling these APIs, call the new {@code Context.getColorStateList()} or
-{@code Context.getColor()} methods instead. These methods are also available in the
-v4 appcompat library via {@link android.support.v4.content.ContextCompat}.</p>
-
-<h2 id="night-mode">Night Mode (User-configurable Dark Theme)</h2>
-<p>
-Support for the {@code -night} resource qualifier has been updated in M. Previously, night mode was
-only available when a device was docked and in car mode. Starting in M, night mode is available on
-all devices and is user-configurable via <em>Settings > Display > Theme</em>. You can adjust this
-setting globally using {@link android.app.UiModeManager#setNightMode(int) setNightMode()}. The
-Dark theme corresponds to {@link android.app.UiModeManager#MODE_NIGHT_YES}. When the device is in
-night mode, the resource framework will prefer resources that have the -night qualifier. To
-take advantage of user-configurable Dark mode in your app, extend from the
-{@code Theme.Material.DayNight} set of themes rather than {@code Theme.Material} or
-{@code Theme.Material.Light}.
-</p>
-
-<h2 id="behavior-art-runtime">ART Runtime</h2>
-<p>The ART runtime now properly implements access rules for the
-{@link java.lang.reflect.Constructor#newInstance(java.lang.Object...) newInstance()} method. This
-change fixes a problem where Dalvik was checking access rules incorrectly in previous versions.
-If your app uses the
-{@link java.lang.reflect.Constructor#newInstance(java.lang.Object...) newInstance()} method and you
-want to override access checks, call the
-{@link java.lang.reflect.Constructor#setAccessible(boolean) setAccessible()} method with the input
-parameter set to {@code true}. If your app uses the
-<a href="{@docRoot}tools/support-library/features.html#v7">v7 appcompat library</a> or the
-<a href="{@docRoot}tools/support-library/features.html#v7-recyclerview">v7 recyclerview library</a>,
-you must update your app to use to the latest versions of these libraries. Otherwise, make sure that
-any custom classes referenced from XML are updated so that their class constructors are accessible.</p>
-
-<p>The M release updates the behavior of the dynamic linker. The dynamic linker now understands the
-difference between a library’s {@code soname} and its path
-(<a href="https://code.google.com/p/android/issues/detail?id=6670" class="external-link">
-public bug 6670</a>), and search by {@code soname} is now
-implemented. Apps which previously worked that have bad {@code DT_NEEDED} entries
-(usually absolute paths on the build machine’s file system) may fail when loaded on M.</p>
-
-<p>The {@code dlopen(3) RTLD_LOCAL} flag is now correctly implemented in M. Note that
-{@code RTLD_LOCAL} is the default, so calls to {@code dlopen(3)} that didn’t explicitly use
-{@code RTLD_LOCAL} will be affected (unless your app explicitly used {@code RTLD_GLOBAL}). With
-{@code RTLD_LOCAL}, symbols will not be made available to libraries loaded by later calls to
-{@code dlopen(3)} (as opposed to being referenced by {@code DT_NEEDED} entries).</p>
-</p>
-
-<h2 id="behavior-afw">Android for Work Changes</h2>
-<p>This release includes the following behavior changes for Android for Work:</p>
-<ul>
-<li><strong>Work contacts in personal contexts.</strong> Google Messenger and the Google Dialer
-Call Log now display work contacts when the user views past messages or calls. Furthermore, both
-work and personal contacts are now available to devices over Bluetooth, but you can hide work
-profile contacts through a device policy by calling the new
-{@code DevicePolicyManager.setBluetoothContactSharingDisabled()} method. Initiating a call or
-creating a new message will only show personal contacts, as consistent with the experience in
-Android 5.0.
-</li>
-<li><strong>WiFi configuration removal:</strong> WiFi configurations added by a Profile Owner
-(for example, through calls to the
-{@link android.net.wifi.WifiManager#addNetwork(android.net.wifi.WifiConfiguration)
-addNetwork()} method) are now removed if that work profile is deleted.</li>
-<li><strong>WiFi configuration lockdown:</strong> Any WiFi configuration created by an active Device
-Owner can no longer be modified or deleted by the user. The user can still create and
-modify their own WiFi configurations, so long as the {@link android.os.UserManager} constant
-{@link android.os.UserManager#DISALLOW_CONFIG_WIFI} has not been set for that user.</li>
-<li><strong>VPN in Settings:</strong> VPN apps are now visible in <em>Settings > More > VPN</em>.
-Additionally, the notifications that accompany VPN usage are now specific to whether that VPN is
-configured for a managed profile or the entire device.</li>
-<li><strong>Work status notification:</strong> A status bar briefcase icon now appears whenever
-an app from the managed profile has an activity in the foreground. Furthermore, if the device is
-unlocked directly to the activity of an app in the managed profile, a toast is displayed notifying
-the user that they are within the work profile.
-</li>
-<li><strong>Download Work Policy Controller via Google account addition:</strong> When a Google
-account that requires management via a Work Policy Controller (WPC) app is added to a device
-outside of a managed context, the add account flow now prompts the user to install the
-appropriate WPC. This behavior also applies to accounts added via
-<em>Settings > Accounts</em> in the initial device setup wizard.</li>
-</ul>
diff --git a/docs/html/preview/api-overview.jd b/docs/html/preview/api-overview.jd
index 5fd6bb8..b8a6033 100644
--- a/docs/html/preview/api-overview.jd
+++ b/docs/html/preview/api-overview.jd
@@ -165,11 +165,11 @@ method to re-authenticate the user within your app.
<p>To see an app implementation of this feature, refer to the
<a href="https://github.com/googlesamples/android-ConfirmCredentials" class="external-link">
- Confirm Device Credentials sample</a>.</p>
+ Confirm Credentials sample</a>.</p>
<h2 id="direct-share">Direct Share</h2>
-<img src="{@docRoot}preview/images/direct-share-screen_2x.png"
+<img src="{@docRoot}preview/images/direct-share-screen.png"
srcset="{@docRoot}preview/images/direct-share-screen.png 1x, preview/images/direct-share-screen_2x.png 2x"
style="float:right; margin:0 0 20px 30px" width="312" height="335" />
diff --git a/docs/html/preview/backup/index.jd b/docs/html/preview/backup/index.jd
index c7d85ae..6735379 100644
--- a/docs/html/preview/backup/index.jd
+++ b/docs/html/preview/backup/index.jd
@@ -1,7 +1,7 @@
page.title=Auto Backup for Apps
page.tags=backup, previewresources, androidm
page.keywords=backup, autobackup, preview
-
+page.image=images/cards/card-auto-backup_2x.png
@jd:body
<div id="qv-wrapper">
diff --git a/docs/html/preview/behavior-changes.jd b/docs/html/preview/behavior-changes.jd
index 568d46e..9b3dbab 100644
--- a/docs/html/preview/behavior-changes.jd
+++ b/docs/html/preview/behavior-changes.jd
@@ -1,6 +1,6 @@
page.title=Behavior Changes
page.keywords=preview,sdk,compatibility
-sdk.platform.apiLevel=22-mnc
+sdk.platform.apiLevel=MNC
@jd:body
<div id="qv-wrapper">
@@ -44,7 +44,7 @@ sdk.platform.apiLevel=22-mnc
<p>Along with new features and capabilities, the M Developer Preview includes a variety of
system changes and API behavior changes. This document highlights
-some of the key changes that you should be understand and account for in your apps.</p>
+some of the key changes that you should understand and account for in your apps.</p>
<p>If you have previously published an app for Android, be aware that your app
might be affected by these changes in the platform.</p>
diff --git a/docs/html/preview/data-binding/guide.jd b/docs/html/preview/data-binding/guide.jd
deleted file mode 100644
index 49b690f..0000000
--- a/docs/html/preview/data-binding/guide.jd
+++ /dev/null
@@ -1,908 +0,0 @@
-page.title=Data Binding Guide
-
-@jd:body
-<p>Data Binding allows you write declarative layouts and minimize the glue code
-that is necessary to bind your application logic and layouts.</p>
-
-
-<h2 id=build_environment>Build Environment</h2>
-
-
-<p><strong>Setting Up Work Environment:</strong></p>
-
-<p>Data Binding EAP only supports gradle.</p>
-
-<p>To set up your application, unzip the provided bundle to a location. It has 3
-sections</p>
-
-<ul>
- <li> <em>maven-repo:</em> which keeps the data-binding libraries
- <li> <em>samples:</em> Sample applications
- <li> <em>databinding.properties:</em> Properties file that can be used to integrate with your app
-</ul>
-
-<p>Add the following section to the project’s build.gradle file (not the module&apos;s
-build.gradle) and replace <code><BUNDLE_FOLDER> </code>with the absolute path of the bundle that you’ve unzipped in the previous step.</p>
-
-<pre class=prettyprint>
-buildscript {
- <strong>def </strong>eapFolder = &apos;&lt;BUNDLE_FOLDER>&apos;
-<strong> def </strong>Properties props = <strong>new </strong>Properties()
- props.load(<strong>new </strong>FileInputStream(<strong>"</strong>${eapFolder}<strong>/databinding.properties"</strong>))
- props.mavenRepoDir = <strong>"</strong>${eapFolder}<strong>/</strong>${props.mavenRepoName}<strong>"
- </strong>ext.config = props
- repositories {
- jcenter()
- maven {
- url config.mavenRepoDir
- }
- }
- dependencies {
- classpath <strong>"com.android.tools.build:gradle:1.1.3"
- </strong>classpath <strong>"com.android.databinding:dataBinder:</strong>${config.snapshotVersion}<strong>"
-<em></strong> </em>}
-}
-allprojects {
- repositories {
- jcenter()
- maven {
- url config.mavenRepoDir
- }
- }
-}
-</pre>
-
-<p>Next, add the following lines to the <em>build.gradle</em>
-file of each module that will use data-binding. The application module must
-have this, even if only its libraries use data binding.</p>
-
-<pre class=prettyprint>
-apply plugin: <strong>&apos;com.android.databinding&apos;
-</strong>dependencies {
- compile <strong>"com.android.databinding:library:</strong>${config.snapshotVersion}<strong>"
-</strong> compile <strong>"com.android.databinding:baseLibrary:</strong>${config.snapshotVersion}<strong>"
-</strong> compile <strong>"com.android.databinding:adapters:</strong>${config.snapshotVersion}<strong>"
-</strong> provided <strong>"com.android.databinding:annotationprocessor:</strong>${config.snapshotVersion}<strong>"
-</strong>}
-</pre>
-
-
-<h2 id="data_binding_layout_files">Data Binding Layout Files</h2>
-
-
-<h3 id="writing_expressions">Writing your first data binding expressions:</h3>
-
-<p>Data-binding layout files are slightly different and start with a root tag of
-<strong>layout</strong> followed by a <strong>data</strong> element and a
-<strong>view</strong> root element. This view element is what your root would
-be in a non-binding layout file.A sample file looks like this:</p>
-
-<pre class=prettyprint>
-<em>&lt;?<strong></em>xml version="1.0" encoding="utf-8"<em></strong>?>
-</em>&lt;<strong>layout xmlns:android="http://schemas.android.com/apk/res/android"</strong>>
- &lt;<strong>data</strong>>
- &lt;<strong>variable name="user" type="com.example.User"</strong>/>
- &lt;/<strong>data</strong>>
- &lt;<strong>LinearLayout
- android:orientation="vertical"
- android:layout_width="match_parent"
- android:layout_height="match_parent"</strong>>
- &lt;<strong>TextView android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- android:text="&commat;{user.firstName}"</strong>/>
- &lt;<strong>TextView android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- android:text="&commat;{user.lastName}"</strong>/>
- &lt;/<strong>LinearLayout</strong>>
-&lt;/<strong>layout</strong>>
-</pre>
-
-<p>The user <strong>variable</strong> within <strong>data</strong> describes a property that may be used within this layout.</p>
-
-<pre class=prettyprint>
-&lt;<strong>variable name="user" type="com.example.User"</strong>/>
-</pre>
-
-<p>Expressions within the layout are written in the attribute properties using the
-“<code>&commat;{}</code>” syntax. Here, the TextView’s text is set to the firstName property of user:</p>
-<pre class=prettyprint>
-&lt;<strong>TextView android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- android:text="&commat;{user.firstName}"</strong>/>
-</pre>
-
-
-<h3 id="data_object">Data Object</h3>
-
-<p>Let’s assume for now that you have a plain-old Java object (POJO) for User:</p>
-<pre class=prettyprint>
-<strong>public class </strong>User {
- <strong>public final </strong>String <strong>firstName</strong>;
- <strong>public final </strong>String <strong>lastName</strong>;
- <strong>public </strong>User(String firstName, String lastName) {
- <strong>this</strong>.<strong>firstName </strong>= firstName;
- <strong>this</strong>.<strong>lastName </strong>= lastName;
- }
-}
-</pre>
-
-<p>This type of object has data that never changes. It is common in applications
-to have data that is read once and never changes thereafter. It is also
-possible to use a JavaBeans objects:</p>
-<pre class=prettyprint>
-<strong>public class </strong>User {
- <strong>private final </strong>String <strong>firstName</strong>;
- <strong>private final </strong>String <strong>lastName</strong>;
- <strong>public </strong>User(String firstName, String lastName) {
- <strong>this</strong>.<strong>firstName </strong>= firstName;
- <strong>this</strong>.<strong>lastName </strong>= lastName;
- }
- <strong>public </strong>String getFirstName() {
- <strong>return this</strong>.<strong>firstName</strong>;
- }
- <strong>public </strong>String getLastName() {
- <strong>return this</strong>.<strong>lastName</strong>;
- }
-}
-</pre>
-
-<p>From the perspective of data binding, these two classes are equivalent. The
-expression <strong><code>&commat;{user.lastName}</code></strong> used for the TextView’s <strong><code>android:text</code></strong> attribute will access the <strong><code>firstName</code></strong> field in the former class and the <code>getFirstName()</code> method in the latter class.
-</p><h3 id=binding_data>Binding Data</h3>
-
-<p>By default, a Binding class will be generated based on the name of the layout
-file, converting it to Pascal case and suffixing “Binding” to it. The above
-layout file was <code>activity_main.xml</code> so the generate class was <code>ActivityMainBinding</code>. This class holds all the bindings from the layout properties (e.g. the <code>user</code> variable) to the layout’s Views and knows how to assign values for the binding
-expressions.The easiest means for creating the bindings is to do it while inflating:
-</p>
-
-<pre class=prettyprint>
-&commat;Override
-<strong>protected void </strong>onCreate(Bundle savedInstanceState) {
- <strong>super</strong>.onCreate(savedInstanceState);
- ActivityMainBinding binding = DataBindingUtil.<em>setContentView</em>(<strong>this</strong>, R.layout.<em><strong>main_activity</strong></em>);
- User user = <strong>new </strong>User(<strong>"Test"</strong>, <strong>"User"</strong>);
- binding.setUser(user);
-}
-</pre>
-
-<p>You’re done! Run the application and you’ll see Test User in the UI.Alternatively, you can get the view via:
-</p><pre class=prettyprint>
-MainActivityBinding binding = MainActivityBinding.<em>inflate</em>(getLayoutInflater());
-</pre>
-
-<p>If you are using data binding items inside a ListView or RecyclerView adapter,
-you may prefer to use:
-</p><pre class=prettyprint>
-ListItemBinding binding = ListItemBinding.inflate(layoutInflater, viewGroup,
-false);
-//or
-ListItemBinding binding = DataBindingUtil.<em>inflate</em>(layoutInflater, R.layout.<em><strong>list_item</strong></em>, viewGroup, <strong>false</strong>);
-</pre>
-
-
-<h2 id=layout_details>Layout Details</h2>
-
-
-<h3 id=imports>Imports</h3>
-
-<p>Zero or more <strong><code>import</code></strong> elements may be used inside the <strong><code>data</code></strong> element. These allow easy reference to classes inside your layout file, just
-like in Java.
-</p><pre class=prettyprint>
-&lt;<strong>data</strong>>
- &lt;<strong>import type="android.view.View"</strong>/>
-&lt;/<strong>data</strong>>
-</pre>
-
-<p>Now, View may be used within your binding expression:
-</p><pre class=prettyprint>
-&lt;<strong>TextView
- android:text="&commat;{user.lastName}"
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- android:visibility="&commat;{user.isAdult ? View.VISIBLE : View.GONE}"</strong>/>
-</pre>
-
-<p>When there are class name conflicts, one of the classes may be renamed to an
-“alias:”</p>
-<pre class=prettyprint>
-&lt;<strong>import type="android.view.View"</strong>/>
-&lt;<strong>import type="com.example.real.estate.View"
- alias="Vista"</strong>/>
-</pre>
-
-<p>Now, <strong><code>Vista</code></strong> may be used to reference the <code>com.example.real.estate.View</code> and <strong><code>View</code></strong> may be used to reference <code>android.view.View </code>within the layout file.Imported types may be used as type references in variables and expressions:</p>
-<pre class=prettyprint>
-&lt;<strong>data</strong>>
- &lt;<strong>import type="com.example.User"</strong>/>
- &lt;<strong>import type="java.util.List"</strong>/>
- &lt;<strong>variable name="user" type="User"</strong>/>
- &lt;<strong>variable name="userList" type="List&lt;User&gt;"</strong>/>
-&lt;/<strong>data</strong>>
-…
-&lt;<strong>TextView
- android:text="&commat;{((User)(user.connection)).lastName}"
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"</strong>/>
-</pre>
-
-<p>Imported types may also be used when referencing static fields and methods in
-expressions:</p>
-<pre class=prettyprint>
-&lt;<strong>data</strong>>
- &lt;<strong>import type="com.example.MyStringUtils"</strong>/>
- &lt;<strong>variable name="user" type="com.example.User"</strong>/>
-&lt;/<strong>data</strong>>
-…
-&lt;<strong>TextView
- android:text="&commat;{MyStringUtils.capitalize(user.lastName)}"
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"</strong>/>
-</pre>
-
-<p>Just as in Java, <code>java.lang.*</code> is imported automatically.</p>
-<h3 id=variables>Variables</h3>
-
-<p>Any number of <strong><code>variable</code></strong> elements may be used inside the <strong><code>data</code></strong> element. Each <strong><code>variable</code></strong> element describes a property that may be set on the layout to be used in
-binding expressions within the layout file.</p>
-<pre class=prettyprint>
-&lt;<strong>data</strong>>
- &lt;<strong>import type="android.graphics.drawable.Drawable"</strong>/>
- &lt;<strong>variable name="user" type="com.example.User"</strong>/>
- &lt;<strong>variable name="image" type="Drawable"</strong>/>
- &lt;<strong>variable name="note" type="String"</strong>/>
-&lt;/<strong>data</strong>>
-</pre>
-
-<p>The variable types are inspected at compile time, so if a variable implements <a href="#observable_objects">Observable</a>, <a href="#observable_collections">observable collection</a>, that should be reflected in the type. If the variable is a base class or
- interface that does not implement the Observable* interface, the variables will <strong>not be</strong> observed!</p>
-
-<p>When there are different layout files for various configurations (e.g.
-landscape or portrait), the variables will be combined. There must not be
-conflicting variable definitions between these layout files.</p>
-
-<p>The generated binding class will have a setter and getter for each of the
-described variables. The variables will take the default Java values until the
-setter is called &mdash; <code>null</code> for reference types, <code>0</code> for <code>int</code>, <code>false</code> for <code>boolean</code>, etc.</p>
-
-<h3 id=custom_binding_class_names>Custom Binding Class Names</h3>
-
-<p>By default, a Binding class is generated based on the name of the layout file,
-starting it with upper-case, removing underscores ( _ ) and capitalizing the
-following letter and then suffixing “Binding”. This class will be placed in a
-databinding package under the module package. For example, the layout file <code>contact_item.xml</code> will generate <code>ContactItemBinding</code>. If the module package is <code>com.example.my.app</code>, then it will be placed in <code>com.example.my.app.databinding</code>.</p>
-
-<p>Binding classes may be renamed or placed in different packages by adjusting the <strong><code>class</code></strong> attribute of the <strong><code>data</code></strong> element. For example:</p>
-<pre class=prettyprint>
-&lt;<strong>data class="ContactItem"</strong>>
- ...
-&lt;/<strong>data</strong>>
-</pre>
-
-<p>This generates the binding class as <code>ContactItem</code> in the databinding package in the module package. If the class should be
-generated in a different package within the module package, it may be prefixed
-with “.”:</p>
-<pre class=prettyprint>
-&lt;<strong>data class=".ContactItem"</strong>>
- ...
-&lt;/<strong>data</strong>>
-</pre>
-
-In this case, <code>ContactItem</code> is generated in the module package directly.Any package may be used if the full package is provided:
-<pre class=prettyprint>
-&lt;<strong>data class="com.example.ContactItem"</strong>>
- ...
-&lt;/<strong>data</strong>>
-</pre>
-
-
-<h3 id=includes>Includes</h3>
-
-<p>Variables may be passed into an included layout&apos;s binding from the containing
-layout by using the application namespace and the variable name in an
-attribute:</p>
-<pre class=prettyprint>
-<em>&lt;?<strong></em>xml version="1.0" encoding="utf-8"<em></strong>?>
-</em>&lt;<strong>layout xmlns:android="http://schemas.android.com/apk/res/android"
-</strong> <strong> xmlns:bind="http://schemas.android.com/apk/res-auto"</strong>>
- &lt;<strong>data</strong>>
- &lt;<strong>variable name="user" type="com.example.User"</strong>/>
- &lt;/<strong>data</strong>>
- &lt;<strong>LinearLayout
- android:orientation="vertical"
- android:layout_width="match_parent"
- android:layout_height="match_parent"</strong>>
- &lt;<strong>include layout="&commat;layout/name"
- bind:user="&commat;{user}"</strong>/>
- &lt;<strong>include layout="&commat;layout/contact"
- bind:user="&commat;{user}"</strong>/>
- &lt;/<strong>LinearLayout</strong>>
-&lt;/<strong>layout</strong>>
-</pre>
-
-<p>Here, there must be a <code>user</code> variable in both the <code>name.xml </code>and <code>contact.xml </code>layout files.</p>
-<h3 id=expression_language>Expression Language</h3>
-
-
-<h4 id=common_features>Common Features</h4>
-
-<p>The expression language looks a lot like a Java expression. These are the same:</p>
-<ul>
- <li> Mathematical <strong><code>+ - / * %</code></strong>
- <li> String concatenation <strong><code>+</code></strong>
- <li> <code>L</code>ogical <strong><code>&& ||</code></strong>
- <li> Binary <strong><code>&</code> <code>|</code> <code>^</code></strong>
- <li> Unary <strong><code>+ - ! ~</code></strong>
- <li> Shift <strong><code>>> >>> <<</code></strong>
- <li> Comparison <strong><code>== > < >= <=</code></strong>
- <li> <strong><code>instanceof</code></strong>
- <li> Grouping <strong><code>()</code></strong>
- <li> Literals - character, String, numeric, <strong><code>null</code></strong>
- <li> Cast
- <li> Method calls
- <li> Field access
- <li> Array access <strong><code>[]</code></strong>
- <li> Ternary operator <strong><code>?:</code></strong>
-</ul>
-<p>Examples:</p>
-<pre class=prettyprint>
-<strong>android:text="&commat;{String.valueOf(index + 1)}"
-android:visibility="&commat;{age &lt; 13 ? View.GONE : View.VISIBLE}"
-android:transitionName=&apos;&commat;{"image_" + id}&apos;</strong>
-</pre>
-
-
-<h4 id=missing_operations>Missing Operations</h4>
-
-<p>A few operations are missing from the expression syntax that you can use in
-Java.</p>
-<ul>
- <li> <strong><code>this</code></strong>
- <li> <strong><code>super</code></strong>
- <li> <strong><code>new</code></strong>
- <li> Explicit generic invocation
-</ul>
-
-<h4 id=null_coalescing_operator>Null Coalescing Operator</h4>
-
-<p>The null coalescing operator (<strong><code>??</code></strong>) chooses the left operand if it is not null or the right if it is null.</p>
-<pre class=prettyprint>
-<strong>android:text="&commat;{user.displayName ?? user.lastName}"</strong>
-</pre>
-
-<p>This is functionally equivalent to:</p>
-<pre class=prettyprint>
-<strong>android:text="&commat;{user.displayName != null ? user.displayName : user.lastName}"</strong>
-</pre>
-
-
-<h4 id=property_reference>Property Reference</h4>
-
-<p>The first was already discussed in the <a href="#writing_your_first_data_binding_expressions">Writing your first data binding expressions</a> above: short form JavaBean references. When an expression references a
-property on a class, it uses the same format for fields, getters, and
-ObservableFields.</p>
-<pre class=prettyprint>
-<strong>android:text="&commat;{user.lastName}"</strong>
-</pre>
-
-
-<h4 id=collections>Collections</h4>
-
-<p>Common collections: arrays, lists, sparse lists, and maps, may be accessed
-using the <code>[]</code> operator for convenience.</p>
-<pre class=prettyprint>
-&lt;<strong>data</strong>>
- &lt;<strong>import type="android.util.SparseArray"</strong>/>
- &lt;<strong>import type="java.util.Map"</strong>/>
- &lt;<strong>import type="java.util.List"</strong>/>
- &lt;<strong>variable name="list" type="List&lt;String&gt;"</strong>/>
- &lt;<strong>variable name="sparse" type="SparseArray&lt;String&gt;"</strong>/>
- &lt;<strong>variable name="map" type="Map&lt;String, String&gt;"</strong>/>
- &lt;<strong>variable name="index" type="int"</strong>/>
- &lt;<strong>variable name="key" type="String"</strong>/>
-&lt;/<strong>data</strong>>
-…
-<strong>android:text="&commat;{list[index]}"
-</strong>…
-<strong>android:text="&commat;{sparse[index]}"
-</strong>…
-<strong>android:text="&commat;{map[key]}"
-</strong>
-</pre>
-
-
-<h4 id=string_literals>String Literals</h4>
-
-<p>When using single quotes around the attribute value, it is easy to use double
-quotes in the expression:</p>
-<pre class=prettyprint>
-<strong>android:text=&apos;&commat;{map["firstName"]}&apos;</strong>
-</pre>
-
-<p>It is also possible to use double quotes to surround the attribute value. When
-doing so, String literals should either use the &quot; or back quote (`).</p>
-<pre class=prettyprint>
-<strong>android:text="&commat;{map[`firstName`}"
-android:text="&commat;{map[&quot;firstName&quot;]}"</strong>
-</pre>
-
-
-<h4 id=resources>Resources</h4>
-
-<p>It is possible to access resources as part of expressions using the normal
-syntax:</p>
-<pre class=prettyprint>
-<strong>android:padding="&commat;{large? &commat;dimen/largePadding : &commat;dimen/smallPadding}"</strong>
-</pre>
-
-<p>Format strings and plurals may be evaluated by providing parameters:</p>
-<pre class=prettyprint>
-<strong>android:text="&commat;{&commat;string/nameFormat(firstName, lastName)}"
-android:text="&commat;{&commat;plurals/banana(bananaCount)}"</strong>
-</pre>
-
-<p>Some resources require explicit type evaluation.</p>
-
-<table>
- <tr>
- <th>Type</th>
- <th>Normal Reference</th>
- <th>Expression Reference</th>
- </tr>
- <tr>
- <td>
-<pre class=prettyprint>
-String[]</td>
- <td>
-&commat;array</td>
- <td>
-&commat;stringArray</td>
- </tr>
- <tr>
- <td>
-int[]</td>
- <td>
-&commat;array</td>
- <td>
-&commat;intArray</td>
- </tr>
- <tr>
- <td>
-TypedArray</td>
- <td>
-&commat;array</td>
- <td>
-&commat;typedArray</td>
- </tr>
- <tr>
- <td>
-Animator</td>
- <td>
-&commat;animator</td>
- <td>
-&commat;animator</td>
- </tr>
- <tr>
- <td>
-StateListAnimator</td>
- <td>
-&commat;animator</td>
- <td>
-&commat;stateListAnimator</td>
- </tr>
- <tr>
- <td>
-</pre>
-
-color <code>int</code></td>
- <td>
-<pre class=prettyprint>
-&commat;color</td>
- <td>
-&commat;color</td>
- </tr>
- <tr>
- <td>
-ColorStateList</td>
- <td>
-&commat;color</td>
- <td>
-&commat;colorStateList</td>
- </tr>
-</table>
-
-</pre>
-
-
-<h2 id="data_objects">Data Objects</h2>
-
-
-<p>Any plain old Java object (POJO) may be used for data binding, but modifying a
-POJO will not cause the UI to update. The real power of data binding can be
-used by giving your data objects the ability to notify when data changes. There
-are three different data change notification mechanisms, <code>Observable </code>objects, <code>ObservableField</code>s, and <code>observable collections</code>.</p>
-
-<p>When one of these observable data object is bound to the UI and a property of
-the data object changes, the UI will be updated automatically.</p>
-
-<h3 id=observable_objects>Observable Objects</h3>
-
-
-<p>A class implementing <code>android.databinding.Observable</code> interface will allow the binding to attach a single listener to a bound object
-to listen for changes of all properties on that object.</p>
-
-<p>The <code>Observable</code> interface has a mechanism to add and remove listeners, but notifying is up to
-the developer. To make development easier, a base class, <code>BaseObservable,</code> was created to implement the listener registration mechanism. The data class
-implementer is still responsible for notifying when the properties change. This
-is done by assigning an <code>Bindable </code>annotation to the getter and notifying in the setter.</p>
-
-<pre class=prettyprint>
-<strong>private static class </strong>User <strong>extends </strong>BaseObservable {
- <strong>private </strong>String <strong>firstName</strong>;
- <strong>private </strong>String <strong>lastName</strong>;
- &commat;Bindable
- <strong>public </strong>String getFirstName() {
- <strong>return this</strong>.<strong>firstName</strong>;
- }
- &commat;Bindable
- <strong>public </strong>String getFirstName() {
- <strong>return this</strong>.<strong>lastName</strong>;
- }
- <strong>public void </strong>setFirstName(String firstName) {
- <strong>this</strong>.<strong>firstName </strong>= firstName;
- notifyPropertyChanged(BR.firstName);
- }
- <strong>public void </strong>setLastName(String lastName) {
- <strong>this</strong>.<strong>lastName </strong>= lastName;
- notifyPropertyChanged(BR.lastName);
- }
-}
-</pre>
-
-<p>The <code>Bindable </code>annotation generates an entry in the BR class file during compilation. The BR
-class file will be generated in the module package.If the base class for data classes cannot be changed, the <code>Observable</code> interface may be implemented using the convenient <code>PropertyChangeRegistry</code> to store and notify listeners efficiently.</p>
-
-<h3 id=observablefields>ObservableFields</h3>
-
-<p>A little work is involved in creating Observable classes, so developers who
-want to save time or have few properties may use ObservableFields.
-ObservableFields are self-contained observable objects that have a single
-field. There are versions for all primitive types and one for reference types.
-To use, create a public final field in the data class:</p>
-<pre class=prettyprint>
-<strong>private static class </strong>User <strong>extends </strong>BaseObservable {
- <strong>public final </strong>ObservableField&lt;String> <strong>firstName </strong>=
- <strong>new </strong>ObservableField&lt;>();
- <strong>public final </strong>ObservableField&lt;String> <strong>lastName </strong>=
- <strong>new </strong>ObservableField&lt;>();
- <strong>public final </strong>ObservableInt <strong>age </strong>= <strong>new </strong>ObservableInt();
-}
-</pre>
-
-<p>That&apos;s it! To access the value, use the set and get accessor methods:</p>
-<pre class=prettyprint>
-user.<strong>firstName</strong>.set(<strong>"Google"</strong>);
-<strong>int </strong>age = user.<strong>age</strong>.get();
-</pre>
-
-
-<h3 id=observable_collections>Observable Collections</h3>
-
-<p>Some applications use more dynamic structures to hold data. Observable
- collections allow keyed access to these data objects.ObservableArrayMap is useful when the key is a reference type, such as String.</p>
-
-<pre class=prettyprint>
-ObservableArrayMap&lt;String, Object> user = <strong>new </strong>ObservableArrayMap&lt;>();
-user.put(<strong>"firstName"</strong>, <strong>"Google"</strong>);
-user.put(<strong>"lastName"</strong>, <strong>"Inc."</strong>);
-user.put(<strong>"age"</strong>, 17);
-</pre>
-
-In the layout, the map may be accessed through the String keys:
-<pre class=prettyprint>
-&lt;<strong>data</strong>>
- &lt;<strong>import type="android.databinding.ObservableMap"</strong>/>
- &lt;<strong>variable name="user" type="ObservableMap&lt;String, Object>"</strong>/>
-&lt;/<strong>data</strong>>
-…
-&lt;<strong>TextView
- android:text=&apos;&commat;{user["lastName"]}&apos;
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"</strong>/>
-&lt;<strong>TextView
- android:text=&apos;&commat;{String.valueOf(1 + (Integer)user["age"])}&apos;
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"</strong>/>
-</pre>
-
-<p>ObservableArrayList is useful when the key is an integer:</p>
-<pre class=prettyprint>
-ObservableArrayList&lt;Object> user = <strong>new </strong>ObservableArrayList&lt;>();
-user.add(<strong>"Google"</strong>);
-user.add(<strong>"Inc."</strong>);
-user.add(17);
-</pre>
-
-<p>In the layout, the list may be accessed through the indices:</p>
-<pre class=prettyprint>
-&lt;<strong>data</strong>>
- &lt;<strong>import type="android.databinding.ObservableList"</strong>/>
- &lt;<strong>import type="com.example.my.app.Fields"</strong>/>
- &lt;<strong>variable name="user" type="ObservableList&lt;Object>"</strong>/>
-&lt;/<strong>data</strong>>
-…
-&lt;<strong>TextView
- android:text=&apos;&commat;{user[Fields.LAST_NAME]}&apos;
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"</strong>/>
-&lt;<strong>TextView
- android:text=&apos;&commat;{String.valueOf(1 + (Integer)user[Fields.AGE])}&apos;
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"</strong>/>
-</pre>
-
-
-<h2 id=generated_binding>Generated Binding</h2>
-
-<p>The generated binding class links the layout variables with the Views within
-the layout. As discussed earlier, the name and package of the Binding may be <a href="#custom_binding_class_names">customized</a>. The Generated binding classes all extend <code>android.databinding.ViewDataBinding</code>.</p>
-<h3 id=creating>Creating</h3>
-
-<p>The binding should be created soon after inflation to ensure that the View
-hierarchy is not disturbed prior to binding to the Views with expressions
-within the layout. There are a few ways to bind to a layout. The most common is
-to use the static methods on the Binding class.The inflate method inflates the View hierarchy and binds to it all it one step.
-There are versions that attach the View to its parent and that inflate without
-attaching.</p>
-<pre class=prettyprint>
-MyLayoutBinding binding = MyLayoutBinding.<em>inflate</em>(<strong>this</strong>);
-MyLayoutBinding binding = MyLayoutBinding.<em>inflate</em>(viewGroup);
-</pre>
-
-<p>If the layout was inflated using a different mechanism, it may be bound
-separately:</p>
-<pre class=prettyprint>
-MyLayoutBinding binding = MyLayoutBinding.<em>bind</em>(viewRoot);
-</pre>
-
-<p>Sometimes the binding cannot be known in advance. In such cases, the binding
-can be created using the DataBindingUtil class:</p>
-<pre class=prettyprint>
-ViewDataBinding binding = DataBindingUtil.<em>inflate</em>(context, layoutId,
- parent, attachToParent);
-ViewDataBinding binding = DataBindingUtil.<em>bindTo</em>(viewRoot, layoutId);
-</pre>
-
-
-<h3 id=views_with_ids>Views With IDs</h3>
-
-<p>A public final field will be generated for each View with an ID in the layout.
-The binding does a single pass on the View hierarchy, extracting the Views with
-IDs. This mechanism can be faster than calling findViewById for several Views. For example:</p>
-<pre class=prettyprint>
-&lt;<strong>layout xmlns:android="http://schemas.android.com/apk/res/android"</strong>>
- &lt;<strong>data</strong>>
- &lt;<strong>variable name="user" type="com.example.User"</strong>/>
- &lt;/<strong>data</strong>>
- &lt;<strong>LinearLayout
- android:orientation="vertical"
- android:layout_width="match_parent"
- android:layout_height="match_parent"</strong>>
- &lt;<strong>TextView android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- android:text="&commat;{user.firstName}"
-</strong> <strong>android:id="&commat;+id/firstName"</strong>/>
- &lt;<strong>TextView android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- android:text="&commat;{user.lastName}"</strong> <strong>android:id="&commat;+id/lastName"</strong>/>
- &lt;/<strong>LinearLayout</strong>>
-&lt;/<strong>layout</strong>>
-</pre>
-
-Will generate a binding class with:
-<pre class=prettyprint>
-<strong>public final </strong>TextView <strong>firstName</strong>;
-<strong>public final </strong>TextView <strong>lastName</strong>;
-</pre>
-
-<p>IDs are not nearly as necessary as without data binding, but there are still
-some instances where access to Views are still necessary from code.</p>
-<h3 id=variables>Variables</h3>
-
-<p>Each variable will be given a accessor methods.</p>
-<pre class=prettyprint>
-&lt;<strong>data</strong>>
- &lt;<strong>import type="android.graphics.drawable.Drawable"</strong>/>
- &lt;<strong>variable name="user" type="com.example.User"</strong>/>
- &lt;<strong>variable name="image" type="Drawable"</strong>/>
- &lt;<strong>variable name="note" type="String"</strong>/>
-&lt;/<strong>data</strong>>
-</pre>
-
-<p>will generate setters and getters in the binding:</p>
-<pre class=prettyprint>
-<strong>public abstract </strong>com.example.User getUser();
-<strong>public abstract void </strong>setUser(com.example.User user);
-<strong>public abstract </strong>Drawable getImage();
-<strong>public abstract void </strong>setImage(Drawable image);
-<strong>public abstract </strong>String getNote();
-<strong>public abstract void </strong>setNote(String note);
-</pre>
-
-
-<h3 id=viewstubs>ViewStubs</h3>
-
-<p>ViewStubs are a little different from normal Views. They start off invisible
-and when they either are made visible or are explicitly told to inflate, they
-replace themselves in the layout by inflating another layout.</p>
-
-<p>Because the ViewStub essentially disappears from the View hierarchy, the View
-in the binding object must also disappear to allow collection. Because the
-Views are final, a ViewStubProxy object takes the place of the ViewStub, giving
-the developer access to the ViewStub when it exists and also access to the
-inflated View hierarchy when the ViewStub has been inflated.</p>
-
-<p>When inflating another layout, a binding must be established for the new
-layout. Therefore, the ViewStubProxy must listen to the ViewStub&apos;s
-OnInflateListener and establish the binding at that time. Since only one can
-exist, the ViewStubProxy allows the developer to set an OnInflateListener on it
-that it will call after establishing the binding.</p>
-
-<h3 id=advanced_binding>Advanced Binding</h3>
-
-
-<h4 id=dynamic_variables>Dynamic Variables</h4>
-
-<p>At times, the specific binding class won&apos;t be known. For example, a
-RecyclerView Adapter operating against arbitrary layouts won&apos;t know the
-specific binding class. It still must assign the binding value during the
-onBindViewHolder.</p>
-
-<p>In this example, all layouts that the RecyclerView binds to have an "item"
-variable. The BindingHolder has a getBinding method returning the <code>ViewDataBinding</code> base.</p>
-<pre class=prettyprint>
-<strong>public void </strong>onBindViewHolder(BindingHolder holder, <strong>int </strong>position) {
- <strong>final </strong>T item = <strong>mItems</strong>.get(position);
- holder.getBinding().setVariable(BR.item, item);
- holder.getBinding().executePendingBindings();
-}
-</pre>
-
-
-<h4 id=immediate_binding>Immediate Binding</h4>
-
-<p>When a variable or observable changes, the binding will be scheduled to change
-before the next frame. There are times, however, when binding must be executed
-immediately. To force execution, use the executePendingBindings() method.</p>
-<h2 id=attribute_setters>Attribute Setters</h2>
-
-<p>Whenever a bound value changes, the generated binding class must call a setter
-method on the View with the binding expression. The data binding framework has
-ways to customize which method to call to set the value.</p>
-<h3 id=automatic_setters>Automatic Setters</h3>
-
-For an attribute, data binding tries to find the method setAttribute. The
-namespace for the attribute does not matter, only the attribute name itself.
-
-<p>For example, an expression associated with TextView&apos;s attribute <strong><code>android:text</code></strong> will look for a setText(String). If the expression returns an int, data
-binding will search for a setText(int) method. Be careful to have the
-expression return the correct type, casting if necessary.Note that data binding will work even if no attribute exists with the given
-name. You can then easily "create" attributes for any setter by using data
-binding. For example, support DrawerLayout doesn&apos;t have any attributes, but
-plenty of setters. You can use the automatic setters to use one of these.</p>
-<pre class=prettyprint>
-&lt;android.support.v4.widget.<strong>DrawerLayout
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- app:scrimColor="&commat;{&commat;color/scrim}"
- app:drawerListener="&commat;{fragment.drawerListener}"/></strong>
-</pre>
-
-
-<h3 id=renamed_setters>Renamed Setters</h3>
-
-<p>Some attributes have setters that don&apos;t match by name. For these methods, an
-attribute may be associated with the setter through BindingMethods annotation.
-This must be associated with a class and contains BindingMethod annotations,
-one for each renamed method. For example, the <strong><code>android:tint</code></strong> attribute is really associated with setImageTintList, not setTint.</p>
-<pre class=prettyprint>
-&commat;BindingMethods({
- &commat;BindingMethod(type = <strong>"android.widget.ImageView"</strong>,
- attribute = <strong>"android:tint"</strong>,
- method = <strong>"setImageTintList"</strong>),
-})
-</pre>
-
-<p>It is unlikely that developers will need to rename setters; the android
-framework attributes have already been implemented.</p>
-<h3 id=custom_setters>Custom Setters</h3>
-
-<p>Some attributes need custom binding logic. For example, there is no associated
-setter for the <strong><code>android:paddingLeft</code></strong> attribute. Instead, setPadding(left, top, right, bottom) exists. A static
-binding adapter method with the BindingAdapter annotation allows the developer
-to customize how a setter for an attribute is called.</p>
-
-<p>The android attributes have already had BindingAdapters created. For example,
-here is the one for paddingLeft:</p>
-<pre class=prettyprint></p>
-&commat;BindingAdapter(<strong>"android:paddingLeft"</strong>)
-<strong>public static void </strong>setPaddingLeft(View view, <strong>int </strong>padding) {
- view.setPadding(padding,
- view.getPaddingTop(),
- view.getPaddingRight(),
- view.getPaddingBottom());
-}
-</pre>
-
-<p>Binding adapters are useful for other types of customization. For example, a
- custom loader can be called off-thread to load an image.</p>
-
-<p>Developer-created binding adapters will override the data binding default
-adapters when there is a conflict.</p>
-
-<p>You can also have adapters that receive multiple parameters. </p>
-<pre class=prettyprint>
-&commat;BindingAdapter(attributes = {<strong>"bind:imageUrl"</strong>, <strong>"bind:error"</strong>})
-<strong>public static void </strong>loadImage(ImageView view, String url, Drawable error) {
- Picasso.<em>with</em>(view.getContext()).load(url).error(error).into(view);
-}
-</pre>
-
-<p>This adapter will be called if both <strong>imageUrl </strong>and <strong>error </strong>are used for an ImageView and <em>imageUrl </em>is a string and <em>error</em> is a drawable.</p>
-<ul>
- <li> Custom namespaces are ignore during matching.
- <li> You can also write adapters for android namespace.
-</ul>
-
-<pre class=prettyprint>
-&lt;ImageView app:imageUrl=“&commat;{venue.imageUrl}”
-app:error=“&commat;{&commat;drawable/venueError}”/>
-</pre>
-
-
-<h2 id=converters>Converters</h2>
-
-
-<h3 id=object_conversions>Object Conversions</h3>
-
-<p>When an Object is returned from a binding expression, a setter will be chosen
-from the automatic, renamed, and custom setters. The Object will be cast to a
-parameter type of the chosen setter.</p><p>This is a convenience for those using ObservableMaps to hold data. for example:</p>
-<pre class=prettyprint>
-&lt;<strong>TextView
- android:text=&apos;&commat;{userMap["lastName"]}&apos;
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"</strong>/>
-</pre>
-
-<p>The userMap returns an Object and that Object will be automatically cast to
-parameter type found in the setter <code>setText(CharSequence)</code>. When there may be confusion about the parameter type, the developer will need
-to cast in the expression.</p>
-<h3 id=custom_conversions>Custom Conversions</h3>
-
-<p>Sometimes conversions should be automatic between specific types. For example,
-when setting the background:</p>
-<pre class=prettyprint>
-&lt;<strong>View
- android:background="&commat;{isError ? &commat;color/red : &commat;color/white}"
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"</strong>/>
-</pre>
-
-<p>Here, the background takes a <code>Drawable</code>, but the color is an integer. Whenever a <code>Drawable</code> is expected and an integer is returned, the <code>int</code> should be converted to a <code>ColorDrawable</code>. This conversion is done using a static method with a BindingConversion
-annotation:</p>
-<pre class=prettyprint>
-&commat;BindingConversion
-<strong>public static </strong>ColorDrawable convertColorToDrawable(<strong>int </strong>color) {
- <strong>return new </strong>ColorDrawable(color);
-}
-</pre>
-
-<p>Note that conversions only happen at the setter level, so it is <strong>not allowed </strong>to mix types like this:</p>
-<pre class=prettyprint>
-&lt;<strong>View
- android:background="&commat;{isError ? &commat;drawable/error : &commat;color/white}"
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"</strong>/>
-</pre>
-
diff --git a/docs/html/preview/download.jd b/docs/html/preview/download.jd
index 9dd0f85..448a23d 100644
--- a/docs/html/preview/download.jd
+++ b/docs/html/preview/download.jd
@@ -189,7 +189,7 @@ This is the Android SDK Preview License Agreement (the “License Agreement”).
</p>
-<h2 id="#docs">Developer Documentation</h2>
+<h2 id="docs">Developer Documentation</h2>
<p>
The developer documentation download package provides detailed API reference information and an API difference report for the preview.
@@ -214,7 +214,7 @@ This is the Android SDK Preview License Agreement (the “License Agreement”).
<h2 id="images">Hardware System Images</h2>
<p>
- These system images allow you install a preview version of the platform on a physical device for
+ These system images allow you to install a preview version of the platform on a physical device for
testing. By configuring a device with one of these images, you can install and test your app to
see how it performs on the next version of the platform. The process of installing a system image
on a device <em>removes all data from the device</em>, so you should backup your data before
@@ -292,7 +292,7 @@ This is the Android SDK Preview License Agreement (the “License Agreement”).
<h3 id="revertDevice">Revert a Device to Factory Specifications</h3>
<p>
- If you want to uninstall the Preview and revert the device to factory specifications, go to
+ If you want to uninstall the preview and revert the device to factory specifications, go to
<a href="http://developers.google.com/android/nexus/images">developers.google.com/android</a> and
download the image you want to flash to for your device. Follow the instructions on that page to
flash the image to your device.
@@ -330,15 +330,18 @@ This is the Android SDK Preview License Agreement (the “License Agreement”).
function onDownloadForRealz(link) {
if ($("input#agree").is(':checked')) {
+ /*
$("#tos").fadeOut('fast');
$("#landing").fadeIn('fast');
+ */
+
ga('send', 'event', 'M Preview', 'System Image', $("#downloadForRealz").html());
+
+ /*
location.hash = "";
+ */
return true;
} else {
- $("label#agreeLabel").parent().stop().animate({color: "#258AAF"}, 200,
- function() {$("label#agreeLabel").parent().stop().animate({color: "#222"}, 200)}
- );
return false;
}
}
diff --git a/docs/html/preview/features/app-linking.jd b/docs/html/preview/features/app-linking.jd
index ffca1a9..5592323 100644
--- a/docs/html/preview/features/app-linking.jd
+++ b/docs/html/preview/features/app-linking.jd
@@ -1,8 +1,8 @@
page.title=App Links
-
+page.image=images/cards/card-app-linking_2x.png
+page.keywords=applinking, deeplinks, intents
@jd:body
-
<div id="qv-wrapper">
<div id="qv">
<h2>In this document</h2>
diff --git a/docs/html/preview/index.jd b/docs/html/preview/index.jd
index 4ea5b4a..eb18aa6 100644
--- a/docs/html/preview/index.jd
+++ b/docs/html/preview/index.jd
@@ -1,6 +1,6 @@
page.title=Android M Developer Preview
page.tags="preview",
-meta.tags="preview, M preview"
+meta.tags="preview, M preview", androidm
fullpage=true
section.landing=true
header.hide=1
@@ -44,24 +44,25 @@ footer.hide=1
<div class="dac-section-subtitle">
Essential information to help you get your apps ready for Android M.
</div>
+
<div class="resource-widget resource-flow-layout col-16"
- data-query="tag:previewresources"
+ data-query="collection:preview/landing/more"
data-cardSizes="6x6"
- data-initial-results="6"
data-maxResults="16"></div>
- <ul class="dac-section-links">
- <li class="dac-section-link"><a href="http://g.co/dev/AndroidMDevPreview">
- <span class="dac-sprite dac-auto-chevron"></span>
- Join G+ Community
- </a></li>
-
- <li class="dac-section-link">
- <a href="https://code.google.com/p/android-developer-preview/">
+ <ul class="dac-section-links">
+ <li class="dac-section-link">
+ <a href="https://code.google.com/p/android-developer-preview/">
+ <span class="dac-sprite dac-auto-chevron"></span>
+ Report Issues
+ </a>
+ </li>
+ <li class="dac-section-link"><a href="http://g.co/dev/AndroidMDevPreview">
<span class="dac-sprite dac-auto-chevron"></span>
- Report Issues
- </a>
- </li>
- </ul>
-</div></section>
+ Join G+ Community
+ </a>
+ </li>
+ </ul>
+ </div>
+</section>
diff --git a/docs/html/preview/overview.jd b/docs/html/preview/overview.jd
index 1b8643e..d6bafb1 100644
--- a/docs/html/preview/overview.jd
+++ b/docs/html/preview/overview.jd
@@ -118,7 +118,7 @@ page.tags="preview", "developer", "android"
<p>
The M Developer Preview runs from May 27 until the final Android M SDK, which
we’ll release shortly before the public release during Q3
- 2015.
+ 2015.
</p>
<p>
@@ -204,7 +204,7 @@ page.tags="preview", "developer", "android"
<p>
You can download these hardware system images for Nexus devices from the
- <a href="downloads.html">Downloads page</a>:
+ <a href="download.html">Downloads page</a>:
</p>
<ul>
@@ -240,24 +240,25 @@ page.tags="preview", "developer", "android"
</li>
<li>
- <a href="testing.html">Testing Guide</a> and <a href=
- "api-changes.html">Behavior Changes</a> point you to key areas to test.
+ <a href="{@docRoot}preview/testing/guide.html">Testing Guide</a> and <a href=
+ "behavior-changes.html">Behavior Changes</a> point you to key areas to test.
</li>
<li>Documentation of new APIs, including an <a href="api-overview.html">API Overview</a>,
- downloadable <a href="">API Reference</a>, and detailed developer guides on
- key features such as <a href="">permissions</a>, <a href="">app backup</a>,
- and others.
+ downloadable <a href="{@docRoot}preview/download.html#docs">API Reference</a>, and detailed developer guides on
+ key features such as
+ <a href="{@docRoot}preview/features/runtime-permissions.html">permissions</a>,
+ <a href="{@docRoot}preview/backup/index.html">app backup</a>, and others.
</li>
<li>
- <a href="">Sample code</a> that demonstrates how to support
+ <a href="{@docRoot}preview/samples.html">Sample code</a> that demonstrates how to support
permissions and other new features.
</li>
<li>
- <a href="">Release notes</a> for the current version of the M Developer
- Preview, including change notes and diff reports.
+ <a href="{@docRoot}preview/support.html#release-notes">Release notes</a> for the current version
+ of the M Developer Preview, including change notes and diff reports.
</li>
</ul>
@@ -334,7 +335,7 @@ page.tags="preview", "developer", "android"
<ol>
<li>Review the <a href="{@docRoot}preview/api-overview.html">API Overview</a>
- and <a href="{@docRoot}preview/behavior.html">Behavior Changes</a> to get an
+ and <a href="{@docRoot}preview/behavior-changes.html">Behavior Changes</a> to get an
idea of what's new and how it affects your apps.
</li>
@@ -349,7 +350,7 @@ page.tags="preview", "developer", "android"
Preview updates will be delivered through over-the-air (OTA) updates.</a>
</li>
- <li>Download the <a href="{@docRoot}preview/reference.html">M Preview API
+ <li>Download the <a href="{@docRoot}preview/download.html#docs">M Preview API
Reference</a> and <a href="{@docRoot}preview/samples.html">M Preview
samples</a> to gain more insight into new API features and how to use them in
your app.
diff --git a/docs/html/preview/preview_toc.cs b/docs/html/preview/preview_toc.cs
index 07afcdd..d0aa55f 100644
--- a/docs/html/preview/preview_toc.cs
+++ b/docs/html/preview/preview_toc.cs
@@ -33,7 +33,7 @@
<li><a href="<?cs var:toroot ?>preview/features/app-linking.html">
App Links</a></li>
<li><a href="<?cs var:toroot ?>preview/backup/index.html">
- Automatic Backups</a></li>
+ Auto Backup for Apps</a></li>
</ul>
</li>
diff --git a/docs/html/preview/samples.jd b/docs/html/preview/samples.jd
index 3974ee3..7d47e0e 100644
--- a/docs/html/preview/samples.jd
+++ b/docs/html/preview/samples.jd
@@ -7,7 +7,6 @@ page.image=images/cards/samples-new_2x.png
the samples in Android Studio, select the <b>File > Import Samples</b> menu option.
</p>
-<img src="{@docRoot}images/cards/card-google-cloud-messaging_16-9_2x" class="figure">
<p class="note">
<strong>Note:</strong> These downloadable projects are designed
for use with Gradle and Android Studio.
diff --git a/docs/html/preview/setup-sdk.jd b/docs/html/preview/setup-sdk.jd
index 016967d..1616053 100644
--- a/docs/html/preview/setup-sdk.jd
+++ b/docs/html/preview/setup-sdk.jd
@@ -116,7 +116,7 @@ of Android Studio to use for testing.</p>
<h3 id="create">Create a new project</h3>
<p>
- We recommend using Android Studio for create a project with the preview. Follow the steps
+ We recommend using Android Studio to create a project with the preview. Follow the steps
described in <a href="{@docRoot}sdk/installing/create-project.html">Creating a Project</a>
until you arrive at the <em>Form Factors</em> screen in the project wizard. Then perform
the following steps to create a project configured for the preview.
@@ -132,7 +132,7 @@ of Android Studio to use for testing.</p>
<p>
For existing projects, you must modify the project configuration to enable the preview APIs. In
- your the development environment, open the <code>build.gradle</code> file for your module and
+ your development environment, open the <code>build.gradle</code> file for your module and
set these values as follows:
</p>
@@ -146,7 +146,7 @@ of Android Studio to use for testing.</p>
<h2 id="setup-test">Set Up for Testing</h2>
<p>
- Testing app with the preview requires that you have a device or virtual device configured with
+ Testing an app with the preview requires that you have a device or virtual device configured with
the preview version of the platform. If you have a compatible device, you can install the preview
platform for testing. Otherwise, you can configure a virtual device for testing.
</p>
@@ -156,7 +156,7 @@ of Android Studio to use for testing.</p>
<p>
If you have a Nexus 5, Nexus 6, Nexus 9, or Android TV, you can install a preview
system image on these devices for testing your app.
- You can set up virtual device with the preview version of the platform from within Android Studio
+ You can set up a virtual device with the preview version of the platform from within Android Studio
using the Android Virtual Device Manager tool.
</p>
diff --git a/docs/html/preview/testing/guide.jd b/docs/html/preview/testing/guide.jd
index 317dc44..07a25a2 100644
--- a/docs/html/preview/testing/guide.jd
+++ b/docs/html/preview/testing/guide.jd
@@ -1,5 +1,6 @@
page.title=Testing Guide
-page.image=images/cards/card-set-up_16-9_2x.png
+page.image=images/cards/card-build_16x9_2x.png
+page.keywords=previewresources,androidm,testing,permissions
@jd:body
@@ -18,7 +19,7 @@ page.image=images/cards/card-set-up_16-9_2x.png
The Android M Developer Preview gives you an opportunity to ensure your apps work with the next
version of the platform. This preview includes a number of APIs and behavior changes that can
impact your app, as described in the <a href="{@docRoot}preview/api-overview.html">API
- Overview</a> and <a href="{@docRoot}preview/api-changes.html">Behavior Changes</a>. In testing
+ Overview</a> and <a href="{@docRoot}preview/behavior-changes.html">Behavior Changes</a>. In testing
your app with the preview, there are some specific system changes that you should focus on to
ensure that users have a good experience.
</p>
@@ -32,7 +33,7 @@ page.image=images/cards/card-set-up_16-9_2x.png
<ul>
<li><a href="#runtime-permissions">Permissions</a>
</li>
- <li><a href="#doze-mode">Doze and App Standby</a>
+ <li><a href="#doze-standby">Doze and App Standby</a>
</li>
<li><a href="#ids">Auto Backup and Device Identifiers</a></li>
</ul>
@@ -57,7 +58,7 @@ page.image=images/cards/card-set-up_16-9_2x.png
</p>
<p>
- This change that affects all apps running on the new platform, even those not targeting the new
+ This change affects all apps running on the new platform, even those not targeting the new
platform version. The platform provides a limited compatibility behavior for legacy apps, but you
should begin planning your app’s migration to the new permissions model now, with a goal of
publishing an updated version of your app at the official platform launch.
@@ -123,7 +124,7 @@ page.image=images/cards/card-set-up_16-9_2x.png
<h2 id="doze-standby">Testing Doze and App Standby</h2>
<p>
- The power saving features of Doze and App Standby limits the amount of background processing that
+ The power saving features of Doze and App Standby limit the amount of background processing that
your app can perform when a device is in an idle state or while your app is not in focus. The
restrictions the system may impose on apps include limited or no network access,
suspended background tasks, suspended Notifications, ignored wake requests, and alarms. To ensure
@@ -182,4 +183,5 @@ $ adb shell am set-idle &lt;packageName&gt; true
<p>If your app is persisting any device-specific identifiers, such as Google
Cloud Messaging registration ID, in internal storage,
make sure to follow best practices to exclude the storage
-location from auto-backup, as described in <a href="">Auto Backup for Apps</a>. </p>
+location from auto-backup, as described in <a href="{@docRoot}preview/backup/index.html">Auto
+Backup for Apps</a>. </p>
diff --git a/docs/html/preview/testing/performance.jd b/docs/html/preview/testing/performance.jd
index a61091f..003b619 100644
--- a/docs/html/preview/testing/performance.jd
+++ b/docs/html/preview/testing/performance.jd
@@ -1,4 +1,6 @@
page.title=Testing Display Performance
+page.image=images/cards/card-test-performance_2x.png
+page.keywords=performance, fps, tools
@jd:body
@@ -552,10 +554,10 @@ Number Slow draw: 23342
</h4>
<p>
- Tool suites like <a href=
- "https://developer.android.com/tools/testing-support-library/index.html">UIAutomator</a>,
- and <a href="https://code.google.com/p/android-test-kit/">Espresso</a> are built to help
- automate the action of a user moving through your application. These are simple
+ Tool suites, like <a href=
+ "{@docRoot}training/testing/ui-testing/uiautomator-testing.html">UI Automator</a> and
+ <a href="{@docRoot}training/testing/ui-testing/espresso-testing.html">Espresso</a>, are
+ built to help automate the action of a user moving through your application. These are simple
frameworks which mimic user interaction with your device. To use these frameworks, you
effectively create unique scripts, which run through a set of user-actions, and play them
out on the device itself.
@@ -583,7 +585,7 @@ Number Slow draw: 23342
<p>
It’s worth noting that UI testing frameworks (like <a href=
- "https://developer.android.com/tools/testing-support-library/index.html">UIAutomator</a>)
+ "{@docRoot}training/testing/ui-testing/uiautomator-testing.html">UI Automator</a>)
run on the target device/emulator directly. While performance gathering information done
by <em>dumpsys gfxinfo</em> is driven by a host machine, sending commands over ADB. To
help bridge the automation of these separate entities, <a href=
@@ -593,7 +595,7 @@ Number Slow draw: 23342
</p>
<p>
- Building a set of scripts for proper Automation of UI Performance testing, at a minimum,
+ Building a set of scripts for proper automation of UI Performance testing, at a minimum,
should be able to utilize monkeyRunner to accomplish the following tasks:
</p>
@@ -601,7 +603,7 @@ Number Slow draw: 23342
<li>Load &amp; Launch a desired APK to a target device, devices, or emulator.
</li>
- <li>Launch a UIAutomator UI test, and allow it to be executed
+ <li>Launch a UI Automator UI test, and allow it to be executed
</li>
<li>Collect performance information through <em>dumpsys gfxinfo</em><em>.</em>
diff --git a/docs/html/tools/data-binding/guide.jd b/docs/html/tools/data-binding/guide.jd
index 6a933d8..71409e4 100644
--- a/docs/html/tools/data-binding/guide.jd
+++ b/docs/html/tools/data-binding/guide.jd
@@ -26,16 +26,16 @@ tracker</a>. Stay tuned for more information about Data Binding and examples of
<a href="#data_binding_layout_files">Data Binding Layout Files</a>
<ol>
<li>
- <a href="writing_expressions">Writing your first data binding
+ <a href="#writing_expressions">Writing your first data binding
expressions</a>
</li>
<li>
- <a href="data_object">Data Object</a>
+ <a href="#data_object">Data Object</a>
</li>
<li>
- <a href="binding_data">Binding Data</a>
+ <a href="#binding_data">Binding Data</a>
</li>
</ol>
</li>
@@ -44,23 +44,23 @@ tracker</a>. Stay tuned for more information about Data Binding and examples of
<a href="#layout_details">Layout Details</a>
<ol>
<li>
- <a href="imports">Imports</a>
+ <a href="#imports">Imports</a>
</li>
<li>
- <a href="variables">Variables</a>
+ <a href="#variables">Variables</a>
</li>
<li>
- <a href="custom_binding_class_names">Custom Binding Class Names</a>
+ <a href="#custom_binding_class_names">Custom Binding Class Names</a>
</li>
<li>
- <a href="includes">Includes</a>
+ <a href="#includes">Includes</a>
</li>
<li>
- <a href="expression_language">Expression Language</a>
+ <a href="#expression_language">Expression Language</a>
</li>
</ol>
</li>
@@ -69,15 +69,15 @@ tracker</a>. Stay tuned for more information about Data Binding and examples of
<a href="#data_objects">Data Objects</a>
<ol>
<li>
- <a href="observable_objects">Observable Objects</a>
+ <a href="#observable_objects">Observable Objects</a>
</li>
<li>
- <a href="observablefields">ObservableFields</a>
+ <a href="#observablefields">ObservableFields</a>
</li>
<li>
- <a href="observable_collections">Observable Collections</a>
+ <a href="#observable_collections">Observable Collections</a>
</li>
</ol>
</li>
@@ -86,23 +86,23 @@ tracker</a>. Stay tuned for more information about Data Binding and examples of
<a href="#generated_binding">Generated Binding</a>
<ol>
<li>
- <a href="creating">Creating</a>
+ <a href="#creating">Creating</a>
</li>
<li>
- <a href="views_with_ids">Views With IDs</a>
+ <a href="#views_with_ids">Views With IDs</a>
</li>
<li>
- <a href="variables">Variables</a>
+ <a href="#variables">Variables</a>
</li>
<li>
- <a href="viewstubs">ViewStubs</a>
+ <a href="#viewstubs">ViewStubs</a>
</li>
<li>
- <a href="advanced_binding">Advanced Binding</a>
+ <a href="#advanced_binding">Advanced Binding</a>
</li>
</ol>
</li>
@@ -111,15 +111,15 @@ tracker</a>. Stay tuned for more information about Data Binding and examples of
<a href="#attribute_setters">Attribute Setters</a>
<ol>
<li>
- <a href="automatic_setters">Automatic Setters</a>
+ <a href="#automatic_setters">Automatic Setters</a>
</li>
<li>
- <a href="renamed_setters">Renamed Setters</a>
+ <a href="#renamed_setters">Renamed Setters</a>
</li>
<li>
- <a href="custom_setters">Custom Setters</a>
+ <a href="#custom_setters">Custom Setters</a>
</li>
</ol>
</li>
@@ -128,11 +128,11 @@ tracker</a>. Stay tuned for more information about Data Binding and examples of
<a href="#converters">Converters</a>
<ol>
<li>
- <a href="object_conversions">Object Conversions</a>
+ <a href="#object_conversions">Object Conversions</a>
</li>
<li>
- <a href="custom_conversions">Custom Conversions</a>
+ <a href="#custom_conversions">Custom Conversions</a>
</li>
</ol>
</li>
diff --git a/docs/html/tools/data-binding/index.jd b/docs/html/tools/data-binding/index.jd
deleted file mode 100644
index 4ad11b6..0000000
--- a/docs/html/tools/data-binding/index.jd
+++ /dev/null
@@ -1,18 +0,0 @@
-page.title=Android Data Binding Library
-page.metaDescription=
-
-@jd:body
-
-<p>
- Some text here.
-</p>
-
-
-
-<!-- <h2>Related Resources</h2>
- <div class="resource-widget resource-flow-layout col-16"
- data-query="tag:engagement"
- data-sortOrder="random"
- data-cardSizes="6x2"
- data-maxResults="3">
- </div> -->
diff --git a/docs/html/training/training_toc.cs b/docs/html/training/training_toc.cs
index 535a87e..0baef14 100644
--- a/docs/html/training/training_toc.cs
+++ b/docs/html/training/training_toc.cs
@@ -1654,6 +1654,14 @@ results."
</ul>
</li> <!-- end of Background Jobs -->
+ <li class="nav-section">
+ <div class="nav-section-header">
+ <a href="<?cs var:toroot ?>training/best-performance.html">
+ <span class="small">Best Practices for</span><br/>
+ Performance
+ </a>
+ </div>
+ <ul>
<li>
<a href="<?cs var:toroot ?>training/articles/memory.html"
description=
@@ -1661,7 +1669,6 @@ results."
on a variety of mobile devices."
>Managing Your App's Memory</a>
</li>
-
<li>
<a href="<?cs var:toroot ?>training/articles/perf-tips.html"
description=
@@ -1669,7 +1676,6 @@ results."
responsiveness and battery efficiency."
>Performance Tips</a>
</li>
-
<li class="nav-section">
<div class="nav-section-header">
<a href="<?cs var:toroot ?>training/improving-layouts/index.html"
@@ -1697,7 +1703,6 @@ results."
</li>
</ul>
</li>
-
<li class="nav-section">
<div class="nav-section-header">
<a href="<?cs var:toroot ?>training/monitoring-device-state/index.html"
@@ -1707,7 +1712,8 @@ results."
description=
"How to minimize the amount of power your app requires by adapting to current
power conditions and performing power-hungry tasks at proper intervals."
- >Optimizing Battery Life</a>
+ >Optimizing Battery Life
+ </a>
</div>
<ul>
<li><a href="<?cs var:toroot ?>training/monitoring-device-state/battery-monitoring.html"
@@ -1763,7 +1769,6 @@ results."
</li>
</ul>
</li>
-
<li>
<a href="<?cs var:toroot ?>training/articles/perf-anr.html"
description=
@@ -1771,7 +1776,6 @@ results."
display an &quot;Application Not Responding&quot; dialog."
>Keeping Your App Responsive</a>
</li>
-
<li>
<a href="<?cs var:toroot ?>training/articles/perf-jni.html"
description=
@@ -1787,8 +1791,6 @@ results."
</ul>
</li> <!-- end of Performance -->
-
-
<li class="nav-section">
<div class="nav-section-header">
<a href="<?cs var:toroot ?>training/best-security.html">
diff --git a/docs/html/training/tv/index.jd b/docs/html/training/tv/index.jd
index d52e1e8..ff9f111 100644
--- a/docs/html/training/tv/index.jd
+++ b/docs/html/training/tv/index.jd
@@ -8,4 +8,5 @@ page.image=design/tv/images/focus.png
<p>These classes teach you how to build apps for TV devices.</p>
-<p class="note"><strong>Note:</strong> For details on how to publish your TV apps in Google Play, see <a href="{docRoot}distribute/googleplay/tv.html">Distributing to Android TV</a>.</p> \ No newline at end of file
+<p class="note"><strong>Note:</strong> For details on how to publish your TV apps in Google Play,
+see <a href="{@docRoot}distribute/googleplay/tv.html">Distribute to Android TV</a>.</p> \ No newline at end of file