Skip to content

Commit 6958c16

Browse files
scottamainAndroid (Google) Code Review
authored andcommitted
Merge "docs: misc bug fixes from external issues" into jb-dev
2 parents 116748d + 183bf11 commit 6958c16

File tree

8 files changed

+20
-16
lines changed

8 files changed

+20
-16
lines changed

core/java/android/app/Notification.java

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -897,12 +897,16 @@ public String toString() {
897897
* Builder class for {@link Notification} objects.
898898
*
899899
* Provides a convenient way to set the various fields of a {@link Notification} and generate
900-
* content views using the platform's notification layout template.
900+
* content views using the platform's notification layout template. If your app supports
901+
* versions of Android as old as API level 4, you can instead use
902+
* {@link android.support.v4.app.NotificationCompat.Builder NotificationCompat.Builder},
903+
* available in the <a href="{@docRoot}tools/extras/support-library.html">Android Support
904+
* library</a>.
901905
*
902-
* Example:
906+
* <p>Example:
903907
*
904908
* <pre class="prettyprint">
905-
* Notification noti = new Notification.Builder()
909+
* Notification noti = new Notification.Builder(mContext)
906910
* .setContentTitle(&quot;New mail from &quot; + sender.toString())
907911
* .setContentText(subject)
908912
* .setSmallIcon(R.drawable.new_mail)

core/java/android/content/res/Resources.java

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1120,8 +1120,8 @@ public void setTo(Theme other) {
11201120
* Return a StyledAttributes holding the values defined by
11211121
* <var>Theme</var> which are listed in <var>attrs</var>.
11221122
*
1123-
* <p>Be sure to call StyledAttributes.recycle() when you are done with
1124-
* the array.
1123+
* <p>Be sure to call {@link TypedArray#recycle() TypedArray.recycle()} when you are done
1124+
* with the array.
11251125
*
11261126
* @param attrs The desired attributes.
11271127
*
@@ -1148,8 +1148,8 @@ public TypedArray obtainStyledAttributes(int[] attrs) {
11481148
* Return a StyledAttributes holding the values defined by the style
11491149
* resource <var>resid</var> which are listed in <var>attrs</var>.
11501150
*
1151-
* <p>Be sure to call StyledAttributes.recycle() when you are done with
1152-
* the array.
1151+
* <p>Be sure to call {@link TypedArray#recycle() TypedArray.recycle()} when you are done
1152+
* with the array.
11531153
*
11541154
* @param resid The desired style resource.
11551155
* @param attrs The desired attributes in the style.
@@ -1208,8 +1208,8 @@ public TypedArray obtainStyledAttributes(int resid, int[] attrs)
12081208
* AttributeSet specifies a style class (through the "style" attribute),
12091209
* that style will be applied on top of the base attributes it defines.
12101210
*
1211-
* <p>Be sure to call StyledAttributes.recycle() when you are done with
1212-
* the array.
1211+
* <p>Be sure to call {@link TypedArray#recycle() TypedArray.recycle()} when you are done
1212+
* with the array.
12131213
*
12141214
* <p>When determining the final value of a particular attribute, there
12151215
* are four inputs that come into play:</p>

core/java/android/content/res/TypedArray.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -684,7 +684,7 @@ public String getPositionDescription() {
684684
}
685685

686686
/**
687-
* Give back a previously retrieved StyledAttributes, for later re-use.
687+
* Give back a previously retrieved array, for later re-use.
688688
*/
689689
public void recycle() {
690690
synchronized (mResources.mTmpValue) {

docs/html/guide/topics/media/camera.jd

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -617,7 +617,7 @@ public class CameraActivity extends Activity {
617617

618618
// Create our Preview view and set it as the content of our activity.
619619
mPreview = new CameraPreview(this, mCamera);
620-
FrameLayout preview = (FrameLayout) findViewById(id.camera_preview);
620+
FrameLayout preview = (FrameLayout) findViewById(R.id.camera_preview);
621621
preview.addView(mPreview);
622622
}
623623
}

docs/html/guide/topics/ui/controls/radiobutton.jd

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ click event for both radio buttons:</p>
7272
<pre>
7373
public void onRadioButtonClicked(View view) {
7474
// Is the button now checked?
75-
boolean checked = (RadioButton) view).isChecked();
75+
boolean checked = ((RadioButton) view).isChecked();
7676

7777
// Check which radio button was clicked
7878
switch(view.getId()) {

docs/html/guide/topics/ui/settings.jd

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -217,7 +217,7 @@ item in the list of settings.</p>
217217
android:dialogTitle="@string/pref_syncConnectionType"
218218
android:entries="@array/pref_syncConnectionTypes_entries"
219219
android:entryValues="@array/pref_syncConnectionTypes_values"
220-
android:defaultValue="@string/pref_syncConnectionTypes_default" >
220+
android:defaultValue="@string/pref_syncConnectionTypes_default" />
221221
&lt;/PreferenceScreen>
222222
</pre>
223223

docs/html/training/basics/activity-lifecycle/starting.jd

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ methods.</p>
112112
</table>
113113
-->
114114

115-
<p>As you'll learn in the following lessons, there are several situtations in which an activity
115+
<p>As you'll learn in the following lessons, there are several situations in which an activity
116116
transitions between different states that are illustrated in figure 1. However, only three of
117117
these states can be static. That is, the activity can exist in one of only three states for an
118118
extended period of time:</p>

docs/html/training/basics/firstapp/starting-activity.jd

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -285,8 +285,8 @@ href="{@docRoot}tools/extras/support-library.html#SettingUp">setting up the Supp
285285

286286
<p>The app is now runnable because the {@link android.content.Intent} in the
287287
first activity now resolves to the {@code DisplayMessageActivity} class. If you run the app now,
288-
clicking the Send button starts the
289-
second activity, but it doesn't show anything yet.</p>
288+
clicking the Send button starts the second activity, but it's still using the default
289+
"Hello world" layout.</p>
290290

291291

292292
<h2 id="ReceiveIntent">Receive the Intent</h2>

0 commit comments

Comments
 (0)