Merge commit '70c9ffbc838271f0ea27a4780eb146287de53ef6' into gingerbread-plus-aosp * commit '70c9ffbc838271f0ea27a4780eb146287de53ef6': docs: add links from widget classes to tutorials
This commit is contained in:
@@ -34,6 +34,9 @@ import java.util.Calendar;
|
||||
|
||||
/**
|
||||
* A simple dialog containing an {@link android.widget.DatePicker}.
|
||||
*
|
||||
* <p>See the <a href="{@docRoot}resources/tutorials/views/hello-datepicker.html">Date Picker
|
||||
* tutorial</a>.</p>
|
||||
*/
|
||||
public class DatePickerDialog extends AlertDialog implements OnClickListener,
|
||||
OnDateChangedListener {
|
||||
|
||||
@@ -32,6 +32,9 @@ import java.util.Calendar;
|
||||
|
||||
/**
|
||||
* A dialog that prompts the user for the time of day using a {@link TimePicker}.
|
||||
*
|
||||
* <p>See the <a href="{@docRoot}resources/tutorials/views/hello-timepicker.html">Time Picker
|
||||
* tutorial</a>.</p>
|
||||
*/
|
||||
public class TimePickerDialog extends AlertDialog implements OnClickListener,
|
||||
OnTimeChangedListener {
|
||||
|
||||
@@ -117,6 +117,9 @@ import junit.framework.Assert;
|
||||
* href="{@docRoot}guide/topics/manifest/manifest-element.html">{@code <manifest>}</a>
|
||||
* element.</p>
|
||||
*
|
||||
* <p>See the <a href="{@docRoot}resources/tutorials/views/hello-webview.html">Web View
|
||||
* tutorial</a>.</p>
|
||||
*
|
||||
* <h3>Basic usage</h3>
|
||||
*
|
||||
* <p>By default, a WebView provides no browser-like widgets, does not
|
||||
|
||||
@@ -76,6 +76,9 @@ import com.android.internal.R;
|
||||
* }
|
||||
* </pre>
|
||||
*
|
||||
* <p>See the <a href="{@docRoot}resources/tutorials/views/hello-autocomplete.html">Auto Complete
|
||||
* tutorial</a>.</p>
|
||||
*
|
||||
* @attr ref android.R.styleable#AutoCompleteTextView_completionHint
|
||||
* @attr ref android.R.styleable#AutoCompleteTextView_completionThreshold
|
||||
* @attr ref android.R.styleable#AutoCompleteTextView_completionHintView
|
||||
|
||||
@@ -48,6 +48,9 @@ import android.widget.RemoteViews.RemoteView;
|
||||
* }
|
||||
* </pre>
|
||||
*
|
||||
* <p>See the <a href="{@docRoot}resources/tutorials/views/hello-formstuff.html">Form Stuff
|
||||
* tutorial</a>.</p>
|
||||
*
|
||||
* <p><strong>XML attributes</strong></p>
|
||||
* <p>
|
||||
* See {@link android.R.styleable#Button Button Attributes},
|
||||
|
||||
@@ -41,6 +41,9 @@ import android.util.AttributeSet;
|
||||
* }
|
||||
* }
|
||||
* </pre>
|
||||
*
|
||||
* <p>See the <a href="{@docRoot}resources/tutorials/views/hello-formstuff.html">Form Stuff
|
||||
* tutorial</a>.</p>
|
||||
*
|
||||
* <p><strong>XML attributes</strong></p>
|
||||
* <p>
|
||||
|
||||
@@ -37,6 +37,9 @@ import java.util.Calendar;
|
||||
/**
|
||||
* A view for selecting a month / year / day based on a calendar like layout.
|
||||
*
|
||||
* <p>See the <a href="{@docRoot}resources/tutorials/views/hello-datepicker.html">Date Picker
|
||||
* tutorial</a>.</p>
|
||||
*
|
||||
* For a dialog using this view, see {@link android.app.DatePickerDialog}.
|
||||
*/
|
||||
@Widget
|
||||
|
||||
@@ -35,6 +35,9 @@ import android.util.AttributeSet;
|
||||
/**
|
||||
* EditText is a thin veneer over TextView that configures itself
|
||||
* to be editable.
|
||||
*
|
||||
* <p>See the <a href="{@docRoot}resources/tutorials/views/hello-formstuff.html">Form Stuff
|
||||
* tutorial</a>.</p>
|
||||
* <p>
|
||||
* <b>XML attributes</b>
|
||||
* <p>
|
||||
|
||||
@@ -46,6 +46,9 @@ import android.view.animation.Transformation;
|
||||
* <p>
|
||||
* Views given to the Gallery should use {@link Gallery.LayoutParams} as their
|
||||
* layout parameters type.
|
||||
*
|
||||
* <p>See the <a href="{@docRoot}resources/tutorials/views/hello-gallery.html">Gallery
|
||||
* tutorial</a>.</p>
|
||||
*
|
||||
* @attr ref android.R.styleable#Gallery_animationDuration
|
||||
* @attr ref android.R.styleable#Gallery_spacing
|
||||
|
||||
@@ -31,6 +31,9 @@ import android.view.animation.GridLayoutAnimationController;
|
||||
/**
|
||||
* A view that shows items in two-dimensional scrolling grid. The items in the
|
||||
* grid come from the {@link ListAdapter} associated with this view.
|
||||
*
|
||||
* <p>See the <a href="{@docRoot}resources/tutorials/views/hello-gridview.html">Grid
|
||||
* View tutorial</a>.</p>
|
||||
*/
|
||||
public class GridView extends AbsListView {
|
||||
public static final int NO_STRETCH = 0;
|
||||
|
||||
@@ -62,6 +62,9 @@ import java.util.Map;
|
||||
* it will only be applied after {@code android:state_pressed} and {@code
|
||||
* android:state_focused} have both evaluated false.</p>
|
||||
*
|
||||
* <p>See the <a href="{@docRoot}resources/tutorials/views/hello-formstuff.html">Form Stuff
|
||||
* tutorial</a>.</p>
|
||||
*
|
||||
* <p><strong>XML attributes</strong></p>
|
||||
* <p>
|
||||
* See {@link android.R.styleable#ImageView Button Attributes},
|
||||
|
||||
@@ -37,6 +37,9 @@ import android.widget.RemoteViews.RemoteView;
|
||||
* {@link android.widget.LinearLayout.LayoutParams LinearLayout.LayoutParams}.
|
||||
* The default orientation is horizontal.
|
||||
*
|
||||
* <p>See the <a href="{@docRoot}resources/tutorials/views/hello-linearlayout.html">Linear Layout
|
||||
* tutorial</a>.</p>
|
||||
*
|
||||
* <p>
|
||||
* Also see {@link LinearLayout.LayoutParams android.widget.LinearLayout.LayoutParams}
|
||||
* for layout attributes </p>
|
||||
|
||||
@@ -58,6 +58,9 @@ import java.util.ArrayList;
|
||||
* A view that shows items in a vertically scrolling list. The items
|
||||
* come from the {@link ListAdapter} associated with this view.
|
||||
*
|
||||
* <p>See the <a href="{@docRoot}resources/tutorials/views/hello-listview.html">List View
|
||||
* tutorial</a>.</p>
|
||||
*
|
||||
* @attr ref android.R.styleable#ListView_entries
|
||||
* @attr ref android.R.styleable#ListView_divider
|
||||
* @attr ref android.R.styleable#ListView_dividerHeight
|
||||
|
||||
@@ -34,6 +34,9 @@ import android.util.AttributeSet;
|
||||
* a radio group, checking one radio button unchecks all the others.</p>
|
||||
* </p>
|
||||
*
|
||||
* <p>See the <a href="{@docRoot}resources/tutorials/views/hello-formstuff.html">Form Stuff
|
||||
* tutorial</a>.</p>
|
||||
*
|
||||
* <p><strong>XML attributes</strong></p>
|
||||
* <p>
|
||||
* See {@link android.R.styleable#CompoundButton CompoundButton Attributes},
|
||||
|
||||
@@ -41,6 +41,9 @@ import com.android.internal.R;
|
||||
* <p>
|
||||
* The secondary progress should not be modified by the client as it is used
|
||||
* internally as the background for a fractionally filled star.
|
||||
*
|
||||
* <p>See the <a href="{@docRoot}resources/tutorials/views/hello-formstuff.html">Form Stuff
|
||||
* tutorial</a>.</p>
|
||||
*
|
||||
* @attr ref android.R.styleable#RatingBar_numStars
|
||||
* @attr ref android.R.styleable#RatingBar_rating
|
||||
|
||||
@@ -54,6 +54,9 @@ import java.util.ArrayList;
|
||||
* {@link #ALIGN_PARENT_BOTTOM}.
|
||||
* </p>
|
||||
*
|
||||
* <p>See the <a href="{@docRoot}resources/tutorials/views/hello-relativelayout.html">Relative
|
||||
* Layout tutorial</a>.</p>
|
||||
*
|
||||
* <p>
|
||||
* Also see {@link android.widget.RelativeLayout.LayoutParams RelativeLayout.LayoutParams} for
|
||||
* layout attributes
|
||||
|
||||
@@ -32,6 +32,9 @@ import android.view.ViewGroup;
|
||||
* A view that displays one child at a time and lets the user pick among them.
|
||||
* The items in the Spinner come from the {@link Adapter} associated with
|
||||
* this view.
|
||||
*
|
||||
* <p>See the <a href="{@docRoot}resources/tutorials/views/hello-spinner.html">Spinner
|
||||
* tutorial</a>.</p>
|
||||
*
|
||||
* @attr ref android.R.styleable#Spinner_prompt
|
||||
*/
|
||||
|
||||
@@ -40,6 +40,9 @@ import java.util.List;
|
||||
* user clicks to select a specific tab, and a FrameLayout object that displays the contents of that
|
||||
* page. The individual elements are typically controlled using this container object, rather than
|
||||
* setting values on the child elements themselves.
|
||||
*
|
||||
* <p>See the <a href="{@docRoot}resources/tutorials/views/hello-tabwidget.html">Tab Layout
|
||||
* tutorial</a>.</p>
|
||||
*/
|
||||
public class TabHost extends FrameLayout implements ViewTreeObserver.OnTouchModeChangeListener {
|
||||
|
||||
|
||||
@@ -40,6 +40,9 @@ import android.view.View.OnFocusChangeListener;
|
||||
* handler, and manage callbacks. You might call this object to iterate the list
|
||||
* of tabs, or to tweak the layout of the tab list, but most methods should be
|
||||
* called on the containing TabHost object.
|
||||
*
|
||||
* <p>See the <a href="{@docRoot}resources/tutorials/views/hello-tabwidget.html">Tab Layout
|
||||
* tutorial</a>.</p>
|
||||
*
|
||||
* @attr ref android.R.styleable#TabWidget_divider
|
||||
* @attr ref android.R.styleable#TabWidget_tabStripEnabled
|
||||
|
||||
@@ -67,6 +67,9 @@ import java.util.regex.Pattern;
|
||||
* <p>Although the typical child of a TableLayout is a TableRow, you can
|
||||
* actually use any View subclass as a direct child of TableLayout. The View
|
||||
* will be displayed as a single row that spans all the table columns.</p>
|
||||
*
|
||||
* <p>See the <a href="{@docRoot}resources/tutorials/views/hello-tablelayout.html">Table
|
||||
* Layout tutorial</a>.</p>
|
||||
*/
|
||||
public class TableLayout extends LinearLayout {
|
||||
private int[] mMaxWidths;
|
||||
|
||||
@@ -45,6 +45,9 @@ import java.util.Calendar;
|
||||
* Under AM/PM mode, the user can hit 'a', 'A", 'p' or 'P' to pick.
|
||||
*
|
||||
* For a dialog using this view, see {@link android.app.TimePickerDialog}.
|
||||
*
|
||||
* <p>See the <a href="{@docRoot}resources/tutorials/views/hello-timepicker.html">Time Picker
|
||||
* tutorial</a>.</p>
|
||||
*/
|
||||
@Widget
|
||||
public class TimePicker extends FrameLayout {
|
||||
|
||||
@@ -26,6 +26,9 @@ import android.util.AttributeSet;
|
||||
/**
|
||||
* Displays checked/unchecked states as a button
|
||||
* with a "light" indicator and by default accompanied with the text "ON" or "OFF".
|
||||
*
|
||||
* <p>See the <a href="{@docRoot}resources/tutorials/views/hello-formstuff.html">Form Stuff
|
||||
* tutorial</a>.</p>
|
||||
*
|
||||
* @attr ref android.R.styleable#ToggleButton_textOn
|
||||
* @attr ref android.R.styleable#ToggleButton_textOff
|
||||
|
||||
@@ -32,9 +32,19 @@ public void onCreate(Bundle savedInstanceState) {
|
||||
}
|
||||
</pre>
|
||||
|
||||
<p>Now select which kind of form widget you'd like to create:</p>
|
||||
<ul>
|
||||
<li><a href="#CustomButton">Custom Button</a></li>
|
||||
<li><a href="#EditText">Edit Text</a></li>
|
||||
<li><a href="#Checkbox">Checkbox</a></li>
|
||||
<li><a href="#RadioButtons">Radio Buttons</a></li>
|
||||
<li><a href="#ToggleButton">Toggle Button</a></li>
|
||||
<li><a href="#RatingBar">Rating Bar</a></li>
|
||||
</ul>
|
||||
|
||||
|
||||
<h2>Custom Button</h2>
|
||||
|
||||
<h2 id="CustomButton">Custom Button</h2>
|
||||
|
||||
<p>In this section, you will create a button with a custom image instead of text, using the {@link
|
||||
android.widget.Button} widget and an XML file that defines three different images to use for the
|
||||
@@ -111,7 +121,8 @@ defines the action to be made when the button is clicked. In this example, a
|
||||
</ol>
|
||||
|
||||
|
||||
<h2>EditText</h2>
|
||||
|
||||
<h2 id="EditText">Edit Text</h2>
|
||||
|
||||
<p>In this section, you will create a text field for user input, using the {@link
|
||||
android.widget.EditText} widget. Once text has been entered into the field, the "Enter" key will
|
||||
@@ -158,7 +169,8 @@ result in a carriage return in the text field).</p>
|
||||
</ol>
|
||||
|
||||
|
||||
<h2>CheckBox</h2>
|
||||
|
||||
<h2 id="Checkbox">Checkbox</h2>
|
||||
|
||||
<p>In this section, you will create a checkbox for selecting items, using the {@link
|
||||
android.widget.CheckBox} widget. When the checkbox is pressed, a toast message will
|
||||
@@ -209,7 +221,8 @@ use the {@link android.widget.CompoundButton#setChecked(boolean)} or {@link
|
||||
android.widget.CompoundButton#toggle()} method.</p>
|
||||
|
||||
|
||||
<h2>RadioButton</h2>
|
||||
|
||||
<h2 id="RadioButtons">Radio Buttons</h2>
|
||||
|
||||
<p>In this section, you will create two mutually-exclusive radio buttons (enabling one disables
|
||||
the other), using the {@link android.widget.RadioGroup} and {@link android.widget.RadioButton}
|
||||
@@ -274,7 +287,8 @@ use the {@link android.widget.CompoundButton#setChecked(boolean)} or {@link
|
||||
android.widget.CompoundButton#toggle()} method.</p>
|
||||
|
||||
|
||||
<h2>ToggleButton</h2>
|
||||
|
||||
<h2 id="ToggleButton">Toggle Button</h2>
|
||||
|
||||
<p>In this section, you'll create a button used specifically for toggling between two
|
||||
states, using the {@link android.widget.ToggleButton} widget. This widget is an excellent
|
||||
@@ -330,7 +344,7 @@ android.widget.CompoundButton#toggle()} method.</p>
|
||||
|
||||
|
||||
|
||||
<h2>RatingBar</h2>
|
||||
<h2 id="RatingBar">Rating Bar</h2>
|
||||
|
||||
<p>In this section, you'll create a widget that allows the user to provide a rating,
|
||||
with the {@link android.widget.RatingBar} widget.</p>
|
||||
|
||||
Reference in New Issue
Block a user