Loading api/current.txt +1 −0 Original line number Diff line number Diff line Loading @@ -26902,6 +26902,7 @@ package android.widget { ctor public CheckedTextView(android.content.Context); ctor public CheckedTextView(android.content.Context, android.util.AttributeSet); ctor public CheckedTextView(android.content.Context, android.util.AttributeSet, int); method public android.graphics.drawable.Drawable getCheckMarkDrawable(); method public boolean isChecked(); method public void setCheckMarkDrawable(int); method public void setCheckMarkDrawable(android.graphics.drawable.Drawable); core/java/android/widget/CheckedTextView.java +26 −0 Original line number Diff line number Diff line Loading @@ -35,6 +35,8 @@ import android.view.accessibility.AccessibilityNodeInfo; * {@link android.widget.ListView#setChoiceMode(int) setChoiceMode} has been set to * something other than {@link android.widget.ListView#CHOICE_MODE_NONE CHOICE_MODE_NONE}. * * @attr ref android.R.styleable#CheckedTextView_checked * @attr ref android.R.styleable#CheckedTextView_checkMark */ public class CheckedTextView extends TextView implements Checkable { private boolean mChecked; Loading Loading @@ -100,6 +102,11 @@ public class CheckedTextView extends TextView implements Checkable { * when {@link #isChecked()} is true. * * @param resid The Drawable to use for the checkmark. * * @see #setCheckMarkDrawable(Drawable) * @see #getCheckMarkDrawable() * * @attr ref android.R.styleable#CheckedTextView_checkMark */ public void setCheckMarkDrawable(int resid) { if (resid != 0 && resid == mCheckMarkResource) { Loading @@ -119,6 +126,11 @@ public class CheckedTextView extends TextView implements Checkable { * Set the checkmark to a given Drawable. This will be drawn when {@link #isChecked()} is true. * * @param d The Drawable to use for the checkmark. * * @see #setCheckMarkDrawable(int) * @see #getCheckMarkDrawable() * * @attr ref android.R.styleable#CheckedTextView_checkMark */ public void setCheckMarkDrawable(Drawable d) { if (mCheckMarkDrawable != null) { Loading @@ -142,6 +154,20 @@ public class CheckedTextView extends TextView implements Checkable { resolvePadding(); } /** * Gets the checkmark drawable * * @return The drawable use to represent the checkmark, if any. * * @see #setCheckMarkDrawable(Drawable) * @see #setCheckMarkDrawable(int) * * @attr ref android.R.styleable#CheckedTextView_checkMark */ public Drawable getCheckMarkDrawable() { return mCheckMarkDrawable; } @Override public void onPaddingChanged(int layoutDirection) { int newPadding = (mCheckMarkDrawable != null) ? Loading Loading
api/current.txt +1 −0 Original line number Diff line number Diff line Loading @@ -26902,6 +26902,7 @@ package android.widget { ctor public CheckedTextView(android.content.Context); ctor public CheckedTextView(android.content.Context, android.util.AttributeSet); ctor public CheckedTextView(android.content.Context, android.util.AttributeSet, int); method public android.graphics.drawable.Drawable getCheckMarkDrawable(); method public boolean isChecked(); method public void setCheckMarkDrawable(int); method public void setCheckMarkDrawable(android.graphics.drawable.Drawable);
core/java/android/widget/CheckedTextView.java +26 −0 Original line number Diff line number Diff line Loading @@ -35,6 +35,8 @@ import android.view.accessibility.AccessibilityNodeInfo; * {@link android.widget.ListView#setChoiceMode(int) setChoiceMode} has been set to * something other than {@link android.widget.ListView#CHOICE_MODE_NONE CHOICE_MODE_NONE}. * * @attr ref android.R.styleable#CheckedTextView_checked * @attr ref android.R.styleable#CheckedTextView_checkMark */ public class CheckedTextView extends TextView implements Checkable { private boolean mChecked; Loading Loading @@ -100,6 +102,11 @@ public class CheckedTextView extends TextView implements Checkable { * when {@link #isChecked()} is true. * * @param resid The Drawable to use for the checkmark. * * @see #setCheckMarkDrawable(Drawable) * @see #getCheckMarkDrawable() * * @attr ref android.R.styleable#CheckedTextView_checkMark */ public void setCheckMarkDrawable(int resid) { if (resid != 0 && resid == mCheckMarkResource) { Loading @@ -119,6 +126,11 @@ public class CheckedTextView extends TextView implements Checkable { * Set the checkmark to a given Drawable. This will be drawn when {@link #isChecked()} is true. * * @param d The Drawable to use for the checkmark. * * @see #setCheckMarkDrawable(int) * @see #getCheckMarkDrawable() * * @attr ref android.R.styleable#CheckedTextView_checkMark */ public void setCheckMarkDrawable(Drawable d) { if (mCheckMarkDrawable != null) { Loading @@ -142,6 +154,20 @@ public class CheckedTextView extends TextView implements Checkable { resolvePadding(); } /** * Gets the checkmark drawable * * @return The drawable use to represent the checkmark, if any. * * @see #setCheckMarkDrawable(Drawable) * @see #setCheckMarkDrawable(int) * * @attr ref android.R.styleable#CheckedTextView_checkMark */ public Drawable getCheckMarkDrawable() { return mCheckMarkDrawable; } @Override public void onPaddingChanged(int layoutDirection) { int newPadding = (mCheckMarkDrawable != null) ? Loading