summaryrefslogtreecommitdiffstats
path: root/docs
diff options
context:
space:
mode:
authorRicardo Cervera <rcervera@google.com>2014-07-09 18:34:15 +0000
committerAndroid (Google) Code Review <android-gerrit@google.com>2014-07-09 14:50:26 +0000
commite34167cef73e23c4be4bf5d7a1517e609122d652 (patch)
tree41cfbb4bcc16e87511f14d08a9074e02a288a840 /docs
parent3a958b9f851a8985bed5fac1499c5553ff566b9e (diff)
parent4adf1e069b4c71861010978db008858c7d898751 (diff)
downloadframeworks_base-e34167cef73e23c4be4bf5d7a1517e609122d652.zip
frameworks_base-e34167cef73e23c4be4bf5d7a1517e609122d652.tar.gz
frameworks_base-e34167cef73e23c4be4bf5d7a1517e609122d652.tar.bz2
Merge "docs: Fixed minor issues with Wear docs. Bug: 16062631" into klp-modular-dev
Diffstat (limited to 'docs')
-rw-r--r--docs/html/training/wearables/apps/creating.jd8
-rw-r--r--docs/html/training/wearables/data-layer/accessing.jd12
2 files changed, 17 insertions, 3 deletions
diff --git a/docs/html/training/wearables/apps/creating.jd b/docs/html/training/wearables/apps/creating.jd
index f6b96e2..fa4913f 100644
--- a/docs/html/training/wearables/apps/creating.jd
+++ b/docs/html/training/wearables/apps/creating.jd
@@ -89,10 +89,16 @@ types of screen shapes, which is useful for testing.</p>
<li>Install the Android Wear app, available on Google Play, on your handheld.</li>
<li>Follow the app's instructions to pair your handheld with your wearable.
This allows you to test out synced handheld notifications, if you're building them.</li>
+ <li>Leave the Android Wear app open on your phone.</li>
<li>Connect the wearable to your machine through USB, so you can install apps directly to it
- as you develop.</li>
+ as you develop. A message appears on both the wearable and the Android Wear app prompting you to allow debugging.</li>
+ <li>On the Android Wear app, check <strong>Always allow from this computer</strong> and tap
+ <strong>OK</strong>.</li>
</ol>
+<p>The <strong>Android</strong> tool window on Android Studio shows the system log from the wearable.
+The wearable should also be listed when you run the <code>adb devices</code> command.</p>
+
<h2 id="CreateProject">Create a Project</h2>
<p>To begin development, create an app project that contains
diff --git a/docs/html/training/wearables/data-layer/accessing.jd b/docs/html/training/wearables/data-layer/accessing.jd
index 4babd0a..896a698 100644
--- a/docs/html/training/wearables/data-layer/accessing.jd
+++ b/docs/html/training/wearables/data-layer/accessing.jd
@@ -33,7 +33,7 @@ A minimal <a href="{@docRoot}reference/com/google/android/gms/common/api/GoogleA
<p class="note"><b>Note:</b> For now, this minimal client is enough to get started. However, see
<a href="{@docRoot}google/auth/api-client.html">Accessing Google Play services APIs</a>
-for more information about creating a<a href="{@docRoot}reference/com/google/android/gms/common/api/GoogleApiClient.html"><code>GoogleApiClient</code></a>,
+for more information about creating a <a href="{@docRoot}reference/com/google/android/gms/common/api/GoogleApiClient.html"><code>GoogleApiClient</code></a>,
implementing its callbacks, and handling error cases.</p>
<pre style="clear:right">
@@ -42,6 +42,7 @@ GoogleApiClient mGoogleAppiClient = new GoogleApiClient.Builder(this)
&#64;Override
public void onConnected(Bundle connectionHint) {
Log.d(TAG, "onConnected: " + connectionHint);
+ // Now you can use the data layer API
}
&#64;Override
public void onConnectionSuspended(int cause) {
@@ -56,4 +57,11 @@ GoogleApiClient mGoogleAppiClient = new GoogleApiClient.Builder(this)
})
.addApi(Wearable.API)
.build();
-</pre> \ No newline at end of file
+</pre>
+
+<p>Before you use the data layer API, start a connection on your client by calling the
+<a href="{@docRoot}reference/com/google/android/gms/common/api/GoogleApiClient.html#connect()">connect()</a>
+method, as described in
+<a href="{@docRoot}google/auth/api-client.html#Starting">Accessing Google Play services APIs</a>.
+When the system invokes the <code>onConnected()</code> callback for your client, you're ready
+to use the data layer API.</p> \ No newline at end of file