mirror of
https://github.com/Pinball3D/Rabbit-R1.git
synced 2025-01-09 13:43:22 +00:00
30 lines
1.1 KiB
Java
30 lines
1.1 KiB
Java
package com.google.android.material.animation;
|
|
|
|
import android.util.Property;
|
|
import android.view.ViewGroup;
|
|
import com.google.android.material.R;
|
|
|
|
/* loaded from: classes2.dex */
|
|
public class ChildrenAlphaProperty extends Property<ViewGroup, Float> {
|
|
public static final Property<ViewGroup, Float> CHILDREN_ALPHA = new ChildrenAlphaProperty("childrenAlpha");
|
|
|
|
private ChildrenAlphaProperty(String str) {
|
|
super(Float.class, str);
|
|
}
|
|
|
|
@Override // android.util.Property
|
|
public Float get(ViewGroup viewGroup) {
|
|
Float f = (Float) viewGroup.getTag(R.id.mtrl_internal_children_alpha_tag);
|
|
return f != null ? f : Float.valueOf(1.0f);
|
|
}
|
|
|
|
@Override // android.util.Property
|
|
public void set(ViewGroup viewGroup, Float f) {
|
|
float floatValue = f.floatValue();
|
|
viewGroup.setTag(R.id.mtrl_internal_children_alpha_tag, Float.valueOf(floatValue));
|
|
int childCount = viewGroup.getChildCount();
|
|
for (int i = 0; i < childCount; i++) {
|
|
viewGroup.getChildAt(i).setAlpha(floatValue);
|
|
}
|
|
}
|
|
}
|