正在查看: Perplexity v2.48.1 应用的 AppWidget2Receiver.java JAVA 源代码文件
本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。
正在查看: Perplexity v2.48.1 应用的 AppWidget2Receiver.java JAVA 源代码文件
本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。
package ai.perplexity.app.android.ui.widget;
import G2.C0178p0;
import android.appwidget.AppWidgetManager;
import android.appwidget.AppWidgetProvider;
import android.content.Context;
import android.content.res.Resources;
import android.os.Build;
import android.util.Log;
import android.widget.RemoteViews;
import bl.b;
import g3.o0;
import i7.f;
import java.util.ArrayList;
import java.util.Iterator;
import java.util.List;
import kotlin.Metadata;
import kotlin.jvm.internal.Intrinsics;
import m7.C3296a;
import m7.C3300e;
import nn.j;
@Metadata(d1 = {"\u0000\f\n\u0002\u0018\u0002\n\u0002\u0018\u0002\n\u0002\b\u0003\b\u0007\u0018\u00002\u00020\u0001B\u0007¢\u0006\u0004\b\u0002\u0010\u0003¨\u0006\u0004"}, d2 = {"Lai/perplexity/app/android/ui/widget/AppWidget2Receiver;", "Landroid/appwidget/AppWidgetProvider;", "<init>", "()V", "PerplexityAndroid_v260454(2.48.1)_20250618_122841_release"}, k = 1, mv = {2, 1, 0}, xi = 48)
public final class AppWidget2Receiver extends AppWidgetProvider {
public static final int f19579a = 0;
@Override
public final void onUpdate(Context context, AppWidgetManager appWidgetManager, int[] iArr) {
Object next;
Object next2;
Object next3;
RemoteViews remoteViews;
Context context2 = context;
Intrinsics.h(context2, "context");
Intrinsics.h(appWidgetManager, "appWidgetManager");
Intrinsics.h(iArr, "appWidgetIds");
Resources resources = context2.getResources();
float integer = resources.getInteger(2131492870);
float integer2 = resources.getInteger(2131492867);
float f4 = integer2 + integer;
float f10 = f4 + integer;
float integer3 = resources.getInteger(2131492868);
float integer4 = resources.getInteger(2131492869);
float integer5 = resources.getInteger(2131492873);
float integer6 = resources.getInteger(2131492871);
float f11 = integer6 + integer5;
float integer7 = resources.getInteger(2131492872);
List e02 = b.e0(new f[]{new f(integer2, integer4), new f(f4, integer4), new f(f10, integer4), new f(integer + f10, integer4), new f(integer3, integer4), new f(integer6, integer7), new f(f11, integer7), new f(integer5 + f11, integer7)});
int length = iArr.length;
int i10 = 0;
while (i10 < length) {
int i11 = iArr[i10];
C0178p0 c0178p0 = new C0178p0(e02, this, context2, i11);
Intrinsics.h(e02, "dpSizes");
if (appWidgetManager.getAppWidgetInfo(i11) == null) {
throw new IllegalArgumentException(j.d(i11, "Invalid app widget id: ").toString());
}
if (e02.isEmpty()) {
throw new IllegalArgumentException("Sizes cannot be empty");
}
if (e02.size() > 16) {
throw new IllegalArgumentException("At most 16 sizes may be provided");
}
if (Build.VERSION.SDK_INT >= 31) {
remoteViews = C3296a.f35917a.b(e02, c0178p0);
} else {
Iterator it = e02.iterator();
if (it.hasNext()) {
next = it.next();
if (it.hasNext()) {
float w2 = o0.w((f) next);
do {
Object next4 = it.next();
float w10 = o0.w((f) next4);
if (Float.compare(w2, w10) > 0) {
next = next4;
w2 = w10;
}
} while (it.hasNext());
}
} else {
next = null;
}
f fVar = (f) next;
if (fVar == null) {
throw new IllegalStateException("Sizes cannot be empty");
}
C3300e z10 = o0.z(appWidgetManager, i11);
if (z10 == null) {
Log.w("AppWidgetManagerCompat", "App widget sizes not found in the options bundle, falling back to the smallest supported size (" + fVar + ')');
z10 = new C3300e(fVar, fVar);
}
ArrayList arrayList = new ArrayList();
for (Object obj : e02) {
if (o0.q(z10.f35927a, (f) obj)) {
arrayList.add(obj);
}
}
Iterator it2 = arrayList.iterator();
if (it2.hasNext()) {
next2 = it2.next();
if (it2.hasNext()) {
float w11 = o0.w((f) next2);
do {
Object next5 = it2.next();
float w12 = o0.w((f) next5);
if (Float.compare(w11, w12) < 0) {
next2 = next5;
w11 = w12;
}
} while (it2.hasNext());
}
} else {
next2 = null;
}
f fVar2 = (f) next2;
f fVar3 = fVar2 == null ? fVar : fVar2;
ArrayList arrayList2 = new ArrayList();
for (Object obj2 : e02) {
if (o0.q(z10.f35928b, (f) obj2)) {
arrayList2.add(obj2);
}
}
Iterator it3 = arrayList2.iterator();
if (it3.hasNext()) {
next3 = it3.next();
if (it3.hasNext()) {
float w13 = o0.w((f) next3);
do {
Object next6 = it3.next();
float w14 = o0.w((f) next6);
if (Float.compare(w13, w14) < 0) {
next3 = next6;
w13 = w14;
}
} while (it3.hasNext());
}
} else {
next3 = null;
}
f fVar4 = (f) next3;
if (fVar4 != null) {
fVar = fVar4;
}
remoteViews = fVar3.equals(fVar) ? (RemoteViews) c0178p0.invoke(fVar3) : new RemoteViews((RemoteViews) c0178p0.invoke(fVar3), (RemoteViews) c0178p0.invoke(fVar));
}
appWidgetManager.updateAppWidget(i11, remoteViews);
i10++;
context2 = context;
}
}
}