- 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
64 lines
2.1 KiB
Java
64 lines
2.1 KiB
Java
package com.unity3d.services.banners;
|
|
|
|
import android.content.Context;
|
|
import com.unity3d.services.core.misc.ViewUtilities;
|
|
import com.vungle.ads.internal.protos.Sdk;
|
|
import kotlin.jvm.internal.DefaultConstructorMarker;
|
|
import kotlin.jvm.internal.Intrinsics;
|
|
import kotlin.math.MathKt__MathJVMKt;
|
|
|
|
/* loaded from: classes4.dex */
|
|
public final class UnityBannerSize {
|
|
private final int height;
|
|
private final int width;
|
|
public static final Companion Companion = new Companion(null);
|
|
private static final UnityBannerSize leaderboard = new UnityBannerSize(728, 90);
|
|
private static final UnityBannerSize iabStandard = new UnityBannerSize(468, 60);
|
|
private static final UnityBannerSize standard = new UnityBannerSize(Sdk.SDKError.Reason.WEBVIEW_ERROR_VALUE, 50);
|
|
|
|
public static final UnityBannerSize getDynamicSize(Context context) {
|
|
return Companion.getDynamicSize(context);
|
|
}
|
|
|
|
public final int getHeight() {
|
|
return this.height;
|
|
}
|
|
|
|
public final int getWidth() {
|
|
return this.width;
|
|
}
|
|
|
|
public static final class Companion {
|
|
public /* synthetic */ Companion(DefaultConstructorMarker defaultConstructorMarker) {
|
|
this();
|
|
}
|
|
|
|
private Companion() {
|
|
}
|
|
|
|
public final UnityBannerSize getLeaderboard() {
|
|
return UnityBannerSize.leaderboard;
|
|
}
|
|
|
|
public final UnityBannerSize getIabStandard() {
|
|
return UnityBannerSize.iabStandard;
|
|
}
|
|
|
|
public final UnityBannerSize getStandard() {
|
|
return UnityBannerSize.standard;
|
|
}
|
|
|
|
public final UnityBannerSize getDynamicSize(Context context) {
|
|
int roundToInt;
|
|
Intrinsics.checkNotNullParameter(context, "context");
|
|
roundToInt = MathKt__MathJVMKt.roundToInt(ViewUtilities.dpFromPx(context, context.getResources().getDisplayMetrics().widthPixels));
|
|
return roundToInt >= getLeaderboard().getWidth() ? getLeaderboard() : roundToInt >= getIabStandard().getWidth() ? getIabStandard() : getStandard();
|
|
}
|
|
}
|
|
|
|
public UnityBannerSize(int i, int i2) {
|
|
this.width = i;
|
|
this.height = i2;
|
|
}
|
|
}
|