Silent Camera v8.11.1版本的 MD5 值为:461a6aeaae6d6fdb2f75be73cf9b5c5d
以下内容为反编译后的 s0.java 源代码,内容仅作参考
package com.peace.SilentCamera;
import android.app.Activity;
import android.app.AlertDialog;
import android.content.Context;
import android.content.Intent;
import android.graphics.drawable.ColorDrawable;
import android.net.Uri;
import android.os.Build;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.Button;
import java.util.Locale;
class s0 {
App f24277a;
Context f24278b;
private AlertDialog f24279c;
class a implements View.OnClickListener {
a() {
}
@Override
public void onClick(View view) {
App.g("rate_dialog", "action", "rate");
s0.this.f24279c.dismiss();
s0.this.b();
}
}
class b implements View.OnClickListener {
b() {
}
@Override
public void onClick(View view) {
App.g("rate_dialog", "action", "deny");
App.K.f("isEvaluate", true);
s0.this.f24279c.dismiss();
}
}
class c implements View.OnClickListener {
c() {
}
@Override
public void onClick(View view) {
App.g("rate_dialog", "action", "report");
App.K.f("isEvaluate", true);
s0.this.f24279c.dismiss();
s0.this.c();
}
}
class d implements View.OnClickListener {
d() {
}
@Override
public void onClick(View view) {
App.g("rate_dialog", "action", "later");
App.K.g("count", 0);
App.K.h("lastEvaluateDate", System.currentTimeMillis());
s0.this.f24279c.dismiss();
}
}
public s0(Context context, AlertDialog alertDialog) {
this.f24278b = context;
this.f24279c = alertDialog;
this.f24277a = (App) ((Activity) context).getApplication();
}
public void b() {
try {
App.K.f("isEvaluate", true);
Intent intent = new Intent("android.intent.action.VIEW", Uri.parse("https://play.google.com/store/apps/details?id=" + this.f24278b.getPackageName()));
intent.setPackage("com.android.vending");
this.f24278b.startActivity(intent);
} catch (Throwable th) {
App.h(th);
}
}
public void c() {
Intent intent;
try {
if (this.f24278b.getPackageManager().getLaunchIntentForPackage("com.google.android.gm") == null) {
intent = new Intent("android.intent.action.SENDTO", Uri.fromParts("mailto", "support@peace-app.com", null));
} else {
Intent intent2 = new Intent();
intent2.setAction("android.intent.action.SEND");
intent2.setType("text/Gmail");
intent2.putExtra("android.intent.extra.EMAIL", new String[]{"support@peace-app.com"});
intent2.setPackage("com.google.android.gm");
intent = intent2;
}
intent.putExtra("android.intent.extra.SUBJECT", "[" + this.f24278b.getString(C0351R.string.app_name) + "] " + this.f24278b.getString(C0351R.string.evaluate_subject));
intent.putExtra("android.intent.extra.TEXT", this.f24278b.getString(C0351R.string.evaluate_text) + "\n\n\n\n\n[Device]\nVendor: " + Build.MANUFACTURER + "\nModel: " + Build.DEVICE + " (" + Build.MODEL + ")\nAndroid: " + Build.VERSION.RELEASE + "\nVersion: 307 ");
this.f24278b.startActivity(intent);
} catch (Throwable th) {
App.h(th);
}
}
public boolean d() {
if (App.K.a("isEvaluate", false)) {
return false;
}
int b10 = App.K.b("count", 0);
int currentTimeMillis = (int) ((System.currentTimeMillis() - App.K.c("lastEvaluateDate", 0L).longValue()) / 86400000);
int b11 = App.K.b("uncaughtException", 0);
int i9 = 20;
try {
if (Locale.getDefault().getLanguage().equals("in")) {
i9 = 40;
}
} catch (Throwable th) {
App.h(th);
}
return b10 >= i9 && currentTimeMillis >= 0 && b11 <= 0;
}
public void e() {
AlertDialog alertDialog = this.f24279c;
if (alertDialog == null || !alertDialog.isShowing()) {
View inflate = ((LayoutInflater) this.f24278b.getSystemService("layout_inflater")).inflate(C0351R.layout.dialog_rate, (ViewGroup) ((Activity) this.f24278b).findViewById(C0351R.id.linearLayoutRateDialog));
AlertDialog.Builder builder = new AlertDialog.Builder(this.f24278b);
builder.setView(inflate);
builder.setCancelable(false);
AlertDialog create = builder.create();
this.f24279c = create;
try {
create.getWindow().setBackgroundDrawable(new ColorDrawable(0));
} catch (Throwable th) {
App.h(th);
}
((Button) inflate.findViewById(C0351R.id.PositiveButton)).setOnClickListener(new a());
((Button) inflate.findViewById(C0351R.id.NegativeButton)).setOnClickListener(new b());
((Button) inflate.findViewById(C0351R.id.ReportButton)).setOnClickListener(new c());
((Button) inflate.findViewById(C0351R.id.NeutralButton)).setOnClickListener(new d());
if (((Activity) this.f24278b).isFinishing()) {
return;
}
this.f24279c.show();
}
}
}