Files
rr3-apk/decompiled-community/sources/androidx/lifecycle/LifecycleCoroutineScopeImpl.java
Daniel Elliott c080f0d97f Add Discord community version (64-bit only)
- 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
2026-02-18 15:48:36 -08:00

49 lines
2.1 KiB
Java

package androidx.lifecycle;
import androidx.lifecycle.Lifecycle;
import kotlin.coroutines.CoroutineContext;
import kotlin.jvm.internal.Intrinsics;
import kotlinx.coroutines.BuildersKt__Builders_commonKt;
import kotlinx.coroutines.Dispatchers;
import kotlinx.coroutines.JobKt__JobKt;
/* loaded from: classes.dex */
public final class LifecycleCoroutineScopeImpl extends LifecycleCoroutineScope implements LifecycleEventObserver {
private final CoroutineContext coroutineContext;
private final Lifecycle lifecycle;
@Override // androidx.lifecycle.LifecycleCoroutineScope, kotlinx.coroutines.CoroutineScope
public CoroutineContext getCoroutineContext() {
return this.coroutineContext;
}
@Override // androidx.lifecycle.LifecycleCoroutineScope
public Lifecycle getLifecycle$lifecycle_common() {
return this.lifecycle;
}
public LifecycleCoroutineScopeImpl(Lifecycle lifecycle, CoroutineContext coroutineContext) {
Intrinsics.checkNotNullParameter(lifecycle, "lifecycle");
Intrinsics.checkNotNullParameter(coroutineContext, "coroutineContext");
this.lifecycle = lifecycle;
this.coroutineContext = coroutineContext;
if (getLifecycle$lifecycle_common().getCurrentState() == Lifecycle.State.DESTROYED) {
JobKt__JobKt.cancel$default(getCoroutineContext(), null, 1, null);
}
}
public final void register() {
BuildersKt__Builders_commonKt.launch$default(this, Dispatchers.getMain().getImmediate(), null, new LifecycleCoroutineScopeImpl$register$1(this, null), 2, null);
}
@Override // androidx.lifecycle.LifecycleEventObserver
public void onStateChanged(LifecycleOwner source, Lifecycle.Event event) {
Intrinsics.checkNotNullParameter(source, "source");
Intrinsics.checkNotNullParameter(event, "event");
if (getLifecycle$lifecycle_common().getCurrentState().compareTo(Lifecycle.State.DESTROYED) <= 0) {
getLifecycle$lifecycle_common().removeObserver(this);
JobKt__JobKt.cancel$default(getCoroutineContext(), null, 1, null);
}
}
}