本文整理了Java中android.widget.ImageView.drawableStateChanged()
方法的一些代码示例,展示了ImageView.drawableStateChanged()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。ImageView.drawableStateChanged()
方法的具体详情如下:
包路径:android.widget.ImageView
类名称:ImageView
方法名:drawableStateChanged
暂无
代码示例来源:origin: vinc3m1/RoundedImageView
@Override
protected void drawableStateChanged() {
super.drawableStateChanged();
invalidate();
}
代码示例来源:origin: mcxiaoke/android-volley
@Override
protected void drawableStateChanged() {
super.drawableStateChanged();
invalidate();
}
}
代码示例来源:origin: chentao0707/SimplifyReader
@Override
protected void drawableStateChanged() {
super.drawableStateChanged();
invalidate();
}
}
代码示例来源:origin: hitherejoe/animate
@Override
protected void drawableStateChanged() {
super.drawableStateChanged();
invalidate();
}
代码示例来源:origin: jiangqqlmj/FastDev4Android
@Override
protected void drawableStateChanged() {
super.drawableStateChanged();
invalidate();
}
}
代码示例来源:origin: ogaclejapan/SmartTabLayout
@Override
protected void drawableStateChanged() {
super.drawableStateChanged();
if (tint != null && tint.isStateful()) {
updateTintColor();
}
}
代码示例来源:origin: aa112901/remusic
@Override
protected void drawableStateChanged() {
super.drawableStateChanged();
if (getBackground() != null) {
invalidateDrawable(getBackground());
}
}
代码示例来源:origin: xinghongfei/LookLook
@Override
protected void drawableStateChanged() {
super.drawableStateChanged();
if (foreground != null && foreground.isStateful()) {
foreground.setState(getDrawableState());
}
}
代码示例来源:origin: qiujuer/Genius-Android
@Override
protected void drawableStateChanged() {
super.drawableStateChanged();
if (mBackgroundColor != null) {
setBackgroundColor(mBackgroundColor.getColorForState(getDrawableState(), mBackgroundColor.getDefaultColor()));
}
}
代码示例来源:origin: rmtheis/android-ocr
super .drawableStateChanged();
final boolean pressed = isPressed();
if (pressed != mOldPressed) {
代码示例来源:origin: ZieIony/Carbon
@Override
protected void drawableStateChanged() {
super.drawableStateChanged();
if (rippleDrawable != null && rippleDrawable.getStyle() != RippleDrawable.Style.Background)
rippleDrawable.setState(getDrawableState());
if (stateAnimator != null)
stateAnimator.setState(getDrawableState());
if (tint != null && tint instanceof AnimatedColorStateList)
((AnimatedColorStateList) tint).setState(getDrawableState());
if (backgroundTint != null && backgroundTint instanceof AnimatedColorStateList)
((AnimatedColorStateList) backgroundTint).setState(getDrawableState());
if (ambientShadow != null && ambientShadowColor != null)
ambientShadowColorFilter = new PorterDuffColorFilter(ambientShadowColor.getColorForState(getDrawableState(), ambientShadowColor.getDefaultColor()), PorterDuff.Mode.MULTIPLY);
if (spotShadow != null && spotShadowColor != null)
spotShadowColorFilter = new PorterDuffColorFilter(spotShadowColor.getColorForState(getDrawableState(), spotShadowColor.getDefaultColor()), PorterDuff.Mode.MULTIPLY);
}
代码示例来源:origin: GeekGhost/Ghost
@Override
protected void drawableStateChanged() {
super.drawableStateChanged();
invalidate();
}
代码示例来源:origin: sunfusheng/GlideImageView
@Override
protected void drawableStateChanged() {
super.drawableStateChanged();
if (enableState) {
if (isPressed()) {
setAlpha(pressedAlpha);
} else if (!isEnabled()) {
setAlpha(unableAlpha);
} else {
setAlpha(1.0f);
}
}
}
代码示例来源:origin: com.mcxiaoke.volley/library
@Override
protected void drawableStateChanged() {
super.drawableStateChanged();
invalidate();
}
}
代码示例来源:origin: panxw/android-volley-manager
@Override
protected void drawableStateChanged() {
super.drawableStateChanged();
invalidate();
}
}
代码示例来源:origin: TangoAgency/avatar-view
@Override
protected void drawableStateChanged() {
super.drawableStateChanged();
invalidate();
}
}
代码示例来源:origin: w446108264/ScrollableLayout
@Override
protected void drawableStateChanged() {
super.drawableStateChanged();
if (foreground != null && foreground.isStateful()) {
foreground.setState(getDrawableState());
}
}
代码示例来源:origin: dialogflow/dialogflow-android-client
@TargetApi(11)
@Override
protected void drawableStateChanged() {
super.drawableStateChanged();
setColorFilter(getCurrentColor(getDrawableState()), PorterDuff.Mode.SRC_ATOP);
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.HONEYCOMB) {
jumpDrawablesToCurrentState();
}
}
代码示例来源:origin: yesidlazaro/BadgedImageview
@Override
protected void drawableStateChanged() {
super.drawableStateChanged();
if (foreground != null && foreground.isStateful()) {
foreground.setState(getDrawableState());
}
}
代码示例来源:origin: f2prateek/device-frame-generator
@Override protected void drawableStateChanged() {
super.drawableStateChanged();
if (foreground != null && foreground.isStateful()) {
foreground.setState(getDrawableState());
}
}
内容来源于网络,如有侵权,请联系作者删除!