Skip to content

Commit 40a0376

Browse files
committed
docs: remove unused id attribute from Button
Change-Id: Ia61c418972699d40757923fd69ea27b26eddaa05
1 parent b0efc7f commit 40a0376

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

docs/html/training/basics/firstapp/building-ui.jd

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -262,7 +262,9 @@ class.</p>
262262
</pre>
263263

264264
<p>The height and width are set to <code>"wrap_content"</code> so the button is only as big as
265-
necessary to fit the button's text.</p>
265+
necessary to fit the button's text. This button doesn't need the
266+
<a href="{@docRoot}reference/android/view/View.html#attr_android:id">{@code android:id}</a>
267+
attribute, because it won't be referenced from the activity code.</p>
266268

267269

268270

@@ -337,7 +339,7 @@ android.widget.LinearLayout}.</p>
337339
android:layout_width="0dp"
338340
android:layout_height="wrap_content"
339341
android:hint="@string/edit_message" />
340-
&lt;Button android:id="@+id/button_send"
342+
&lt;Button
341343
android:layout_width="wrap_content"
342344
android:layout_height="wrap_content"
343345
android:text="@string/button_send" />

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ href="{@docRoot}reference/android/view/View.html#attr_android:onClick">{@code an
5555
attribute to the {@link android.widget.Button &lt;Button>} element:</p>
5656

5757
<pre>
58-
&lt;Button android:id="@+id/button_send"
58+
&lt;Button
5959
android:layout_width="wrap_content"
6060
android:layout_height="wrap_content"
6161
android:text="@string/button_send"

0 commit comments

Comments
 (0)