mirror of
https://github.com/VibedByKaKi/alexandroid.git
synced 2026-11-15 18:37:17 +01:00
53 lines
4.3 KiB
Java
53 lines
4.3 KiB
Java
package androidx.compose.ui.window;
|
|
|
|
import androidx.compose.runtime.internal.StabilityInferred;
|
|
import androidx.compose.ui.Alignment;
|
|
import androidx.compose.ui.unit.IntOffset;
|
|
import androidx.compose.ui.unit.IntRect;
|
|
import androidx.compose.ui.unit.IntSize;
|
|
import androidx.compose.ui.unit.LayoutDirection;
|
|
import com.facebook.react.uimanager.ViewProps;
|
|
import kotlin.Metadata;
|
|
import kotlin.jvm.internal.DefaultConstructorMarker;
|
|
import kotlin.jvm.internal.SourceDebugExtension;
|
|
import org.jetbrains.annotations.NotNull;
|
|
|
|
/* compiled from: r8-map-id-b9432e0f623b4a4bff4ba50a8a24c4aafad2c1e11092747b9fb5e6a22af5a940 */
|
|
@StabilityInferred(parameters = 1)
|
|
@Metadata(d1 = {"\u0000,\n\u0002\u0018\u0002\n\u0002\u0018\u0002\n\u0000\n\u0002\u0018\u0002\n\u0000\n\u0002\u0018\u0002\n\u0002\b\t\n\u0002\u0018\u0002\n\u0000\n\u0002\u0018\u0002\n\u0000\n\u0002\u0018\u0002\n\u0002\b\u0004\b\u0001\u0018\u00002\u00020\u0001B\u0017\u0012\u0006\u0010\u0002\u001a\u00020\u0003\u0012\u0006\u0010\u0004\u001a\u00020\u0005¢\u0006\u0004\b\u0006\u0010\u0007J/\u0010\r\u001a\u00020\u00052\u0006\u0010\u000e\u001a\u00020\u000f2\u0006\u0010\u0010\u001a\u00020\u00112\u0006\u0010\u0012\u001a\u00020\u00132\u0006\u0010\u0014\u001a\u00020\u0011H\u0016¢\u0006\u0004\b\u0015\u0010\u0016R\u0011\u0010\u0002\u001a\u00020\u0003¢\u0006\b\n\u0000\u001a\u0004\b\b\u0010\tR\u0013\u0010\u0004\u001a\u00020\u0005¢\u0006\n\n\u0002\u0010\f\u001a\u0004\b\n\u0010\u000b¨\u0006\u0017"}, d2 = {"Landroidx/compose/ui/window/AlignmentOffsetPositionProvider;", "Landroidx/compose/ui/window/PopupPositionProvider;", "alignment", "Landroidx/compose/ui/Alignment;", "offset", "Landroidx/compose/ui/unit/IntOffset;", "<init>", "(Landroidx/compose/ui/Alignment;JLkotlin/jvm/internal/DefaultConstructorMarker;)V", "getAlignment", "()Landroidx/compose/ui/Alignment;", "getOffset-nOcc-ac", "()J", "J", "calculatePosition", "anchorBounds", "Landroidx/compose/ui/unit/IntRect;", "windowSize", "Landroidx/compose/ui/unit/IntSize;", ViewProps.LAYOUT_DIRECTION, "Landroidx/compose/ui/unit/LayoutDirection;", "popupContentSize", "calculatePosition-llwVHH4", "(Landroidx/compose/ui/unit/IntRect;JLandroidx/compose/ui/unit/LayoutDirection;J)J", "ui_release"}, k = 1, mv = {2, 0, 0}, xi = 48)
|
|
@SourceDebugExtension({"SMAP\nPopup.kt\nKotlin\n*S Kotlin\n*F\n+ 1 Popup.kt\nandroidx/compose/ui/window/AlignmentOffsetPositionProvider\n+ 2 IntOffset.kt\nandroidx/compose/ui/unit/IntOffsetKt\n+ 3 InlineClassHelper.kt\nandroidx/compose/ui/util/InlineClassHelperKt\n*L\n1#1,150:1\n32#2:151\n80#3:152\n*S KotlinDebug\n*F\n+ 1 Popup.kt\nandroidx/compose/ui/window/AlignmentOffsetPositionProvider\n*L\n95#1:151\n95#1:152\n*E\n"})
|
|
/* loaded from: classes13.dex */
|
|
public final class AlignmentOffsetPositionProvider implements PopupPositionProvider {
|
|
public static final int $stable = 0;
|
|
|
|
@NotNull
|
|
private final Alignment alignment;
|
|
private final long offset;
|
|
|
|
private AlignmentOffsetPositionProvider(Alignment alignment, long j) {
|
|
this.alignment = alignment;
|
|
this.offset = j;
|
|
}
|
|
|
|
@Override // androidx.compose.ui.window.PopupPositionProvider
|
|
/* renamed from: calculatePosition-llwVHH4 */
|
|
public long mo529calculatePositionllwVHH4(@NotNull IntRect anchorBounds, long windowSize, @NotNull LayoutDirection layoutDirection, long popupContentSize) {
|
|
Alignment alignment = this.alignment;
|
|
IntSize.Companion companion = IntSize.INSTANCE;
|
|
return IntOffset.m7500plusqkQi6aY(IntOffset.m7500plusqkQi6aY(IntOffset.m7500plusqkQi6aY(anchorBounds.m7525getTopLeftnOccac(), alignment.mo4123alignKFBX0sM(companion.m7544getZeroYbymL2g(), anchorBounds.m7523getSizeYbymL2g(), layoutDirection)), IntOffset.m7504unaryMinusnOccac(this.alignment.mo4123alignKFBX0sM(companion.m7544getZeroYbymL2g(), popupContentSize, layoutDirection))), IntOffset.m7490constructorimpl(((IntOffset.m7496getXimpl(this.offset) * (layoutDirection == LayoutDirection.Ltr ? 1 : -1)) << 32) | (IntOffset.m7497getYimpl(this.offset) & 4294967295L)));
|
|
}
|
|
|
|
@NotNull
|
|
public final Alignment getAlignment() {
|
|
return this.alignment;
|
|
}
|
|
|
|
/* renamed from: getOffset-nOcc-ac, reason: not valid java name and from getter */
|
|
public final long getOffset() {
|
|
return this.offset;
|
|
}
|
|
|
|
public /* synthetic */ AlignmentOffsetPositionProvider(Alignment alignment, long j, DefaultConstructorMarker defaultConstructorMarker) {
|
|
this(alignment, j);
|
|
}
|
|
}
|