diff options
Diffstat (limited to 'core')
-rw-r--r-- | core/java/android/widget/ListView.java | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/core/java/android/widget/ListView.java b/core/java/android/widget/ListView.java index a786b3f..64e5452 100644 --- a/core/java/android/widget/ListView.java +++ b/core/java/android/widget/ListView.java @@ -3167,11 +3167,12 @@ public class ListView extends AbsListView { /** * Returns the checked state of the specified position. The result is only - * valid if the choice mode has not been set to {@link #CHOICE_MODE_SINGLE} + * valid if the choice mode has been set to {@link #CHOICE_MODE_SINGLE} * or {@link #CHOICE_MODE_MULTIPLE}. * * @param position The item whose checked state to return - * @return The item's checked state + * @return The item's checked state or <code>false</code> if choice mode + * is invalid * * @see #setChoiceMode(int) */ @@ -3185,7 +3186,7 @@ public class ListView extends AbsListView { /** * Returns the currently checked item. The result is only valid if the choice - * mode has not been set to {@link #CHOICE_MODE_SINGLE}. + * mode has been set to {@link #CHOICE_MODE_SINGLE}. * * @return The position of the currently checked item or * {@link #INVALID_POSITION} if nothing is selected @@ -3202,10 +3203,12 @@ public class ListView extends AbsListView { /** * Returns the set of checked items in the list. The result is only valid if - * the choice mode has not been set to {@link #CHOICE_MODE_SINGLE}. + * the choice mode has not been set to {@link #CHOICE_MODE_NONE}. * * @return A SparseBooleanArray which will return true for each call to - * get(int position) where position is a position in the list. + * get(int position) where position is a position in the list, + * or <code>null</code> if the choice mode is set to + * {@link #CHOICE_MODE_NONE}. */ public SparseBooleanArray getCheckedItemPositions() { if (mChoiceMode != CHOICE_MODE_NONE) { |