Skip to content

Commit 321e030

Browse files
author
Ricardo Cervera
committed
docs: Fix Wear docs issues.
Bug: 16624918 Bug: 16626217 Bug: 16626415 Bug: 16624384 Bug: 16623147 Change-Id: I774f19aded22562b891f9d2ccc35f0befb50f21c
1 parent 7af4e81 commit 321e030

File tree

5 files changed

+17
-9
lines changed

5 files changed

+17
-9
lines changed

docs/html/training/wearables/apps/creating.jd

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ Project</a>. As you follow the wizard, enter the following information:</p>
112112
name.</li>
113113
<li>In the <b>Form Factors</b> window:
114114
<ul>
115-
<li>Select <b>Phone and Tablet</b> and select <b>API 8: Android 2.2 (Froyo)</b>
115+
<li>Select <b>Phone and Tablet</b> and select <b>API 9: Android 2.3 (Gingerbread)</b>
116116
under <b>Minimum SDK</b>.</li>
117117
<li>Select <b>Wear</b> and select <b>API 20: Android 4.4 (KitKat Wear)</b>
118118
under <b>Minimum SDK</b>.</li>

docs/html/training/wearables/apps/voice.jd

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ named <code>MyNoteActivity</code>:
119119
<td>
120120
<dl>
121121
<dt>Action</dt>
122-
<dd><code>android.provider.AlarmClock.ACTION_SET_TIMER</code></dd>
122+
<dd><code>android.intent.action.SET_TIMER</code></dd>
123123
<dt>Extras</dt>
124124
<dd><code>android.provider.AlarmClock.EXTRA_LENGTH</code> - an integer in the range of
125125
1 to 86400 (number of seconds in 24 hours) representing the length of the timer </dd>
@@ -244,7 +244,7 @@ from users and then process it, such as doing a search or sending it as a messag
244244

245245
In your app, you call {@link android.app.Activity#startActivityForResult startActivityForResult()} using
246246
the {@link android.speech.RecognizerIntent#ACTION_RECOGNIZE_SPEECH} action. This starts the
247-
and then handle the result
247+
speech recognition activity, and you can then handle the result
248248
in {@link android.app.Activity#onActivityResult onActivityResult()}.
249249
<pre>
250250
private static final int SPEECH_REQUEST_CODE = 0;

docs/html/training/wearables/data-layer/events.jd

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -102,12 +102,12 @@ so the handheld app doesn't listen for any data events from the wearable app.</p
102102
<ul>
103103
<li><a href="{@docRoot}reference/com/google/android/gms/wearable/WearableListenerService.html#onDataChanged(com.google.android.gms.wearable.DataEventBuffer)"><code>onDataChanged()</code></a>
104104
- Called when data item objects are created, changed, or deleted. An event on one side of a connection
105-
triggers an this callback on both sides.</li>
105+
triggers this callback on both sides.</li>
106106
<li><a href="{@docRoot}reference/com/google/android/gms/wearable/WearableListenerService.html#onMessageReceived(com.google.android.gms.wearable.MessageEvent)"><code>onMessageReceived()</code></a>
107107
- A message sent from one side of a connection triggers this callback on the other side of the connection.</li>
108108
<li><a href="{@docRoot}reference/com/google/android/gms/wearable/WearableListenerService.html#onMessageReceived(com.google.android.gms.wearable.MessageEvent)"><code>onPeerConnected()</code></a>
109109
and <a href="{@docRoot}reference/com/google/android/gms/wearable/WearableListenerService.html#onPeerDisconnected(com.google.android.gms.wearable.Node)"><code>onPeerDisconnected()</code></a> -
110-
Called when connection with the handheld or wearable is connected or disconnected.
110+
Called when connection with the handheld or wearable is connected or disconnected.
111111
Changes in connection state on one side of the connection triggers these callbacks on both sides of the connection.
112112
</li>
113113
</ul>
@@ -174,7 +174,7 @@ public class DataLayerListenerService extends WearableListenerService {
174174
}
175175
}
176176
}
177-
</pre>
177+
</pre>
178178

179179
<p>Here's the corresponding intent filter in the Android manifest file:</p>
180180

docs/html/training/wearables/data-layer/messages.jd

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,5 +95,5 @@ public void onMessageReceived(MessageEvent messageEvent) {
9595
<p>
9696
This is just a snippet that requires more implementation details. Learn about
9797
how to implement a full listener service or activity in
98-
<a href="#listening">Listening for Data Layer Events</a>.
98+
<a href="{@docRoot}training/wearables/data-layer/events.html">Listening for Data Layer Events</a>.
9999
</p>

docs/html/training/wearables/notifications/creating.jd

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,15 @@ that use custom card layouts by creating a wearable app that runs on the wearabl
3333
</div>
3434

3535
<h2 id="Import">Import the necessary classes</h2>
36-
<p>Before you begin, import the necessary classes from the support library:</p>
36+
37+
<p>To import the necessary packages, add this line to your <code>build.gradle</code>file:</p>
38+
39+
<pre>
40+
compile "com.android.support:support-v4:20.0.+"
41+
</pre>
42+
43+
<p>Now that your project has access to the necessary packages, import the necessary classes from
44+
the support library:</p>
3745

3846
<pre style="clear:right">
3947
import android.support.v4.app.NotificationCompat;
@@ -190,7 +198,7 @@ bigStyle.bigText(eventDescription);
190198
NotificationCompat.Builder notificationBuilder =
191199
new NotificationCompat.Builder(this)
192200
.setSmallIcon(R.drawable.ic_event)
193-
.setLargeIcon(BitmapFractory.decodeResource(
201+
.setLargeIcon(BitmapFactory.decodeResource(
194202
getResources(), R.drawable.notif_background))
195203
.setContentTitle(eventTitle)
196204
.setContentText(eventLocation)

0 commit comments

Comments
 (0)