mirror of
https://github.com/VibedByKaKi/alexandroid.git
synced 2026-11-17 11:27:17 +01:00
52 lines
2.4 KiB
Java
52 lines
2.4 KiB
Java
package androidx.compose.foundation;
|
|
|
|
import android.content.Context;
|
|
import android.util.AttributeSet;
|
|
import android.widget.EdgeEffect;
|
|
import androidx.annotation.DoNotInline;
|
|
import androidx.annotation.RequiresApi;
|
|
import kotlin.Metadata;
|
|
import org.jetbrains.annotations.NotNull;
|
|
import org.jetbrains.annotations.Nullable;
|
|
|
|
/* compiled from: r8-map-id-b9432e0f623b4a4bff4ba50a8a24c4aafad2c1e11092747b9fb5e6a22af5a940 */
|
|
@RequiresApi(31)
|
|
@Metadata(d1 = {"\u0000&\n\u0002\u0018\u0002\n\u0002\u0010\u0000\n\u0002\b\u0002\n\u0002\u0018\u0002\n\u0000\n\u0002\u0018\u0002\n\u0000\n\u0002\u0018\u0002\n\u0000\n\u0002\u0010\u0007\n\u0002\b\u0005\bÃ\u0002\u0018\u00002\u00020\u0001B\u0007\b\u0002¢\u0006\u0002\u0010\u0002J\u001a\u0010\u0003\u001a\u00020\u00042\u0006\u0010\u0005\u001a\u00020\u00062\b\u0010\u0007\u001a\u0004\u0018\u00010\bH\u0007J\u0010\u0010\t\u001a\u00020\n2\u0006\u0010\u000b\u001a\u00020\u0004H\u0007J \u0010\f\u001a\u00020\n2\u0006\u0010\u000b\u001a\u00020\u00042\u0006\u0010\r\u001a\u00020\n2\u0006\u0010\u000e\u001a\u00020\nH\u0007¨\u0006\u000f"}, d2 = {"Landroidx/compose/foundation/Api31Impl;", "", "()V", "create", "Landroid/widget/EdgeEffect;", "context", "Landroid/content/Context;", "attrs", "Landroid/util/AttributeSet;", "getDistance", "", "edgeEffect", "onPullDistance", "deltaDistance", "displacement", "foundation_release"}, k = 1, mv = {1, 8, 0}, xi = 48)
|
|
/* loaded from: classes.dex */
|
|
final class Api31Impl {
|
|
|
|
@NotNull
|
|
public static final Api31Impl INSTANCE = new Api31Impl();
|
|
|
|
private Api31Impl() {
|
|
}
|
|
|
|
@DoNotInline
|
|
@NotNull
|
|
public final EdgeEffect create(@NotNull Context context, @Nullable AttributeSet attrs) {
|
|
try {
|
|
return new EdgeEffect(context, attrs);
|
|
} catch (Throwable unused) {
|
|
return new EdgeEffect(context);
|
|
}
|
|
}
|
|
|
|
@DoNotInline
|
|
public final float getDistance(@NotNull EdgeEffect edgeEffect) {
|
|
try {
|
|
return edgeEffect.getDistance();
|
|
} catch (Throwable unused) {
|
|
return 0.0f;
|
|
}
|
|
}
|
|
|
|
@DoNotInline
|
|
public final float onPullDistance(@NotNull EdgeEffect edgeEffect, float deltaDistance, float displacement) {
|
|
try {
|
|
return edgeEffect.onPullDistance(deltaDistance, displacement);
|
|
} catch (Throwable unused) {
|
|
edgeEffect.onPull(deltaDistance, displacement);
|
|
return 0.0f;
|
|
}
|
|
}
|
|
}
|