Rabbit-R1/original r1/java/sources/androidx/compose/material3/EnterAlwaysScrollBehavior$nestedScrollConnection$1.java

140 lines
8.3 KiB
Java
Raw Normal View History

2024-05-21 16:08:36 -05:00
package androidx.compose.material3;
import androidx.compose.ui.geometry.Offset;
import androidx.compose.ui.input.nestedscroll.NestedScrollConnection;
import io.sentry.protocol.TransactionInfo;
import kotlin.Metadata;
/* compiled from: AppBar.kt */
@Metadata(d1 = {"\u0000!\n\u0000\n\u0002\u0018\u0002\n\u0000\n\u0002\u0018\u0002\n\u0002\b\u0005\n\u0002\u0018\u0002\n\u0000\n\u0002\u0018\u0002\n\u0002\b\u0006*\u0001\u0000\b\n\u0018\u00002\u00020\u0001J)\u0010\u0002\u001a\u00020\u00032\u0006\u0010\u0004\u001a\u00020\u00032\u0006\u0010\u0005\u001a\u00020\u0003H\u0096@ø\u0001\u0000ø\u0001\u0001ø\u0001\u0001¢\u0006\u0004\b\u0006\u0010\u0007J-\u0010\b\u001a\u00020\t2\u0006\u0010\u0004\u001a\u00020\t2\u0006\u0010\u0005\u001a\u00020\t2\u0006\u0010\n\u001a\u00020\u000bH\u0016ø\u0001\u0000ø\u0001\u0001¢\u0006\u0004\b\f\u0010\rJ%\u0010\u000e\u001a\u00020\t2\u0006\u0010\u0005\u001a\u00020\t2\u0006\u0010\n\u001a\u00020\u000bH\u0016ø\u0001\u0000ø\u0001\u0001¢\u0006\u0004\b\u000f\u0010\u0010\u0082\u0002\u000b\n\u0005\\u001e0\u0001\n\u0002\b\u0019¨\u0006\u0011"}, d2 = {"androidx/compose/material3/EnterAlwaysScrollBehavior$nestedScrollConnection$1", "Landroidx/compose/ui/input/nestedscroll/NestedScrollConnection;", "onPostFling", "Landroidx/compose/ui/unit/Velocity;", "consumed", "available", "onPostFling-RZ2iAVY", "(JJLkotlin/coroutines/Continuation;)Ljava/lang/Object;", "onPostScroll", "Landroidx/compose/ui/geometry/Offset;", TransactionInfo.JsonKeys.SOURCE, "Landroidx/compose/ui/input/nestedscroll/NestedScrollSource;", "onPostScroll-DzOQY0M", "(JJI)J", "onPreScroll", "onPreScroll-OzD1aCk", "(JI)J", "material3_release"}, k = 1, mv = {1, 8, 0}, xi = 48)
/* loaded from: classes.dex */
public final class EnterAlwaysScrollBehavior$nestedScrollConnection$1 implements NestedScrollConnection {
final /* synthetic */ EnterAlwaysScrollBehavior this$0;
/* JADX INFO: Access modifiers changed from: package-private */
public EnterAlwaysScrollBehavior$nestedScrollConnection$1(EnterAlwaysScrollBehavior enterAlwaysScrollBehavior) {
this.this$0 = enterAlwaysScrollBehavior;
}
@Override // androidx.compose.ui.input.nestedscroll.NestedScrollConnection
/* renamed from: onPreScroll-OzD1aCk */
public long mo344onPreScrollOzD1aCk(long available, int source) {
if (!this.this$0.getCanScroll().invoke().booleanValue()) {
return Offset.INSTANCE.m2416getZeroF1C5BW0();
}
float heightOffset = this.this$0.getState().getHeightOffset();
this.this$0.getState().setHeightOffset(this.this$0.getState().getHeightOffset() + Offset.m2401getYimpl(available));
if (heightOffset != this.this$0.getState().getHeightOffset()) {
return Offset.m2394copydBAh8RU$default(available, 0.0f, 0.0f, 2, null);
}
return Offset.INSTANCE.m2416getZeroF1C5BW0();
}
@Override // androidx.compose.ui.input.nestedscroll.NestedScrollConnection
/* renamed from: onPostScroll-DzOQY0M */
public long mo343onPostScrollDzOQY0M(long consumed, long available, int source) {
if (!this.this$0.getCanScroll().invoke().booleanValue()) {
return Offset.INSTANCE.m2416getZeroF1C5BW0();
}
TopAppBarState state = this.this$0.getState();
state.setContentOffset(state.getContentOffset() + Offset.m2401getYimpl(consumed));
if ((this.this$0.getState().getHeightOffset() == 0.0f || this.this$0.getState().getHeightOffset() == this.this$0.getState().getHeightOffsetLimit()) && Offset.m2401getYimpl(consumed) == 0.0f && Offset.m2401getYimpl(available) > 0.0f) {
this.this$0.getState().setContentOffset(0.0f);
}
this.this$0.getState().setHeightOffset(this.this$0.getState().getHeightOffset() + Offset.m2401getYimpl(consumed));
return Offset.INSTANCE.m2416getZeroF1C5BW0();
}
/* JADX WARN: Removed duplicated region for block: B:19:0x007e A[RETURN] */
/* JADX WARN: Removed duplicated region for block: B:20:0x007f */
/* JADX WARN: Removed duplicated region for block: B:21:0x0041 */
/* JADX WARN: Removed duplicated region for block: B:8:0x0025 */
@Override // androidx.compose.ui.input.nestedscroll.NestedScrollConnection
/* renamed from: onPostFling-RZ2iAVY */
/*
Code decompiled incorrectly, please refer to instructions dump.
To view partially-correct add '--show-bad-code' argument
*/
public java.lang.Object mo342onPostFlingRZ2iAVY(long r10, long r12, kotlin.coroutines.Continuation<? super androidx.compose.ui.unit.Velocity> r14) {
/*
r9 = this;
boolean r0 = r14 instanceof androidx.compose.material3.EnterAlwaysScrollBehavior$nestedScrollConnection$1$onPostFling$1
if (r0 == 0) goto L14
r0 = r14
androidx.compose.material3.EnterAlwaysScrollBehavior$nestedScrollConnection$1$onPostFling$1 r0 = (androidx.compose.material3.EnterAlwaysScrollBehavior$nestedScrollConnection$1$onPostFling$1) r0
int r1 = r0.label
r2 = -2147483648(0xffffffff80000000, float:-0.0)
r1 = r1 & r2
if (r1 == 0) goto L14
int r14 = r0.label
int r14 = r14 - r2
r0.label = r14
goto L19
L14:
androidx.compose.material3.EnterAlwaysScrollBehavior$nestedScrollConnection$1$onPostFling$1 r0 = new androidx.compose.material3.EnterAlwaysScrollBehavior$nestedScrollConnection$1$onPostFling$1
r0.<init>(r9, r14)
L19:
java.lang.Object r14 = r0.result
java.lang.Object r7 = kotlin.coroutines.intrinsics.IntrinsicsKt.getCOROUTINE_SUSPENDED()
int r1 = r0.label
r8 = 2
r2 = 1
if (r1 == 0) goto L41
if (r1 == r2) goto L37
if (r1 != r8) goto L2f
long r9 = r0.J$0
kotlin.ResultKt.throwOnFailure(r14)
goto L80
L2f:
java.lang.IllegalStateException r9 = new java.lang.IllegalStateException
java.lang.String r10 = "call to 'resume' before 'invoke' with coroutine"
r9.<init>(r10)
throw r9
L37:
long r12 = r0.J$0
java.lang.Object r9 = r0.L$0
androidx.compose.material3.EnterAlwaysScrollBehavior$nestedScrollConnection$1 r9 = (androidx.compose.material3.EnterAlwaysScrollBehavior$nestedScrollConnection$1) r9
kotlin.ResultKt.throwOnFailure(r14)
goto L55
L41:
kotlin.ResultKt.throwOnFailure(r14)
r0.L$0 = r9
r0.J$0 = r12
r0.label = r2
r1 = r9
r2 = r10
r4 = r12
r6 = r0
java.lang.Object r14 = super.mo342onPostFlingRZ2iAVY(r2, r4, r6)
if (r14 != r7) goto L55
return r7
L55:
androidx.compose.ui.unit.Velocity r14 = (androidx.compose.ui.unit.Velocity) r14
long r10 = r14.getPackedValue()
androidx.compose.material3.EnterAlwaysScrollBehavior r14 = r9.this$0
androidx.compose.material3.TopAppBarState r14 = r14.getState()
float r12 = androidx.compose.ui.unit.Velocity.m5109getYimpl(r12)
androidx.compose.material3.EnterAlwaysScrollBehavior r13 = r9.this$0
androidx.compose.animation.core.DecayAnimationSpec r13 = r13.getFlingAnimationSpec()
androidx.compose.material3.EnterAlwaysScrollBehavior r9 = r9.this$0
androidx.compose.animation.core.AnimationSpec r9 = r9.getSnapAnimationSpec()
r1 = 0
r0.L$0 = r1
r0.J$0 = r10
r0.label = r8
java.lang.Object r14 = androidx.compose.material3.AppBarKt.access$settleAppBar(r14, r12, r13, r9, r0)
if (r14 != r7) goto L7f
return r7
L7f:
r9 = r10
L80:
androidx.compose.ui.unit.Velocity r14 = (androidx.compose.ui.unit.Velocity) r14
long r11 = r14.getPackedValue()
long r9 = androidx.compose.ui.unit.Velocity.m5112plusAH228Gc(r9, r11)
androidx.compose.ui.unit.Velocity r9 = androidx.compose.ui.unit.Velocity.m5099boximpl(r9)
return r9
*/
throw new UnsupportedOperationException("Method not decompiled: androidx.compose.material3.EnterAlwaysScrollBehavior$nestedScrollConnection$1.mo342onPostFlingRZ2iAVY(long, long, kotlin.coroutines.Continuation):java.lang.Object");
}
}