alexandroid/decompiled/jadx/sources/androidx/compose/ui/semantics/SemanticsConfiguration.java
KaKi87 a47fad5135 📦 Add decompiled Alexa 2.2.730155.0 (jadx, apktool, Hermes strings)
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-11-07 00:04:16 +01:00

362 lines
20 KiB
Java

package androidx.compose.ui.semantics;
import ai.onnxruntime.OnnxMap$$ExternalSyntheticBUOutline0;
import androidx.collection.DoubleList$$ExternalSyntheticOutline0;
import androidx.collection.MutableScatterMap;
import androidx.collection.MutableScatterSet;
import androidx.collection.ScatterMapKt;
import androidx.collection.ScatterSet;
import androidx.collection.ScatterSetKt;
import androidx.compose.runtime.internal.StabilityInferred;
import androidx.compose.ui.platform.JvmActuals_jvmKt;
import androidx.exifinterface.media.ExifInterface;
import com.amazon.alexa.redesign.view.container.CardStudioAgentSpaceMetrics;
import com.amazon.deecomms.common.metrics.MetricKeys;
import com.dee.app.metrics.MetricsConstants;
import java.util.Iterator;
import java.util.Map;
import kotlin.Function;
import kotlin.Metadata;
import kotlin.jvm.functions.Function0;
import kotlin.jvm.internal.Intrinsics;
import kotlin.jvm.internal.SourceDebugExtension;
import kotlin.jvm.internal.markers.KMappedMarker;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
/* compiled from: r8-map-id-b9432e0f623b4a4bff4ba50a8a24c4aafad2c1e11092747b9fb5e6a22af5a940 */
@StabilityInferred(parameters = 0)
@Metadata(d1 = {"\u0000b\n\u0002\u0018\u0002\n\u0002\u0018\u0002\n\u0002\u0010\u001c\n\u0002\u0010&\n\u0002\u0018\u0002\n\u0002\u0010\u0000\n\u0002\b\u0003\n\u0002\u0018\u0002\n\u0002\b\u0003\n\u0002\u0010$\n\u0000\n\u0002\u0018\u0002\n\u0000\n\u0002\u0018\u0002\n\u0002\b\b\n\u0002\u0018\u0002\n\u0002\b\u0003\n\u0002\u0010(\n\u0000\n\u0002\u0010\u0002\n\u0002\b\u0003\n\u0002\u0010\u000b\n\u0002\b\u0012\n\u0002\u0010\b\n\u0000\n\u0002\u0010\u000e\n\u0000\b\u0007\u0018\u00002\u00020\u00012\u001a\u0012\u0016\u0012\u0014\u0012\b\u0012\u0006\u0012\u0002\b\u00030\u0004\u0012\u0006\u0012\u0004\u0018\u00010\u00050\u00030\u0002B\u0007¢\u0006\u0004\b\u0006\u0010\u0007J\"\u0010\u0014\u001a\u0002H\u0015\"\u0004\b\u0000\u0010\u00152\f\u0010\u0016\u001a\b\u0012\u0004\u0012\u0002H\u00150\u0004H\u0086\u0002¢\u0006\u0002\u0010\u0017J-\u0010\u0018\u001a\u0002H\u0015\"\u0004\b\u0000\u0010\u00152\f\u0010\u0016\u001a\b\u0012\u0004\u0012\u0002H\u00150\u00042\f\u0010\u0019\u001a\b\u0012\u0004\u0012\u0002H\u00150\u001a¢\u0006\u0002\u0010\u001bJ1\u0010\u001c\u001a\u0004\u0018\u0001H\u0015\"\u0004\b\u0000\u0010\u00152\f\u0010\u0016\u001a\b\u0012\u0004\u0012\u0002H\u00150\u00042\u000e\u0010\u0019\u001a\n\u0012\u0006\u0012\u0004\u0018\u0001H\u00150\u001a¢\u0006\u0002\u0010\u001bJ!\u0010\u001d\u001a\u001a\u0012\u0016\u0012\u0014\u0012\b\u0012\u0006\u0012\u0002\b\u00030\u0004\u0012\u0006\u0012\u0004\u0018\u00010\u00050\u00030\u001eH\u0096\u0002J*\u0010\u001f\u001a\u00020 \"\u0004\b\u0000\u0010\u00152\f\u0010\u0016\u001a\b\u0012\u0004\u0012\u0002H\u00150\u00042\u0006\u0010!\u001a\u0002H\u0015H\u0096\u0002¢\u0006\u0002\u0010\"J\u001d\u0010#\u001a\u00020$\"\u0004\b\u0000\u0010\u00152\f\u0010\u0016\u001a\b\u0012\u0004\u0012\u0002H\u00150\u0004H\u0086\u0002J\r\u0010%\u001a\u00020$H\u0000¢\u0006\u0002\b&J\u0015\u0010-\u001a\u00020 2\u0006\u0010.\u001a\u00020\u0000H\u0000¢\u0006\u0002\b/J\u0015\u00100\u001a\u00020 2\u0006\u00101\u001a\u00020\u0000H\u0000¢\u0006\u0002\b2J\u0006\u00103\u001a\u00020\u0000J\u0013\u00104\u001a\u00020$2\b\u00105\u001a\u0004\u0018\u00010\u0005H\u0096\u0002J\b\u00106\u001a\u000207H\u0016J\b\u00108\u001a\u000209H\u0016R&\u0010\b\u001a\u0014\u0012\b\u0012\u0006\u0012\u0002\b\u00030\u0004\u0012\u0006\u0012\u0004\u0018\u00010\u00050\tX\u0080\u0004¢\u0006\b\n\u0000\u001a\u0004\b\n\u0010\u000bR\"\u0010\f\u001a\u0016\u0012\b\u0012\u0006\u0012\u0002\b\u00030\u0004\u0012\u0006\u0012\u0004\u0018\u00010\u0005\u0018\u00010\rX\u0082\u000e¢\u0006\u0002\n\u0000R\u001a\u0010\u000e\u001a\u000e\u0012\b\u0012\u0006\u0012\u0002\b\u00030\u0004\u0018\u00010\u000fX\u0082\u000e¢\u0006\u0002\n\u0000R \u0010\u0010\u001a\u000e\u0012\b\u0012\u0006\u0012\u0002\b\u00030\u0004\u0018\u00010\u00118@X\u0080\u0004¢\u0006\u0006\u001a\u0004\b\u0012\u0010\u0013R\u001a\u0010'\u001a\u00020$X\u0086\u000e¢\u0006\u000e\n\u0000\u001a\u0004\b'\u0010(\"\u0004\b)\u0010*R\u001a\u0010+\u001a\u00020$X\u0086\u000e¢\u0006\u000e\n\u0000\u001a\u0004\b+\u0010(\"\u0004\b,\u0010*¨\u0006:"}, d2 = {"Landroidx/compose/ui/semantics/SemanticsConfiguration;", "Landroidx/compose/ui/semantics/SemanticsPropertyReceiver;", "", "", "Landroidx/compose/ui/semantics/SemanticsPropertyKey;", "", "<init>", "()V", "props", "Landroidx/collection/MutableScatterMap;", "getProps$ui_release", "()Landroidx/collection/MutableScatterMap;", "mapWrapper", "", "_accessibilityExtraKeys", "Landroidx/collection/MutableScatterSet;", "accessibilityExtraKeys", "Landroidx/collection/ScatterSet;", "getAccessibilityExtraKeys$ui_release", "()Landroidx/collection/ScatterSet;", MetricsConstants.Method.CACHE_GET, ExifInterface.GPS_DIRECTION_TRUE, "key", "(Landroidx/compose/ui/semantics/SemanticsPropertyKey;)Ljava/lang/Object;", "getOrElse", "defaultValue", "Lkotlin/Function0;", "(Landroidx/compose/ui/semantics/SemanticsPropertyKey;Lkotlin/jvm/functions/Function0;)Ljava/lang/Object;", "getOrElseNullable", "iterator", "", "set", "", "value", "(Landroidx/compose/ui/semantics/SemanticsPropertyKey;Ljava/lang/Object;)V", "contains", "", "containsImportantForAccessibility", "containsImportantForAccessibility$ui_release", "isMergingSemanticsOfDescendants", "()Z", "setMergingSemanticsOfDescendants", "(Z)V", "isClearingSemantics", "setClearingSemantics", "mergeChild", MetricKeys.VALUE_IS_CHILD, "mergeChild$ui_release", "collapsePeer", "peer", "collapsePeer$ui_release", "copy", "equals", CardStudioAgentSpaceMetrics.DimensionValue.SCHEME_OTHER, "hashCode", "", "toString", "", "ui_release"}, k = 1, mv = {2, 0, 0}, xi = 48)
@SourceDebugExtension({"SMAP\nSemanticsConfiguration.kt\nKotlin\n*S Kotlin\n*F\n+ 1 SemanticsConfiguration.kt\nandroidx/compose/ui/semantics/SemanticsConfiguration\n+ 2 ScatterMap.kt\nandroidx/collection/ScatterMap\n+ 3 fake.kt\nkotlin/jvm/internal/FakeKt\n+ 4 ScatterMap.kt\nandroidx/collection/ScatterMapKt\n*L\n1#1,210:1\n320#2:211\n320#2:212\n320#2:213\n385#2:215\n357#2,4:216\n329#2,6:220\n339#2,3:227\n342#2,9:231\n361#2:240\n386#2:241\n357#2,4:242\n329#2,6:246\n339#2,3:253\n342#2,9:257\n361#2:266\n357#2,4:267\n329#2,6:271\n339#2,3:278\n342#2,9:282\n361#2:291\n357#2,4:292\n329#2,6:296\n339#2,3:303\n342#2,9:307\n361#2:316\n1#3:214\n1399#4:226\n1270#4:230\n1399#4:252\n1270#4:256\n1399#4:277\n1270#4:281\n1399#4:302\n1270#4:306\n*S KotlinDebug\n*F\n+ 1 SemanticsConfiguration.kt\nandroidx/compose/ui/semantics/SemanticsConfiguration\n*L\n48#1:211\n56#1:212\n62#1:213\n90#1:215\n90#1:216,4\n90#1:220,6\n90#1:227,3\n90#1:231,9\n90#1:240\n90#1:241\n112#1:242,4\n112#1:246,6\n112#1:253,3\n112#1:257,9\n112#1:266\n139#1:267,4\n139#1:271,6\n139#1:278,3\n139#1:282,9\n139#1:291\n196#1:292,4\n196#1:296,6\n196#1:303,3\n196#1:307,9\n196#1:316\n90#1:226\n90#1:230\n112#1:252\n112#1:256\n139#1:277\n139#1:281\n196#1:302\n196#1:306\n*E\n"})
/* loaded from: classes13.dex */
public final class SemanticsConfiguration implements SemanticsPropertyReceiver, Iterable<Map.Entry<? extends SemanticsPropertyKey<?>, ? extends Object>>, KMappedMarker {
public static final int $stable = 8;
@Nullable
private MutableScatterSet<SemanticsPropertyKey<?>> _accessibilityExtraKeys;
private boolean isClearingSemantics;
private boolean isMergingSemanticsOfDescendants;
@Nullable
private Map<SemanticsPropertyKey<?>, ? extends Object> mapWrapper;
@NotNull
private final MutableScatterMap<SemanticsPropertyKey<?>, Object> props = ScatterMapKt.mutableScatterMapOf();
public final void collapsePeer$ui_release(@NotNull SemanticsConfiguration peer) {
int i;
if (peer.isMergingSemanticsOfDescendants) {
this.isMergingSemanticsOfDescendants = true;
}
if (peer.isClearingSemantics) {
this.isClearingSemantics = true;
}
MutableScatterMap<SemanticsPropertyKey<?>, Object> mutableScatterMap = peer.props;
Object[] objArr = mutableScatterMap.keys;
Object[] objArr2 = mutableScatterMap.values;
long[] jArr = mutableScatterMap.metadata;
int length = jArr.length - 2;
if (length < 0) {
return;
}
int i2 = 0;
while (true) {
long j = jArr[i2];
if ((((~j) << 7) & j & (-9187201950435737472L)) != -9187201950435737472L) {
int i3 = 8;
int i4 = 8 - ((~(i2 - length)) >>> 31);
int i5 = 0;
while (i5 < i4) {
if ((255 & j) < 128) {
int i6 = (i2 << 3) + i5;
Object obj = objArr[i6];
Object obj2 = objArr2[i6];
SemanticsPropertyKey<?> semanticsPropertyKey = (SemanticsPropertyKey) obj;
if (!this.props.contains(semanticsPropertyKey)) {
this.props.set(semanticsPropertyKey, obj2);
} else if (obj2 instanceof AccessibilityAction) {
Object obj3 = this.props.get(semanticsPropertyKey);
obj3.getClass();
AccessibilityAction accessibilityAction = (AccessibilityAction) obj3;
MutableScatterMap<SemanticsPropertyKey<?>, Object> mutableScatterMap2 = this.props;
String label = accessibilityAction.getLabel();
if (label == null) {
label = ((AccessibilityAction) obj2).getLabel();
}
i = i3;
String str = label;
Function action = accessibilityAction.getAction();
if (action == null) {
action = ((AccessibilityAction) obj2).getAction();
}
mutableScatterMap2.set(semanticsPropertyKey, new AccessibilityAction(str, action));
j >>= i;
i5++;
i3 = i;
}
}
i = i3;
j >>= i;
i5++;
i3 = i;
}
if (i4 != i3) {
return;
}
}
if (i2 == length) {
return;
} else {
i2++;
}
}
}
public final <T> boolean contains(@NotNull SemanticsPropertyKey<T> key) {
return this.props.containsKey(key);
}
public final boolean containsImportantForAccessibility$ui_release() {
MutableScatterMap<SemanticsPropertyKey<?>, Object> mutableScatterMap = this.props;
Object[] objArr = mutableScatterMap.keys;
Object[] objArr2 = mutableScatterMap.values;
long[] jArr = mutableScatterMap.metadata;
int length = jArr.length - 2;
if (length >= 0) {
int i = 0;
while (true) {
long j = jArr[i];
if ((((~j) << 7) & j & (-9187201950435737472L)) != -9187201950435737472L) {
int i2 = 8 - ((~(i - length)) >>> 31);
for (int i3 = 0; i3 < i2; i3++) {
if ((255 & j) < 128) {
int i4 = (i << 3) + i3;
Object obj = objArr[i4];
Object obj2 = objArr2[i4];
if (((SemanticsPropertyKey) obj).getIsImportantForAccessibility()) {
return true;
}
}
j >>= 8;
}
if (i2 != 8) {
break;
}
}
if (i == length) {
break;
}
i++;
}
}
return false;
}
@NotNull
public final SemanticsConfiguration copy() {
SemanticsConfiguration semanticsConfiguration = new SemanticsConfiguration();
semanticsConfiguration.isMergingSemanticsOfDescendants = this.isMergingSemanticsOfDescendants;
semanticsConfiguration.isClearingSemantics = this.isClearingSemantics;
semanticsConfiguration.props.putAll(this.props);
return semanticsConfiguration;
}
public boolean equals(@Nullable Object other) {
if (this == other) {
return true;
}
if (!(other instanceof SemanticsConfiguration)) {
return false;
}
SemanticsConfiguration semanticsConfiguration = (SemanticsConfiguration) other;
return Intrinsics.areEqual(this.props, semanticsConfiguration.props) && this.isMergingSemanticsOfDescendants == semanticsConfiguration.isMergingSemanticsOfDescendants && this.isClearingSemantics == semanticsConfiguration.isClearingSemantics;
}
public final <T> T get(@NotNull SemanticsPropertyKey<T> key) {
T t = (T) this.props.get(key);
if (t != null) {
return t;
}
OnnxMap$$ExternalSyntheticBUOutline0.m("Key not present: ", key, " - consider getOrElse or getOrNull");
return null;
}
@Nullable
public final ScatterSet<SemanticsPropertyKey<?>> getAccessibilityExtraKeys$ui_release() {
return this._accessibilityExtraKeys;
}
public final <T> T getOrElse(@NotNull SemanticsPropertyKey<T> key, @NotNull Function0<? extends T> defaultValue) {
T t = (T) this.props.get(key);
return t == null ? defaultValue.invoke() : t;
}
@Nullable
public final <T> T getOrElseNullable(@NotNull SemanticsPropertyKey<T> key, @NotNull Function0<? extends T> defaultValue) {
T t = (T) this.props.get(key);
return t == null ? defaultValue.invoke() : t;
}
@NotNull
public final MutableScatterMap<SemanticsPropertyKey<?>, Object> getProps$ui_release() {
return this.props;
}
public int hashCode() {
return Boolean.hashCode(this.isClearingSemantics) + DoubleList$$ExternalSyntheticOutline0.m(this.isMergingSemanticsOfDescendants, this.props.hashCode() * 31, 31);
}
/* renamed from: isClearingSemantics, reason: from getter */
public final boolean getIsClearingSemantics() {
return this.isClearingSemantics;
}
/* renamed from: isMergingSemanticsOfDescendants, reason: from getter */
public final boolean getIsMergingSemanticsOfDescendants() {
return this.isMergingSemanticsOfDescendants;
}
@Override // java.lang.Iterable
@NotNull
public Iterator<Map.Entry<? extends SemanticsPropertyKey<?>, ? extends Object>> iterator() {
Map<SemanticsPropertyKey<?>, ? extends Object> map = this.mapWrapper;
if (map == null) {
map = this.props.asMap();
this.mapWrapper = map;
}
return map.entrySet().iterator();
}
public final void mergeChild$ui_release(@NotNull SemanticsConfiguration child) {
MutableScatterMap<SemanticsPropertyKey<?>, Object> mutableScatterMap = child.props;
Object[] objArr = mutableScatterMap.keys;
Object[] objArr2 = mutableScatterMap.values;
long[] jArr = mutableScatterMap.metadata;
int length = jArr.length - 2;
if (length < 0) {
return;
}
int i = 0;
while (true) {
long j = jArr[i];
if ((((~j) << 7) & j & (-9187201950435737472L)) != -9187201950435737472L) {
int i2 = 8 - ((~(i - length)) >>> 31);
for (int i3 = 0; i3 < i2; i3++) {
if ((255 & j) < 128) {
int i4 = (i << 3) + i3;
Object obj = objArr[i4];
Object obj2 = objArr2[i4];
SemanticsPropertyKey<?> semanticsPropertyKey = (SemanticsPropertyKey) obj;
Object obj3 = this.props.get(semanticsPropertyKey);
semanticsPropertyKey.getClass();
Object merge = semanticsPropertyKey.merge(obj3, obj2);
if (merge != null) {
this.props.set(semanticsPropertyKey, merge);
}
}
j >>= 8;
}
if (i2 != 8) {
return;
}
}
if (i == length) {
return;
} else {
i++;
}
}
}
/* JADX WARN: Multi-variable type inference failed */
@Override // androidx.compose.ui.semantics.SemanticsPropertyReceiver
public <T> void set(@NotNull SemanticsPropertyKey<T> key, T value) {
if ((value instanceof AccessibilityAction) && contains(key)) {
Object obj = this.props.get(key);
obj.getClass();
AccessibilityAction accessibilityAction = (AccessibilityAction) obj;
MutableScatterMap<SemanticsPropertyKey<?>, Object> mutableScatterMap = this.props;
AccessibilityAction accessibilityAction2 = (AccessibilityAction) value;
String label = accessibilityAction2.getLabel();
if (label == null) {
label = accessibilityAction.getLabel();
}
Function action = accessibilityAction2.getAction();
if (action == null) {
action = accessibilityAction.getAction();
}
mutableScatterMap.set(key, new AccessibilityAction(label, action));
} else {
this.props.set(key, value);
}
if (key.getAccessibilityExtraKey() != null) {
if (this._accessibilityExtraKeys == null) {
this._accessibilityExtraKeys = ScatterSetKt.mutableScatterSetOf();
}
MutableScatterSet<SemanticsPropertyKey<?>> mutableScatterSet = this._accessibilityExtraKeys;
if (mutableScatterSet != null) {
mutableScatterSet.add(key);
}
}
}
public final void setClearingSemantics(boolean z) {
this.isClearingSemantics = z;
}
public final void setMergingSemanticsOfDescendants(boolean z) {
this.isMergingSemanticsOfDescendants = z;
}
@NotNull
public String toString() {
String str;
StringBuilder sb = new StringBuilder();
if (this.isMergingSemanticsOfDescendants) {
sb.append("mergeDescendants=true");
str = ", ";
} else {
str = "";
}
if (this.isClearingSemantics) {
sb.append(str);
sb.append("isClearingSemantics=true");
str = ", ";
}
MutableScatterMap<SemanticsPropertyKey<?>, Object> mutableScatterMap = this.props;
Object[] objArr = mutableScatterMap.keys;
Object[] objArr2 = mutableScatterMap.values;
long[] jArr = mutableScatterMap.metadata;
int length = jArr.length - 2;
if (length >= 0) {
int i = 0;
while (true) {
long j = jArr[i];
if ((((~j) << 7) & j & (-9187201950435737472L)) != -9187201950435737472L) {
int i2 = 8 - ((~(i - length)) >>> 31);
for (int i3 = 0; i3 < i2; i3++) {
if ((255 & j) < 128) {
int i4 = (i << 3) + i3;
Object obj = objArr[i4];
Object obj2 = objArr2[i4];
sb.append(str);
sb.append(((SemanticsPropertyKey) obj).getName());
sb.append(" : ");
sb.append(obj2);
str = ", ";
}
j >>= 8;
}
if (i2 != 8) {
break;
}
}
if (i == length) {
break;
}
i++;
}
}
return JvmActuals_jvmKt.simpleIdentityToString(this, null) + "{ " + ((Object) sb) + " }";
}
}