- Added realracing3-community.apk (71.57 MB) - Removed 32-bit support (armeabi-v7a) - Only includes arm64-v8a libraries - Decompiled source code included - Added README-community.md with analysis
49 lines
2.3 KiB
Java
49 lines
2.3 KiB
Java
package androidx.activity;
|
|
|
|
import android.view.View;
|
|
import kotlin.jvm.functions.Function1;
|
|
import kotlin.jvm.internal.Intrinsics;
|
|
import kotlin.sequences.Sequence;
|
|
import kotlin.sequences.SequencesKt__SequencesKt;
|
|
import kotlin.sequences.SequencesKt___SequencesKt;
|
|
|
|
/* loaded from: classes.dex */
|
|
public final class ViewTreeOnBackPressedDispatcherOwner {
|
|
public static final void set(View view, OnBackPressedDispatcherOwner onBackPressedDispatcherOwner) {
|
|
Intrinsics.checkNotNullParameter(view, "<this>");
|
|
Intrinsics.checkNotNullParameter(onBackPressedDispatcherOwner, "onBackPressedDispatcherOwner");
|
|
view.setTag(R.id.view_tree_on_back_pressed_dispatcher_owner, onBackPressedDispatcherOwner);
|
|
}
|
|
|
|
public static final OnBackPressedDispatcherOwner get(View view) {
|
|
Sequence generateSequence;
|
|
Sequence mapNotNull;
|
|
Object firstOrNull;
|
|
Intrinsics.checkNotNullParameter(view, "<this>");
|
|
generateSequence = SequencesKt__SequencesKt.generateSequence(view, new Function1() { // from class: androidx.activity.ViewTreeOnBackPressedDispatcherOwner$findViewTreeOnBackPressedDispatcherOwner$1
|
|
@Override // kotlin.jvm.functions.Function1
|
|
public final View invoke(View it) {
|
|
Intrinsics.checkNotNullParameter(it, "it");
|
|
Object parent = it.getParent();
|
|
if (parent instanceof View) {
|
|
return (View) parent;
|
|
}
|
|
return null;
|
|
}
|
|
});
|
|
mapNotNull = SequencesKt___SequencesKt.mapNotNull(generateSequence, new Function1() { // from class: androidx.activity.ViewTreeOnBackPressedDispatcherOwner$findViewTreeOnBackPressedDispatcherOwner$2
|
|
@Override // kotlin.jvm.functions.Function1
|
|
public final OnBackPressedDispatcherOwner invoke(View it) {
|
|
Intrinsics.checkNotNullParameter(it, "it");
|
|
Object tag = it.getTag(R.id.view_tree_on_back_pressed_dispatcher_owner);
|
|
if (tag instanceof OnBackPressedDispatcherOwner) {
|
|
return (OnBackPressedDispatcherOwner) tag;
|
|
}
|
|
return null;
|
|
}
|
|
});
|
|
firstOrNull = SequencesKt___SequencesKt.firstOrNull(mapNotNull);
|
|
return (OnBackPressedDispatcherOwner) firstOrNull;
|
|
}
|
|
}
|