Sunbit v2.4.4版本的 MD5 值为:a5021e5e2a58eb1d6741b432fe7533c4
以下内容为反编译后的 r.java 源代码,内容仅作参考
package io.bibeex.contract.util.k1;
import android.content.Context;
import android.content.DialogInterface;
import android.content.Intent;
import android.text.Editable;
import android.text.InputFilter;
import android.text.SpannableString;
import android.text.TextUtils;
import android.text.TextWatcher;
import android.text.style.ForegroundColorSpan;
import android.view.View;
import android.view.Window;
import android.view.WindowManager;
import android.webkit.JavascriptInterface;
import android.webkit.WebView;
import android.webkit.WebViewClient;
import android.widget.Button;
import android.widget.EditText;
import android.widget.ImageView;
import android.widget.TextView;
import androidx.appcompat.app.AlertDialog;
import androidx.lifecycle.LifecycleOwner;
import androidx.recyclerview.widget.LinearLayoutManager;
import androidx.recyclerview.widget.RecyclerView;
import io.bibeex.contract.base.adapter.BaseAdapter;
import io.bibeex.contract.base.adapter.BaseViewHolder;
import io.bibeex.contract.common.bean.hpx.Charge;
import io.bibeex.contract.common.bean.task.TaskBean;
import io.bibeex.contract.common.utlis.AutoObservable;
import io.bibeex.contract.ui.activity.MainWebviewActivity;
import io.bibeex.contract.ui.fragment.task.TaskDetailAdapter;
import io.bilian.aavys.sunbit.R;
import java.util.List;
public class r {
public static final float f18315f = 0.86f;
private static r f18316g;
private AlertDialog f18317a;
private c2 b;
int c = 1;
double f18318d = 0.0d;
private b2 f18319e;
class a implements View.OnClickListener {
a() {
}
@Override
public void onClick(View view) {
if (r.this.f18317a != null) {
r.this.f18317a.dismiss();
r.this.f18317a = null;
}
}
}
class a0 implements DialogInterface.OnDismissListener {
a0() {
}
@Override
public void onDismiss(DialogInterface dialogInterface) {
if (r.this.b != null) {
r.this.b = null;
}
r.this.f18317a = null;
}
}
class a1 implements View.OnClickListener {
final c2 f18322a;
final View b;
a1(c2 c2Var, View view) {
this.f18322a = c2Var;
this.b = view;
}
@Override
public void onClick(View view) {
c2 c2Var = this.f18322a;
if (c2Var != null) {
c2Var.b(r.this.f18317a, this.b);
}
}
}
public interface a2 {
void a(TextView textView, String... strArr);
void a(String... strArr);
}
class b implements DialogInterface.OnDismissListener {
b() {
}
@Override
public void onDismiss(DialogInterface dialogInterface) {
if (r.this.b != null) {
r.this.b = null;
}
r.this.f18317a = null;
}
}
class b0 implements View.OnClickListener {
b0() {
}
@Override
public void onClick(View view) {
if (r.this.f18317a != null) {
r.this.f18317a.dismiss();
}
}
}
class b1 implements DialogInterface.OnDismissListener {
b1() {
}
@Override
public void onDismiss(DialogInterface dialogInterface) {
r.this.f18317a = null;
}
}
public interface b2 {
void a(String str);
}
class c implements DialogInterface.OnDismissListener {
final View.OnClickListener f18326a;
final Context b;
c(View.OnClickListener onClickListener, Context context) {
this.f18326a = onClickListener;
this.b = context;
}
@Override
public void onDismiss(DialogInterface dialogInterface) {
if (r.this.b != null) {
r.this.b = null;
}
this.f18326a.onClick(new View(this.b));
r.this.f18317a = null;
}
}
class c0 implements DialogInterface.OnDismissListener {
c0() {
}
@Override
public void onDismiss(DialogInterface dialogInterface) {
if (r.this.b != null) {
r.this.b = null;
}
r.this.f18317a = null;
}
}
class c1 implements View.OnClickListener {
c1() {
}
@Override
public void onClick(View view) {
if (r.this.f18317a != null) {
r.this.f18317a.dismiss();
r.this.f18317a = null;
}
}
}
public static abstract class c2 {
public abstract void a(AlertDialog alertDialog, View view);
public void a(AlertDialog alertDialog, View view, int i2, String str) {
}
public void a(AlertDialog alertDialog, View view, String str) {
}
public abstract void b(AlertDialog alertDialog, View view);
}
class d implements View.OnClickListener {
d() {
}
@Override
public void onClick(View view) {
if (r.this.f18317a != null) {
r.this.f18317a.dismiss();
r.this.f18317a = null;
}
}
}
public class d0 implements View.OnClickListener {
d0() {
}
@Override
public void onClick(View view) {
if (r.this.f18317a != null) {
r.this.f18317a.dismiss();
}
}
}
class d1 implements View.OnClickListener {
final c2 f18331a;
d1(c2 c2Var) {
this.f18331a = c2Var;
}
@Override
public void onClick(View view) {
c2 c2Var = this.f18331a;
if (c2Var != null) {
c2Var.a(r.this.f18317a, view);
}
if (r.this.f18317a != null) {
r.this.f18317a.dismiss();
}
}
}
public class d2 {
public d2() {
}
@JavascriptInterface
public void getVerityData(String str) {
r.this.f18319e.a(str);
}
}
class e implements View.OnClickListener {
e() {
}
@Override
public void onClick(View view) {
if (r.this.b != null) {
r.this.b.a(r.this.f18317a, view);
}
}
}
public class e0 implements View.OnClickListener {
e0() {
}
@Override
public void onClick(View view) {
if (r.this.f18317a != null) {
r.this.f18317a.dismiss();
}
}
}
class e1 implements View.OnClickListener {
final c2 f18335a;
final View b;
e1(c2 c2Var, View view) {
this.f18335a = c2Var;
this.b = view;
}
@Override
public void onClick(View view) {
c2 c2Var = this.f18335a;
if (c2Var != null) {
c2Var.b(r.this.f18317a, this.b);
}
}
}
class f implements View.OnClickListener {
f() {
}
@Override
public void onClick(View view) {
if (r.this.b != null) {
r.this.b.b(r.this.f18317a, view);
}
}
}
public class f0 implements DialogInterface.OnDismissListener {
f0() {
}
@Override
public void onDismiss(DialogInterface dialogInterface) {
r.this.f18317a = null;
}
}
class f1 implements DialogInterface.OnDismissListener {
f1() {
}
@Override
public void onDismiss(DialogInterface dialogInterface) {
r.this.f18317a = null;
}
}
class g implements DialogInterface.OnDismissListener {
g() {
}
@Override
public void onDismiss(DialogInterface dialogInterface) {
if (r.this.b != null) {
r.this.b = null;
}
r.this.f18317a = null;
}
}
public class g0 implements View.OnClickListener {
g0() {
}
@Override
public void onClick(View view) {
if (r.this.f18317a != null) {
r.this.f18317a.dismiss();
r.this.f18317a = null;
}
}
}
class g1 implements View.OnClickListener {
g1() {
}
@Override
public void onClick(View view) {
if (r.this.f18317a != null) {
r.this.f18317a.dismiss();
r.this.f18317a = null;
}
}
}
class h implements View.OnClickListener {
h() {
}
@Override
public void onClick(View view) {
if (r.this.b != null) {
r.this.b.a(r.this.f18317a, view);
}
}
}
class h0 implements DialogInterface.OnDismissListener {
h0() {
}
@Override
public void onDismiss(DialogInterface dialogInterface) {
r.this.f18317a = null;
}
}
class h1 implements r.s.p<CharSequence, Object> {
final TextView f18344a;
final String b;
final EditText c;
final Context f18345d;
final int f18346e;
final double f18347f;
h1(TextView textView, String str, EditText editText, Context context, int i2, double d2) {
this.f18344a = textView;
this.b = str;
this.c = editText;
this.f18345d = context;
this.f18346e = i2;
this.f18347f = d2;
}
@Override
public Object a(CharSequence charSequence) {
int i2 = r.this.c;
if (i2 == 1) {
TextView textView = this.f18344a;
textView.setText("0 " + this.b);
} else if (i2 == 2) {
this.f18344a.setText("0.00%");
}
if (TextUtils.isEmpty(this.c.getText())) {
return true;
}
r.this.b(this.f18345d, charSequence.toString(), this.f18346e);
int i3 = r.this.c;
if (i3 != 1) {
if (i3 == 2) {
TextView textView2 = this.f18344a;
textView2.setText(io.bibeex.contract.common.utlis.d.a((io.bibeex.contract.common.utlis.d.b(charSequence) * 100.0d) / this.f18347f, 2) + "%");
}
} else if (this.f18346e == 0) {
TextView textView3 = this.f18344a;
textView3.setText(io.bibeex.contract.common.utlis.d.a((io.bibeex.contract.common.utlis.d.b(charSequence) * this.f18347f) / 100.0d, 2) + this.b);
} else {
TextView textView4 = this.f18344a;
textView4.setText(((int) Math.ceil((io.bibeex.contract.common.utlis.d.b(charSequence) * this.f18347f) / 100.0d)) + this.b);
}
return true;
}
}
class i implements View.OnClickListener {
i() {
}
@Override
public void onClick(View view) {
if (r.this.b != null) {
r.this.b.b(r.this.f18317a, view);
}
}
}
class i0 extends BaseAdapter<String, BaseViewHolder> {
i0(Context context, int i2, List list) {
super(context, i2, list);
}
@Override
public void a(BaseViewHolder baseViewHolder, String str) {
baseViewHolder.a(R.id.text_item, str);
}
}
class i1 implements View.OnClickListener {
final EditText f18351a;
final TextView b;
final Context c;
final int f18352d;
final TextView f18353e;
final TextView f18354f;
final TextView f18355g;
final String f18356h;
final TextView f18357i;
i1(EditText editText, TextView textView, Context context, int i2, TextView textView2, TextView textView3, TextView textView4, String str, TextView textView5) {
this.f18351a = editText;
this.b = textView;
this.c = context;
this.f18352d = i2;
this.f18353e = textView2;
this.f18354f = textView3;
this.f18355g = textView4;
this.f18356h = str;
this.f18357i = textView5;
}
@Override
public void onClick(View view) {
int i2 = r.this.c;
if (i2 == 1) {
this.f18351a.setText("");
this.b.setText(this.c.getString(R.string.proportionally));
if (this.f18352d == 0) {
this.f18353e.setText(this.c.getString(R.string.byamount));
} else {
this.f18353e.setText(this.c.getString(R.string.bysheet));
}
this.f18354f.setText(this.c.getString(R.string.estimated_closing_rate));
this.f18355g.setText(this.f18356h);
r.this.c = 2;
if (TextUtils.isEmpty(this.f18351a.getText())) {
this.f18357i.setText("0.00%");
}
} else if (i2 != 2) {
} else {
this.f18351a.setText("");
if (this.f18352d == 0) {
this.b.setText(this.c.getString(R.string.byamount));
} else {
this.b.setText(this.c.getString(R.string.bysheet));
}
this.f18353e.setText(this.c.getString(R.string.proportionally));
this.f18354f.setText(this.c.getString(R.string.estimated_closing_amount));
this.f18355g.setText("%");
r.this.c = 1;
if (TextUtils.isEmpty(this.f18351a.getText())) {
TextView textView = this.f18357i;
textView.setText("0 " + this.f18356h);
}
}
}
}
class j implements DialogInterface.OnDismissListener {
j() {
}
@Override
public void onDismiss(DialogInterface dialogInterface) {
if (r.this.b != null) {
r.this.b = null;
}
r.this.f18317a = null;
}
}
public class j0 implements DialogInterface.OnDismissListener {
j0() {
}
@Override
public void onDismiss(DialogInterface dialogInterface) {
r.this.f18317a = null;
}
}
class j1 implements View.OnClickListener {
j1() {
}
@Override
public void onClick(View view) {
if (r.this.b != null) {
r.this.b.a(r.this.f18317a, view);
}
}
}
class k implements View.OnClickListener {
k() {
}
@Override
public void onClick(View view) {
if (r.this.f18317a != null) {
r.this.f18317a.dismiss();
r.this.f18317a = null;
}
}
}
class k0 implements DialogInterface.OnDismissListener {
k0() {
}
@Override
public void onDismiss(DialogInterface dialogInterface) {
r.this.f18317a = null;
}
}
class k1 implements View.OnClickListener {
final EditText f18364a;
final Context b;
final int c;
k1(EditText editText, Context context, int i2) {
this.f18364a = editText;
this.b = context;
this.c = i2;
}
@Override
public void onClick(View view) {
int i2 = r.this.c;
if (i2 != 1) {
if (i2 == 2 && TextUtils.isEmpty(this.f18364a.getText())) {
Context context = this.b;
io.bibeex.contract.common.d.f.a.c(context, context.getString(R.string.please_price));
return;
}
} else if (TextUtils.isEmpty(this.f18364a.getText())) {
Context context2 = this.b;
io.bibeex.contract.common.d.f.a.c(context2, context2.getString(R.string.please_rate));
return;
}
if (r.this.b(this.b, this.f18364a.getText().toString(), this.c) && r.this.b != null) {
r.this.b.a(r.this.f18317a, view, r.this.c, this.f18364a.getText().toString());
}
}
}
class l implements View.OnClickListener {
l() {
}
@Override
public void onClick(View view) {
if (r.this.f18317a != null) {
r.this.f18317a.dismiss();
r.this.f18317a = null;
}
}
}
class l0 extends WebViewClient {
l0() {
}
@Override
public boolean shouldOverrideUrlLoading(WebView webView, String str) {
webView.loadUrl(str);
return true;
}
}
class l1 implements DialogInterface.OnDismissListener {
l1() {
}
@Override
public void onDismiss(DialogInterface dialogInterface) {
if (r.this.b != null) {
r.this.b = null;
}
r.this.f18317a = null;
}
}
class m implements View.OnClickListener {
m() {
}
@Override
public void onClick(View view) {
if (r.this.b != null) {
r.this.b.a(r.this.f18317a, view);
}
}
}
class m0 implements View.OnClickListener {
m0() {
}
@Override
public void onClick(View view) {
if (r.this.f18317a != null) {
r.this.f18317a.dismiss();
}
}
}
class m1 implements View.OnClickListener {
m1() {
}
@Override
public void onClick(View view) {
if (r.this.f18317a != null) {
r.this.f18317a.dismiss();
r.this.f18317a = null;
}
}
}
class n implements View.OnClickListener {
n() {
}
@Override
public void onClick(View view) {
if (r.this.b != null) {
r.this.b.b(r.this.f18317a, view);
}
}
}
class n0 implements DialogInterface.OnDismissListener {
n0() {
}
@Override
public void onDismiss(DialogInterface dialogInterface) {
r.this.f18317a = null;
}
}
class n1 implements View.OnClickListener {
n1() {
}
@Override
public void onClick(View view) {
r.this.a();
if (r.this.b != null) {
r.this.b.a(r.this.f18317a, view);
}
}
}
class o implements DialogInterface.OnDismissListener {
o() {
}
@Override
public void onDismiss(DialogInterface dialogInterface) {
if (r.this.b != null) {
r.this.b = null;
}
r.this.f18317a = null;
}
}
class o0 implements View.OnClickListener {
o0() {
}
@Override
public void onClick(View view) {
if (r.this.f18317a != null) {
r.this.f18317a.dismiss();
}
}
}
class o1 implements View.OnClickListener {
o1() {
}
@Override
public void onClick(View view) {
if (r.this.b != null) {
r.this.b.a(r.this.f18317a, view);
}
}
}
class p implements View.OnClickListener {
p() {
}
@Override
public void onClick(View view) {
if (r.this.f18317a != null) {
r.this.f18317a.dismiss();
r.this.f18317a = null;
}
}
}
class p0 implements View.OnClickListener {
p0() {
}
@Override
public void onClick(View view) {
if (r.this.f18317a != null) {
r.this.f18317a.dismiss();
}
}
}
class p1 implements View.OnClickListener {
final TextView f18380a;
final Context b;
final TextView c;
final TextView f18381d;
final TextView f18382e;
final EditText f18383f;
final TextView f18384g;
p1(TextView textView, Context context, TextView textView2, TextView textView3, TextView textView4, EditText editText, TextView textView5) {
this.f18380a = textView;
this.b = context;
this.c = textView2;
this.f18381d = textView3;
this.f18382e = textView4;
this.f18383f = editText;
this.f18384g = textView5;
}
@Override
public void onClick(View view) {
if (this.f18380a.getText().toString().equals(this.b.getResources().getString(R.string.by_sheet))) {
this.f18380a.setText(this.b.getResources().getString(R.string.byamount));
this.c.setText(this.b.getResources().getString(R.string.by_sheet));
this.f18381d.setText(this.b.getResources().getString(R.string.sheet));
this.f18382e.setText(this.b.getResources().getString(R.string.predict_amount));
this.f18383f.setFilters(new InputFilter[]{new io.bibeex.contract.util.m(0)});
this.f18383f.setHint(R.string.add_position_sheet_hint);
} else {
this.f18380a.setText(this.b.getResources().getString(R.string.by_sheet));
this.c.setText(this.b.getResources().getString(R.string.byamount));
this.f18381d.setText("USDT");
this.f18382e.setText(this.b.getResources().getString(R.string.predict_sheet));
this.f18383f.setFilters(new InputFilter[]{new io.bibeex.contract.util.m(4)});
this.f18383f.setHint(R.string.add_position_usdt_hint);
}
this.f18384g.setText("");
this.f18383f.setText("");
}
}
class q implements View.OnClickListener {
q() {
}
@Override
public void onClick(View view) {
if (r.this.b != null) {
r.this.b.b(r.this.f18317a, view);
}
}
}
class q0 implements DialogInterface.OnDismissListener {
q0() {
}
@Override
public void onDismiss(DialogInterface dialogInterface) {
r.this.f18317a = null;
}
}
class q1 implements TextWatcher {
final TextView f18388a;
final double b;
final EditText c;
final String f18389d;
final Context f18390e;
final TextView f18391f;
q1(TextView textView, double d2, EditText editText, String str, Context context, TextView textView2) {
this.f18388a = textView;
this.b = d2;
this.c = editText;
this.f18389d = str;
this.f18390e = context;
this.f18391f = textView2;
}
@Override
public void afterTextChanged(Editable editable) {
try {
if (this.f18388a.getText().toString().equals("USDT")) {
if (io.bibeex.contract.common.utlis.d.a((Object) editable.toString(), 0.0d) > this.b) {
String substring = editable.toString().substring(0, editable.toString().length() - 1);
this.c.setText(substring);
this.c.setSelection(substring.length() - 1);
return;
}
} else if (io.bibeex.contract.common.utlis.d.a((Object) editable.toString(), 0.0d) > io.bibeex.contract.util.i1.a.f18210a.a(io.bibeex.contract.common.utlis.d.a((Object) Double.valueOf(this.b), 0.0d), this.f18389d, this.f18390e)) {
String substring2 = editable.toString().substring(0, editable.toString().length() - 1);
this.c.setText(substring2);
this.c.setSelection(substring2.length() - 1);
return;
}
} catch (Exception e2) {
e2.printStackTrace();
}
if (this.f18388a.getText().toString().equals("USDT")) {
TextView textView = this.f18391f;
textView.setText(io.bibeex.contract.util.i1.a.f18210a.a(io.bibeex.contract.common.utlis.d.a((Object) this.c.getText().toString(), 0.0d), this.f18389d, this.f18390e) + this.f18390e.getResources().getString(R.string.sheet));
return;
}
TextView textView2 = this.f18391f;
textView2.setText(io.bibeex.contract.common.utlis.d.a(io.bibeex.contract.util.i1.a.f18210a.a(io.bibeex.contract.common.utlis.d.a((Object) this.c.getText().toString(), 0), this.f18389d, this.f18390e), 2) + "USDT");
}
@Override
public void beforeTextChanged(CharSequence charSequence, int i2, int i3, int i4) {
}
@Override
public void onTextChanged(CharSequence charSequence, int i2, int i3, int i4) {
}
}
class DialogInterface$OnDismissListenerC0432r implements DialogInterface.OnDismissListener {
DialogInterface$OnDismissListenerC0432r() {
}
@Override
public void onDismiss(DialogInterface dialogInterface) {
if (r.this.b != null) {
r.this.b = null;
}
r.this.f18317a = null;
}
}
public class r0 implements View.OnClickListener {
final View.OnClickListener f18394a;
r0(View.OnClickListener onClickListener) {
this.f18394a = onClickListener;
}
@Override
public void onClick(View view) {
if (r.this.f18317a != null) {
r.this.f18317a.dismiss();
r.this.f18317a = null;
}
View.OnClickListener onClickListener = this.f18394a;
if (onClickListener != null) {
onClickListener.onClick(view);
}
}
}
class r1 implements View.OnClickListener {
final EditText f18395a;
final TextView b;
r1(EditText editText, TextView textView) {
this.f18395a = editText;
this.b = textView;
}
@Override
public void onClick(View view) {
if (TextUtils.isEmpty(this.f18395a.getText()) || r.this.b == null) {
return;
}
r.this.b.a(r.this.f18317a, view, !this.b.getText().toString().equals("USDT"), this.f18395a.getText().toString());
}
}
class s implements View.OnClickListener {
s() {
}
@Override
public void onClick(View view) {
if (r.this.f18317a != null) {
r.this.f18317a.dismiss();
r.this.f18317a = null;
}
}
}
class s0 implements View.OnClickListener {
s0() {
}
@Override
public void onClick(View view) {
if (r.this.b != null) {
r.this.b.b(r.this.f18317a, view);
}
if (r.this.f18317a != null) {
r.this.f18317a.dismiss();
}
}
}
class s1 implements DialogInterface.OnDismissListener {
s1() {
}
@Override
public void onDismiss(DialogInterface dialogInterface) {
if (r.this.b != null) {
r.this.b = null;
}
r.this.f18317a = null;
}
}
class t implements View.OnClickListener {
t() {
}
@Override
public void onClick(View view) {
r.this.a();
}
}
class t0 implements View.OnClickListener {
t0() {
}
@Override
public void onClick(View view) {
if (r.this.b != null) {
r.this.b.b(r.this.f18317a, view);
}
if (r.this.f18317a != null) {
r.this.f18317a.dismiss();
}
}
}
class t1 implements View.OnClickListener {
t1() {
}
@Override
public void onClick(View view) {
if (r.this.f18317a != null) {
r.this.f18317a.dismiss();
r.this.f18317a = null;
}
}
}
class u implements DialogInterface.OnDismissListener {
u() {
}
@Override
public void onDismiss(DialogInterface dialogInterface) {
if (r.this.b != null) {
r.this.b = null;
}
r.this.f18317a = null;
}
}
class u0 implements DialogInterface.OnDismissListener {
u0() {
}
@Override
public void onDismiss(DialogInterface dialogInterface) {
r.this.f18317a = null;
}
}
class u1 implements View.OnClickListener {
u1() {
}
@Override
public void onClick(View view) {
if (r.this.b != null) {
r.this.b.a(r.this.f18317a, view);
}
}
}
class v implements View.OnClickListener {
v() {
}
@Override
public void onClick(View view) {
if (r.this.f18317a != null) {
r.this.f18317a.dismiss();
r.this.f18317a = null;
}
}
}
class v0 implements View.OnClickListener {
v0() {
}
@Override
public void onClick(View view) {
if (r.this.f18317a != null) {
r.this.f18317a.dismiss();
}
}
}
class v1 implements View.OnClickListener {
final EditText f18407a;
v1(EditText editText) {
this.f18407a = editText;
}
@Override
public void onClick(View view) {
if (TextUtils.isEmpty(this.f18407a.getText()) || r.this.b == null) {
return;
}
r.this.b.a(r.this.f18317a, view, this.f18407a.getText().toString());
}
}
public class w implements DialogInterface.OnDismissListener {
final View.OnClickListener f18408a;
final Context b;
w(View.OnClickListener onClickListener, Context context) {
this.f18408a = onClickListener;
this.b = context;
}
@Override
public void onDismiss(DialogInterface dialogInterface) {
if (r.this.b != null) {
r.this.b = null;
}
this.f18408a.onClick(new View(this.b));
r.this.f18317a = null;
}
}
class w0 implements View.OnClickListener {
final c2 f18409a;
w0(c2 c2Var) {
this.f18409a = c2Var;
}
@Override
public void onClick(View view) {
c2 c2Var = this.f18409a;
if (c2Var != null) {
c2Var.a(r.this.f18317a, view);
}
if (r.this.f18317a != null) {
r.this.f18317a.dismiss();
}
}
}
class w1 implements DialogInterface.OnDismissListener {
w1() {
}
@Override
public void onDismiss(DialogInterface dialogInterface) {
if (r.this.b != null) {
r.this.b = null;
}
r.this.f18317a = null;
}
}
class x implements View.OnClickListener {
x() {
}
@Override
public void onClick(View view) {
if (r.this.f18317a != null) {
r.this.f18317a.dismiss();
r.this.f18317a = null;
}
}
}
class x0 implements View.OnClickListener {
final c2 f18412a;
x0(c2 c2Var) {
this.f18412a = c2Var;
}
@Override
public void onClick(View view) {
c2 c2Var = this.f18412a;
if (c2Var != null) {
c2Var.b(r.this.f18317a, view);
}
}
}
class x1 implements View.OnClickListener {
x1() {
}
@Override
public void onClick(View view) {
r.this.a();
if (r.this.b != null) {
r.this.b.b(r.this.f18317a, view);
}
}
}
class y implements View.OnClickListener {
y() {
}
@Override
public void onClick(View view) {
if (r.this.b != null) {
r.this.b.a(r.this.f18317a, view);
}
}
}
class y0 implements DialogInterface.OnDismissListener {
y0() {
}
@Override
public void onDismiss(DialogInterface dialogInterface) {
r.this.f18317a = null;
}
}
class y1 implements DialogInterface.OnDismissListener {
y1() {
}
@Override
public void onDismiss(DialogInterface dialogInterface) {
if (r.this.b != null) {
r.this.b = null;
}
r.this.f18317a = null;
}
}
class z implements View.OnClickListener {
final EditText f18417a;
z(EditText editText) {
this.f18417a = editText;
}
@Override
public void onClick(View view) {
if (r.this.b != null) {
r.this.b.a(r.this.f18317a, view, this.f18417a.getText().toString());
}
}
}
class z0 implements View.OnClickListener {
final c2 f18418a;
z0(c2 c2Var) {
this.f18418a = c2Var;
}
@Override
public void onClick(View view) {
c2 c2Var = this.f18418a;
if (c2Var != null) {
c2Var.a(r.this.f18317a, view);
}
if (r.this.f18317a != null) {
r.this.f18317a.dismiss();
}
}
}
class z1 implements View.OnClickListener {
final Context f18419a;
final String b;
final String c;
z1(Context context, String str, String str2) {
this.f18419a = context;
this.b = str;
this.c = str2;
}
@Override
public void onClick(View view) {
Intent intent = new Intent(this.f18419a, MainWebviewActivity.class);
intent.putExtra("title", this.b);
intent.putExtra("url", this.c);
intent.putExtra("showTitle", true);
this.f18419a.startActivity(intent);
if (r.this.f18317a != null) {
r.this.f18317a.dismiss();
r.this.f18317a = null;
}
}
}
private r(r rVar) {
f18316g = rVar;
}
public void d(Context context) {
this.f18317a = new AlertDialog.Builder(context).create();
View inflate = View.inflate(context, R.layout.dialog_switch_warehouse_success, null);
this.f18317a.setView(inflate);
((ImageView) inflate.findViewById(R.id.ivClose)).setOnClickListener(new a());
this.f18317a.setCancelable(true);
this.f18317a.setOnDismissListener(new b());
Window window = this.f18317a.getWindow();
window.setBackgroundDrawableResource(17170445);
window.setContentView(inflate);
this.f18317a.show();
a(context, window);
}
public void e(Context context) {
this.f18317a = new AlertDialog.Builder(context).create();
View inflate = View.inflate(context, R.layout.dialog_task_desc, null);
this.f18317a.setView(inflate);
((TextView) inflate.findViewById(R.id.tv_description)).setText(context.getString(R.string.task_description_content).replaceAll("\\{product\\}", context.getString(R.string.app_name_en)));
((ImageView) inflate.findViewById(R.id.closeView)).setOnClickListener(new View.OnClickListener() {
@Override
public final void onClick(View view) {
r.this.d(view);
}
});
((TextView) inflate.findViewById(R.id.confirmView)).setOnClickListener(new View.OnClickListener() {
@Override
public final void onClick(View view) {
r.this.e(view);
}
});
this.f18317a.setCancelable(true);
this.f18317a.setOnDismissListener(new DialogInterface.OnDismissListener() {
@Override
public final void onDismiss(DialogInterface dialogInterface) {
r.this.b(dialogInterface);
}
});
Window window = this.f18317a.getWindow();
window.setBackgroundDrawableResource(17170445);
window.setContentView(inflate);
this.f18317a.show();
a(context, window);
}
public void f(View view) {
a();
}
public void g(View view) {
a();
}
public void h(View view) {
a();
}
public static r c() {
if (f18316g == null) {
f18316g = new r();
}
return f18316g;
}
public AlertDialog b() {
return this.f18317a;
}
public void b(Context context) {
this.f18317a = new AlertDialog.Builder(context).create();
View inflate = View.inflate(context, R.layout.dialog_kyc_status, null);
this.f18317a.setView(inflate);
((ImageView) inflate.findViewById(R.id.cancle_iv)).setOnClickListener(new c1());
((TextView) inflate.findViewById(R.id.cancel_tv)).setOnClickListener(new n1());
((TextView) inflate.findViewById(R.id.confirm_tv)).setOnClickListener(new x1());
this.f18317a.setCancelable(true);
this.f18317a.setOnDismissListener(new y1());
Window window = this.f18317a.getWindow();
window.setBackgroundDrawableResource(17170445);
window.setContentView(inflate);
this.f18317a.show();
}
private r() {
}
public void a() {
AlertDialog alertDialog = this.f18317a;
if (alertDialog != null) {
alertDialog.dismiss();
this.f18317a = null;
}
}
public void c(View view) {
AlertDialog alertDialog = this.f18317a;
if (alertDialog != null) {
alertDialog.dismiss();
this.f18317a = null;
}
}
private void a(Context context, Window window) {
WindowManager.LayoutParams attributes = window.getAttributes();
attributes.width = (int) (com.mob.tools.j.l.k(context) * 0.86f);
window.setAttributes(attributes);
}
public void c(Context context, String str, String str2, String str3) {
this.f18317a = new AlertDialog.Builder(context).create();
View inflate = View.inflate(context, R.layout.dialog_show, null);
this.f18317a.setView(inflate);
((ImageView) inflate.findViewById(R.id.image)).setOnClickListener(new d());
TextView textView = (TextView) inflate.findViewById(R.id.tv_dialog_cancel);
TextView textView2 = (TextView) inflate.findViewById(R.id.tv_dialog_ok);
((TextView) inflate.findViewById(R.id.tv_showdialog_text)).setText(str);
textView.setText(str2);
textView2.setText(str3);
textView.setOnClickListener(new e());
textView2.setOnClickListener(new f());
this.f18317a.setCancelable(true);
this.f18317a.setOnDismissListener(new g());
Window window = this.f18317a.getWindow();
window.setBackgroundDrawableResource(17170445);
window.setContentView(inflate);
this.f18317a.show();
}
public void a(c2 c2Var) {
this.b = c2Var;
}
public void a(Context context, String str, String str2) {
this.f18317a = new AlertDialog.Builder(context).create();
View inflate = View.inflate(context, R.layout.dialog_know, null);
this.f18317a.setView(inflate);
((ImageView) inflate.findViewById(R.id.ivClose)).setOnClickListener(new k());
((TextView) inflate.findViewById(R.id.tvTitle)).setText(str);
((TextView) inflate.findViewById(R.id.tvContent)).setText(str2);
((TextView) inflate.findViewById(R.id.tvKnow)).setOnClickListener(new v());
Window window = this.f18317a.getWindow();
window.setBackgroundDrawableResource(17170445);
window.setContentView(inflate);
this.f18317a.show();
a(context, window);
}
public View d(Context context, c2 c2Var) {
this.b = c2Var;
AlertDialog alertDialog = this.f18317a;
if (alertDialog != null && alertDialog.isShowing()) {
this.f18317a.dismiss();
}
this.f18317a = new AlertDialog.Builder(context).create();
View inflate = View.inflate(context, R.layout.finger_print_dialog, null);
this.f18317a.setView(inflate);
((ImageView) inflate.findViewById(R.id.cancle_iv)).setOnClickListener(new s0());
((Button) inflate.findViewById(R.id.know_tv)).setOnClickListener(new t0());
this.f18317a.setCancelable(true);
this.f18317a.setOnDismissListener(new u0());
Window window = this.f18317a.getWindow();
window.setBackgroundDrawableResource(17170445);
window.setContentView(inflate);
this.f18317a.show();
return inflate;
}
public void e(View view) {
a();
}
public void b(Context context, String str, String str2, String str3, String str4) {
this.f18317a = new AlertDialog.Builder(context).create();
View inflate = View.inflate(context, R.layout.dialog_title_2_button, null);
this.f18317a.setView(inflate);
TextView textView = (TextView) inflate.findViewById(R.id.tv_dialog_cancel);
TextView textView2 = (TextView) inflate.findViewById(R.id.tv_dialog_ok);
((TextView) inflate.findViewById(R.id.tv_showdialog_text)).setText(str2);
((TextView) inflate.findViewById(R.id.tvTitle)).setText(str);
textView.setText(str3);
textView2.setText(str4);
textView.setOnClickListener(new h());
textView2.setOnClickListener(new i());
this.f18317a.setCancelable(true);
this.f18317a.setOnDismissListener(new j());
Window window = this.f18317a.getWindow();
window.setBackgroundDrawableResource(17170445);
window.setContentView(inflate);
this.f18317a.show();
}
public void c(Context context) {
a(context, (DialogInterface.OnDismissListener) null);
}
public void c(Context context, c2 c2Var) {
this.b = c2Var;
AlertDialog alertDialog = this.f18317a;
if (alertDialog != null && alertDialog.isShowing()) {
this.f18317a.dismiss();
}
this.f18317a = new AlertDialog.Builder(context).create();
View inflate = View.inflate(context, R.layout.confirm_otcusersell_dialog, null);
this.f18317a.setView(inflate);
((TextView) inflate.findViewById(R.id.cancle_tv)).setOnClickListener(new d1(c2Var));
((TextView) inflate.findViewById(R.id.btnSure)).setOnClickListener(new e1(c2Var, inflate));
this.f18317a.setCancelable(true);
this.f18317a.setOnDismissListener(new f1());
Window window = this.f18317a.getWindow();
window.setBackgroundDrawableResource(17170445);
window.setContentView(inflate);
this.f18317a.show();
}
public void a(Context context, String str, String str2, String str3, View.OnClickListener onClickListener) {
this.f18317a = new AlertDialog.Builder(context).create();
View inflate = View.inflate(context, R.layout.dialog_know, null);
this.f18317a.setView(inflate);
((ImageView) inflate.findViewById(R.id.ivClose)).setOnClickListener(new g0());
((TextView) inflate.findViewById(R.id.tvTitle)).setText(str);
TextView textView = (TextView) inflate.findViewById(R.id.tvContent);
textView.setText(str2);
textView.setGravity(17);
TextView textView2 = (TextView) inflate.findViewById(R.id.tvKnow);
textView2.setText(str3);
textView2.setOnClickListener(new r0(onClickListener));
Window window = this.f18317a.getWindow();
window.setBackgroundDrawableResource(17170445);
window.setContentView(inflate);
this.f18317a.show();
a(context, window);
}
public void d(View view) {
a();
}
public void b(Context context, String str, String str2, String str3) {
AlertDialog alertDialog = this.f18317a;
if (alertDialog != null && !alertDialog.isShowing()) {
this.f18317a.dismiss();
this.f18317a = null;
}
this.f18317a = new AlertDialog.Builder(context).create();
View inflate = View.inflate(context, R.layout.dialog_show_otctip, null);
this.f18317a.setView(inflate);
((ImageView) inflate.findViewById(R.id.image)).setOnClickListener(new l());
TextView textView = (TextView) inflate.findViewById(R.id.tv_dialog_cancel);
TextView textView2 = (TextView) inflate.findViewById(R.id.tv_dialog_ok);
((TextView) inflate.findViewById(R.id.tv_showdialog_text)).setText(str);
textView.setText(str2);
textView2.setText(str3);
textView.setOnClickListener(new m());
textView2.setOnClickListener(new n());
this.f18317a.setCancelable(true);
this.f18317a.setOnDismissListener(new o());
Window window = this.f18317a.getWindow();
window.setBackgroundDrawableResource(17170445);
window.setContentView(inflate);
this.f18317a.show();
}
public void c(DialogInterface dialogInterface) {
if (this.b != null) {
this.b = null;
}
}
public void a(final Context context, String str, String str2, final String str3, String str4) {
String a3 = io.bibeex.contract.util.t0.a(context, str3, "0");
if (TextUtils.equals("1", a3)) {
return;
}
io.bibeex.contract.common.utlis.c.a(this.f18317a);
this.f18317a = new AlertDialog.Builder(context).create();
View inflate = View.inflate(context, R.layout.dialog_know_tip, null);
this.f18317a.setView(inflate);
TextView textView = (TextView) inflate.findViewById(R.id.tvContent3);
((TextView) inflate.findViewById(R.id.tv_title)).setText(str);
textView.setText(context.getString(R.string.lighting_cfd_tip_1, str));
((TextView) inflate.findViewById(R.id.tvContent)).setText(str2.replace("\\n", d.b.f.u.x.y));
((TextView) inflate.findViewById(R.id.tvKnow)).setOnClickListener(new View.OnClickListener() {
@Override
public final void onClick(View view) {
r.this.c(view);
}
});
String string = context.getString(R.string.lighting_cfd_tip_1, str);
SpannableString spannableString = new SpannableString(string);
spannableString.setSpan(new ForegroundColorSpan(context.getResources().getColor(R.color.D0A858)), string.indexOf("《"), string.indexOf("》") + 1, 33);
textView.setText(spannableString);
textView.setOnClickListener(new z1(context, str, str4));
final ImageView imageView = (ImageView) inflate.findViewById(R.id.ivWaring);
imageView.setImageResource(TextUtils.equals("0", a3) ? R.mipmap.ic_box_normal : R.mipmap.ic_box_checked);
inflate.findViewById(R.id.llWaring).setOnClickListener(new View.OnClickListener() {
@Override
public final void onClick(View view) {
r.a(context, str3, imageView, view);
}
});
Window window = this.f18317a.getWindow();
window.setBackgroundDrawableResource(17170445);
window.setContentView(inflate);
this.f18317a.show();
a(context, window);
}
public void b(Context context, String str, String str2) {
this.f18317a = new AlertDialog.Builder(context).create();
View inflate = View.inflate(context, R.layout.dialog_show_one, null);
this.f18317a.setView(inflate);
((ImageView) inflate.findViewById(R.id.image)).setOnClickListener(new p());
TextView textView = (TextView) inflate.findViewById(R.id.tv_dialog_cancel);
TextView textView2 = (TextView) inflate.findViewById(R.id.tv_dialog_ok);
((TextView) inflate.findViewById(R.id.tv_showdialog_text)).setText(str);
textView2.setText(str2);
textView2.setOnClickListener(new q());
this.f18317a.setCancelable(true);
this.f18317a.setOnDismissListener(new DialogInterface$OnDismissListenerC0432r());
Window window = this.f18317a.getWindow();
window.setBackgroundDrawableResource(17170445);
window.setContentView(inflate);
this.f18317a.show();
}
public static void a(Context context, String str, ImageView imageView, View view) {
if (TextUtils.equals("0", io.bibeex.contract.util.t0.a(context, str, "0"))) {
imageView.setImageResource(R.mipmap.ic_box_checked);
io.bibeex.contract.util.t0.c(context, str, "1");
return;
}
imageView.setImageResource(R.mipmap.ic_box_normal);
io.bibeex.contract.util.t0.c(context, str, "0");
}
public void b(Context context, String str, String str2, String str3, View.OnClickListener onClickListener) {
this.f18317a = new AlertDialog.Builder(context).create();
View inflate = View.inflate(context, R.layout.dialog_show_3, null);
this.f18317a.setView(inflate);
((ImageView) inflate.findViewById(R.id.image)).setOnClickListener(new s());
TextView textView = (TextView) inflate.findViewById(R.id.tv_dialog_cancel);
TextView textView2 = (TextView) inflate.findViewById(R.id.tv_dialog_ok);
((TextView) inflate.findViewById(R.id.tv_showdialog_text)).setText(str);
if (!TextUtils.isEmpty(str2)) {
textView.setText(str2);
}
if (!TextUtils.isEmpty(str3)) {
textView2.setText(str3);
}
textView.setOnClickListener(new t());
textView2.setOnClickListener(onClickListener);
this.f18317a.setCancelable(true);
this.f18317a.setOnDismissListener(new u());
Window window = this.f18317a.getWindow();
window.setBackgroundDrawableResource(17170445);
window.setContentView(inflate);
this.f18317a.show();
}
public void a(Context context, View.OnClickListener onClickListener) {
this.f18317a = new AlertDialog.Builder(context).create();
View inflate = View.inflate(context, R.layout.dialog_kyc_fail, null);
this.f18317a.setView(inflate);
View findViewById = inflate.findViewById(R.id.iv_close);
View findViewById2 = inflate.findViewById(R.id.tv_yes);
findViewById.setOnClickListener(onClickListener);
findViewById2.setOnClickListener(onClickListener);
this.f18317a.setCancelable(true);
this.f18317a.setOnDismissListener(new c(onClickListener, context));
Window window = this.f18317a.getWindow();
window.setBackgroundDrawableResource(17170445);
window.setContentView(inflate);
this.f18317a.show();
a(context, window);
}
public void a(Context context, String str, String str2, String str3, String str4, View.OnClickListener onClickListener) {
this.f18317a = new AlertDialog.Builder(context).create();
View inflate = View.inflate(context, R.layout.dialog_show_4, null);
this.f18317a.setView(inflate);
TextView textView = (TextView) inflate.findViewById(R.id.tv_no);
TextView textView2 = (TextView) inflate.findViewById(R.id.tv_yes);
((TextView) inflate.findViewById(R.id.tv_title)).setText(str);
((TextView) inflate.findViewById(R.id.tv_showdialog_text)).setText(str2);
if (!TextUtils.isEmpty(str3)) {
textView.setText(str3);
}
if (!TextUtils.isEmpty(str4)) {
textView2.setText(str4);
}
textView.setOnClickListener(onClickListener);
textView2.setOnClickListener(onClickListener);
this.f18317a.setCancelable(true);
this.f18317a.setOnDismissListener(new w(onClickListener, context));
Window window = this.f18317a.getWindow();
window.setBackgroundDrawableResource(17170445);
window.setContentView(inflate);
this.f18317a.show();
}
public static void b(Context context, Charge charge, View view) {
io.bibeex.contract.util.b1.a(context, charge.getFadderess());
io.bibeex.contract.common.d.f.a.c(context, context.getString(R.string.copied_to_clipboard));
}
public void b(View view) {
this.f18317a.dismiss();
}
public void b(Context context, c2 c2Var) {
this.b = c2Var;
AlertDialog alertDialog = this.f18317a;
if (alertDialog != null && alertDialog.isShowing()) {
this.f18317a.dismiss();
}
this.f18317a = new AlertDialog.Builder(context).create();
View inflate = View.inflate(context, R.layout.confirm_otctrade_dialog, null);
this.f18317a.setView(inflate);
((TextView) inflate.findViewById(R.id.cancle_tv)).setOnClickListener(new z0(c2Var));
((TextView) inflate.findViewById(R.id.btnSure)).setOnClickListener(new a1(c2Var, inflate));
this.f18317a.setCancelable(true);
this.f18317a.setOnDismissListener(new b1());
Window window = this.f18317a.getWindow();
window.setBackgroundDrawableResource(17170445);
window.setContentView(inflate);
this.f18317a.show();
}
public boolean b(Context context, String str, int i2) {
String string = i2 == 0 ? "USDT" : context.getString(R.string.sheet);
int i3 = this.c;
if (i3 != 1) {
if (i3 == 2 && io.bibeex.contract.common.utlis.d.b((Object) str) > this.f18318d) {
io.bibeex.contract.common.d.f.a.c(context, context.getString(R.string.max_rate) + this.f18318d + string);
return false;
}
} else if (io.bibeex.contract.common.utlis.d.b((Object) str) > 99.0d) {
io.bibeex.contract.common.d.f.a.c(context, context.getString(R.string.max_rate) + "99%");
return false;
}
return io.bibeex.contract.common.utlis.d.b((Object) str) != 0.0d;
}
public void a(Context context, String str, String str2, String str3) {
this.f18317a = new AlertDialog.Builder(context).create();
View inflate = View.inflate(context, R.layout.dialog_show_2, null);
this.f18317a.setView(inflate);
((ImageView) inflate.findViewById(R.id.image)).setOnClickListener(new x());
((TextView) inflate.findViewById(R.id.tv_showdialog_text)).setText(str);
((TextView) inflate.findViewById(R.id.tv_dialog_cancel)).setOnClickListener(new y());
((TextView) inflate.findViewById(R.id.tv_dialog_ok)).setOnClickListener(new z((EditText) inflate.findViewById(R.id.editText)));
this.f18317a.setCancelable(true);
this.f18317a.setOnDismissListener(new a0());
Window window = this.f18317a.getWindow();
window.setBackgroundDrawableResource(17170445);
window.setContentView(inflate);
this.f18317a.show();
}
public void b(DialogInterface dialogInterface) {
if (this.b != null) {
this.b = null;
}
}
public void a(Context context, String str, int i2) {
this.f18317a = new AlertDialog.Builder(context).create();
View inflate = View.inflate(context, R.layout.dialog_show_1, null);
this.f18317a.setView(inflate);
((TextView) inflate.findViewById(R.id.tv_showdialog_text)).setText(str);
((ImageView) inflate.findViewById(R.id.image)).setImageResource(i2);
((ImageView) inflate.findViewById(R.id.cancle_iv)).setOnClickListener(new b0());
this.f18317a.setCancelable(true);
this.f18317a.setOnDismissListener(new c0());
Window window = this.f18317a.getWindow();
window.setBackgroundDrawableResource(17170445);
window.setContentView(inflate);
this.f18317a.show();
}
public void a(Context context, View.OnClickListener onClickListener, View.OnClickListener onClickListener2) {
this.f18317a = new AlertDialog.Builder(context).create();
View inflate = View.inflate(context, R.layout.dialog_kyc_view, null);
this.f18317a.setView(inflate);
((TextView) inflate.findViewById(R.id.btn_no)).setOnClickListener(onClickListener);
((TextView) inflate.findViewById(R.id.btn_continue)).setOnClickListener(onClickListener2);
this.f18317a.setCancelable(false);
Window window = this.f18317a.getWindow();
window.setBackgroundDrawableResource(17170445);
window.setContentView(inflate);
this.f18317a.show();
}
public void a(Context context, DialogInterface.OnDismissListener onDismissListener) {
this.f18317a = new AlertDialog.Builder(context).create();
View inflate = View.inflate(context, R.layout.regist_suc_view, null);
this.f18317a.setView(inflate);
((ImageView) inflate.findViewById(R.id.cancle_iv)).setOnClickListener(new d0());
((TextView) inflate.findViewById(R.id.tv_sure)).setOnClickListener(new e0());
this.f18317a.setCancelable(true);
if (onDismissListener != null) {
this.f18317a.setOnDismissListener(onDismissListener);
} else {
this.f18317a.setOnDismissListener(new f0());
}
Window window = this.f18317a.getWindow();
window.setBackgroundDrawableResource(17170445);
window.setContentView(inflate);
this.f18317a.show();
}
public void a(final Context context, final Charge charge) {
this.f18317a = new AlertDialog.Builder(context).create();
View inflate = View.inflate(context, R.layout.dialog_charge, null);
this.f18317a.setView(inflate);
RecyclerView recyclerView = (RecyclerView) inflate.findViewById(R.id.recyclerView);
((TextView) inflate.findViewById(R.id.tv_address)).setText(charge.getMemoAccount());
((TextView) inflate.findViewById(R.id.copy_1)).setOnClickListener(new View.OnClickListener() {
@Override
public final void onClick(View view) {
r.a(context, charge, view);
}
});
((TextView) inflate.findViewById(R.id.tv_memo)).setText(charge.getFadderess());
((TextView) inflate.findViewById(R.id.copy_2)).setOnClickListener(new View.OnClickListener() {
@Override
public final void onClick(View view) {
r.b(context, charge, view);
}
});
this.f18317a.setOnDismissListener(new h0());
recyclerView.setAdapter(new i0(context, R.layout.dialog_charge_item, charge.getDescList()));
recyclerView.setLayoutManager(new LinearLayoutManager(context));
Window window = this.f18317a.getWindow();
window.setBackgroundDrawableResource(17170445);
window.setContentView(inflate);
this.f18317a.show();
}
public static void a(Context context, Charge charge, View view) {
io.bibeex.contract.util.b1.a(context, charge.getMemoAccount());
io.bibeex.contract.common.d.f.a.c(context, context.getString(R.string.copied_to_clipboard));
}
public void a(Context context, boolean z2, View.OnClickListener onClickListener, String str, String str2) {
io.bibeex.contract.common.utlis.a.b(context);
this.f18317a = new AlertDialog.Builder(context).create();
View inflate = View.inflate(context, R.layout.dialog_version_bibeex, null);
this.f18317a.setView(inflate);
TextView textView = (TextView) inflate.findViewById(R.id.later);
((TextView) inflate.findViewById(R.id.tv_update_info)).setText(str2);
((TextView) inflate.findViewById(R.id.tv_version_name)).setText(com.alibaba.sdk.android.tbrest.d.b.f1763h + str);
((TextView) inflate.findViewById(R.id.update_now)).setOnClickListener(onClickListener);
textView.setOnClickListener(new View.OnClickListener() {
@Override
public final void onClick(View view) {
r.this.b(view);
}
});
if (z2) {
textView.setVisibility(8);
}
this.f18317a.setCancelable(false);
this.f18317a.setCanceledOnTouchOutside(false);
this.f18317a.setOnDismissListener(new j0());
Window window = this.f18317a.getWindow();
window.setBackgroundDrawableResource(17170445);
window.setContentView(inflate);
this.f18317a.show();
}
public void a(Context context, String str, View.OnClickListener onClickListener) {
this.f18317a = new AlertDialog.Builder(context).create();
View inflate = View.inflate(context, R.layout.dialog_human_hand, null);
this.f18317a.setView(inflate);
((TextView) inflate.findViewById(R.id.tv_info)).setText(str);
((TextView) inflate.findViewById(R.id.No)).setOnClickListener(new View.OnClickListener() {
@Override
public final void onClick(View view) {
r.this.h(view);
}
});
((TextView) inflate.findViewById(R.id.Yes)).setOnClickListener(onClickListener);
this.f18317a.setOnDismissListener(new k0());
Window window = this.f18317a.getWindow();
window.setBackgroundDrawableResource(17170445);
window.setContentView(inflate);
this.f18317a.show();
}
public void a(Context context, b2 b2Var) {
this.f18319e = b2Var;
this.f18317a = new AlertDialog.Builder(context).create();
View inflate = View.inflate(context, R.layout.verify_renji_view, null);
this.f18317a.setView(inflate);
WebView webView = (WebView) inflate.findViewById(R.id.webview);
WebView webView2 = (WebView) inflate.findViewById(R.id.webview);
webView2.getSettings().setUseWideViewPort(true);
webView2.getSettings().setLoadWithOverviewMode(true);
webView2.getSettings().setCacheMode(1);
webView2.setWebViewClient(new l0());
webView2.getSettings().setJavaScriptEnabled(true);
webView2.addJavascriptInterface(new d2(), "testInterface");
webView2.loadUrl("file:////android_asset/LoginVerityMain.html");
((ImageView) inflate.findViewById(R.id.cancle_iv)).setOnClickListener(new m0());
this.f18317a.setCancelable(true);
this.f18317a.setOnDismissListener(new n0());
Window window = this.f18317a.getWindow();
window.setBackgroundDrawableResource(17170445);
window.setContentView(inflate);
this.f18317a.show();
}
public void a(Context context, String str) {
this.f18317a = new AlertDialog.Builder(context).create();
View inflate = View.inflate(context, R.layout.kefu_dialog, null);
TextView textView = (TextView) inflate.findViewById(R.id.know_tv);
TextView textView2 = (TextView) inflate.findViewById(R.id.text_tv);
if (!TextUtils.isEmpty(str)) {
textView2.setText(str);
}
this.f18317a.setView(inflate);
((ImageView) inflate.findViewById(R.id.cancle_iv)).setOnClickListener(new o0());
textView.setOnClickListener(new p0());
this.f18317a.setCancelable(true);
this.f18317a.setOnDismissListener(new q0());
Window window = this.f18317a.getWindow();
window.setBackgroundDrawableResource(17170445);
window.setContentView(inflate);
this.f18317a.show();
}
public void a(Context context, c2 c2Var) {
this.b = c2Var;
AlertDialog alertDialog = this.f18317a;
if (alertDialog != null && alertDialog.isShowing()) {
this.f18317a.dismiss();
}
this.f18317a = new AlertDialog.Builder(context).create();
View inflate = View.inflate(context, R.layout.dialog_cancel_order, null);
this.f18317a.setView(inflate);
((ImageView) inflate.findViewById(R.id.image)).setOnClickListener(new v0());
((TextView) inflate.findViewById(R.id.tv_cancel)).setOnClickListener(new w0(c2Var));
((TextView) inflate.findViewById(R.id.tv_ok)).setOnClickListener(new x0(c2Var));
this.f18317a.setCancelable(true);
this.f18317a.setOnDismissListener(new y0());
Window window = this.f18317a.getWindow();
window.setBackgroundDrawableResource(17170445);
window.setContentView(inflate);
this.f18317a.show();
}
public void a(Context context, double d3, int i2, LifecycleOwner lifecycleOwner) {
this.c = 1;
this.f18318d = d3;
this.f18317a = new AlertDialog.Builder(context).create();
View inflate = View.inflate(context, R.layout.dialog_show_part_pc, null);
this.f18317a.setView(inflate);
((ImageView) inflate.findViewById(R.id.image)).setOnClickListener(new g1());
TextView textView = (TextView) inflate.findViewById(R.id.tv_dialog_cancel);
TextView textView2 = (TextView) inflate.findViewById(R.id.tv_dialog_ok);
TextView textView3 = (TextView) inflate.findViewById(R.id.tv_by_type);
TextView textView4 = (TextView) inflate.findViewById(R.id.tv_by_info);
TextView textView5 = (TextView) inflate.findViewById(R.id.tv_pc_title);
TextView textView6 = (TextView) inflate.findViewById(R.id.tv_pc_value);
TextView textView7 = (TextView) inflate.findViewById(R.id.tv_unit);
String string = i2 == 0 ? "USDT" : context.getString(R.string.sheet);
int i3 = this.c;
if (i3 == 1) {
textView6.setText("0 " + string);
} else if (i3 == 2) {
textView6.setText("0.00%");
}
EditText editText = (EditText) inflate.findViewById(R.id.et_part);
editText.setFilters(new InputFilter[]{new io.bibeex.contract.util.m(4)});
AutoObservable autoObservable = new AutoObservable(e.g.b.e.j0.l(editText));
lifecycleOwner.getLifecycle().addObserver(autoObservable);
autoObservable.a(new h1(textView6, string, editText, context, i2, d3)).Q();
if (i2 == 0) {
textView3.setText(context.getString(R.string.byamount));
} else {
textView3.setText(context.getString(R.string.bysheet));
}
textView3.setOnClickListener(new i1(editText, textView3, context, i2, textView4, textView5, textView7, string, textView6));
textView.setOnClickListener(new j1());
textView2.setOnClickListener(new k1(editText, context, i2));
this.f18317a.setCancelable(true);
this.f18317a.setOnDismissListener(new l1());
Window window = this.f18317a.getWindow();
window.setBackgroundDrawableResource(17170445);
window.setContentView(inflate);
this.f18317a.show();
}
public void a(Context context, String str, double d3, boolean z2) {
TextView textView;
this.f18317a = new AlertDialog.Builder(context).create();
View inflate = View.inflate(context, R.layout.dialog_permanent_show_add_position, null);
this.f18317a.setView(inflate);
((ImageView) inflate.findViewById(R.id.image)).setOnClickListener(new m1());
TextView textView2 = (TextView) inflate.findViewById(R.id.tv_dialog_cancel);
TextView textView3 = (TextView) inflate.findViewById(R.id.tv_dialog_ok);
TextView textView4 = (TextView) inflate.findViewById(R.id.tv_unit);
TextView textView5 = (TextView) inflate.findViewById(R.id.tv_by_type);
TextView textView6 = (TextView) inflate.findViewById(R.id.tv_by_info);
TextView textView7 = (TextView) inflate.findViewById(R.id.tv_pc_title);
TextView textView8 = (TextView) inflate.findViewById(R.id.tv_pc_value);
if (z2) {
textView5.setVisibility(8);
}
EditText editText = (EditText) inflate.findViewById(R.id.et_part);
editText.setFilters(new InputFilter[]{new io.bibeex.contract.util.m(4)});
textView2.setOnClickListener(new o1());
textView5.setOnClickListener(new p1(textView5, context, textView6, textView4, textView7, editText, textView8));
if (textView4.getText().toString().equals("USDT")) {
textView = textView8;
textView.setText(io.bibeex.contract.util.i1.a.f18210a.a(io.bibeex.contract.common.utlis.d.a((Object) editText.getText().toString(), 0.0d), str, context) + context.getResources().getString(R.string.sheet));
} else {
textView = textView8;
textView.setText(io.bibeex.contract.common.utlis.d.a(io.bibeex.contract.util.i1.a.f18210a.a(io.bibeex.contract.common.utlis.d.a((Object) editText.getText().toString(), 0), str, context), 2) + "USDT");
}
editText.addTextChangedListener(new q1(textView4, d3, editText, str, context, textView));
textView3.setOnClickListener(new r1(editText, textView4));
this.f18317a.setCancelable(true);
this.f18317a.setOnDismissListener(new s1());
Window window = this.f18317a.getWindow();
window.setBackgroundDrawableResource(17170445);
window.setContentView(inflate);
this.f18317a.show();
}
public void a(Context context) {
this.f18317a = new AlertDialog.Builder(context).create();
View inflate = View.inflate(context, R.layout.dialog_show_add_position, null);
this.f18317a.setView(inflate);
((ImageView) inflate.findViewById(R.id.image)).setOnClickListener(new t1());
EditText editText = (EditText) inflate.findViewById(R.id.et_part);
editText.setFilters(new InputFilter[]{new io.bibeex.contract.util.m(2)});
((TextView) inflate.findViewById(R.id.tv_dialog_cancel)).setOnClickListener(new u1());
((TextView) inflate.findViewById(R.id.tv_dialog_ok)).setOnClickListener(new v1(editText));
this.f18317a.setCancelable(true);
this.f18317a.setOnDismissListener(new w1());
Window window = this.f18317a.getWindow();
window.setBackgroundDrawableResource(17170445);
window.setContentView(inflate);
this.f18317a.show();
}
public void a(final Context context, final io.bibeex.contract.ui.fragment.asset.q qVar, final io.bibeex.contract.ui.fragment.asset.r rVar) {
this.f18317a = new AlertDialog.Builder(context).create();
View inflate = View.inflate(context, R.layout.dialog_transfer, null);
this.f18317a.setView(inflate);
final TextView textView = (TextView) inflate.findViewById(R.id.transferFromView);
final TextView textView2 = (TextView) inflate.findViewById(R.id.transferToView);
TextView textView3 = (TextView) inflate.findViewById(R.id.enableTransferView);
TextView textView4 = (TextView) inflate.findViewById(R.id.unableTransferView);
TextView textView5 = (TextView) inflate.findViewById(R.id.totalView);
final EditText editText = (EditText) inflate.findViewById(R.id.transferAmountView);
TextView textView6 = (TextView) inflate.findViewById(R.id.unitView);
final TextView textView7 = (TextView) inflate.findViewById(R.id.transferLimitView);
TextView textView8 = (TextView) inflate.findViewById(R.id.confirmView);
((ImageView) inflate.findViewById(R.id.closeView)).setOnClickListener(new View.OnClickListener() {
@Override
public final void onClick(View view) {
r.this.a(view);
}
});
((TextView) inflate.findViewById(R.id.tipView)).setText(qVar.l());
textView.setText(qVar.h());
textView2.setText(qVar.m());
textView7.setText(io.bibeex.contract.common.utlis.d.a(qVar.j(), 4) + " USDT");
editText.setFilters(new InputFilter[]{new io.bibeex.contract.util.m(4)});
io.bibeex.contract.util.y0.f18496a.b(context, editText);
if (qVar.e()) {
textView3.setVisibility(0);
textView4.setVisibility(8);
} else {
textView3.setVisibility(8);
textView4.setVisibility(0);
}
textView3.setOnClickListener(new View.OnClickListener() {
@Override
public final void onClick(View view) {
r.a(io.bibeex.contract.ui.fragment.asset.q.this, textView, textView2, textView7, editText, view);
}
});
textView5.setOnClickListener(new View.OnClickListener() {
@Override
public final void onClick(View view) {
editText.setText(io.bibeex.contract.common.utlis.d.a(qVar.j(), 4));
}
});
textView8.setOnClickListener(new View.OnClickListener() {
@Override
public final void onClick(View view) {
r.this.a(editText, context, qVar, rVar, view);
}
});
this.f18317a.setCancelable(true);
this.f18317a.setOnDismissListener(new DialogInterface.OnDismissListener() {
@Override
public final void onDismiss(DialogInterface dialogInterface) {
r.this.a(dialogInterface);
}
});
Window window = this.f18317a.getWindow();
window.setBackgroundDrawableResource(17170445);
window.setContentView(inflate);
this.f18317a.show();
a(context, window);
}
public void a(View view) {
a();
}
public static void a(io.bibeex.contract.ui.fragment.asset.q qVar, TextView textView, TextView textView2, TextView textView3, EditText editText, View view) {
String m2 = qVar.m();
String h2 = qVar.h();
String b3 = qVar.b();
String a3 = qVar.a();
double k2 = qVar.k();
double j2 = qVar.j();
qVar.e(m2);
qVar.g(h2);
qVar.a(b3);
qVar.b(a3);
qVar.c(k2);
qVar.d(j2);
textView.setText(qVar.h());
textView2.setText(qVar.m());
textView3.setText(io.bibeex.contract.common.utlis.d.a(qVar.j(), 4) + " USDT");
editText.setText("");
}
public void a(EditText editText, Context context, io.bibeex.contract.ui.fragment.asset.q qVar, io.bibeex.contract.ui.fragment.asset.r rVar, View view) {
if (!TextUtils.isEmpty(editText.getText()) && io.bibeex.contract.common.utlis.d.b(editText.getText()) != 0.0d) {
if (Double.parseDouble(editText.getText().toString().trim()) > qVar.j()) {
io.bibeex.contract.util.blank2.g.a(context, (int) R.string.asset_account_transfer_tip_over);
return;
} else if (qVar.f() && Double.parseDouble(editText.getText().toString().trim()) < qVar.i()) {
io.bibeex.contract.util.blank2.g.a(context, (int) R.string.asset_account_transfer_tip_less);
return;
} else {
if (rVar != null) {
qVar.a(Double.parseDouble(editText.getText().toString().trim()));
rVar.a(qVar);
}
a();
return;
}
}
io.bibeex.contract.util.blank2.g.a(context, (int) R.string.asset_account_transfer_tip_input);
}
public void a(DialogInterface dialogInterface) {
if (this.b != null) {
this.b = null;
}
}
public void a(Context context, TaskBean taskBean) {
this.f18317a = new AlertDialog.Builder(context).create();
View inflate = View.inflate(context, R.layout.dialog_task_detail, null);
this.f18317a.setView(inflate);
RecyclerView recyclerView = (RecyclerView) inflate.findViewById(R.id.viewTasks);
((TextView) inflate.findViewById(R.id.viewTaskName)).setText(taskBean.getDescription());
TaskDetailAdapter taskDetailAdapter = new TaskDetailAdapter(taskBean.getTaskItems());
recyclerView.setLayoutManager(new LinearLayoutManager(context));
taskDetailAdapter.bindToRecyclerView(recyclerView);
((ImageView) inflate.findViewById(R.id.closeView)).setOnClickListener(new View.OnClickListener() {
@Override
public final void onClick(View view) {
r.this.f(view);
}
});
((TextView) inflate.findViewById(R.id.confirmView)).setOnClickListener(new View.OnClickListener() {
@Override
public final void onClick(View view) {
r.this.g(view);
}
});
this.f18317a.setCancelable(true);
this.f18317a.setOnDismissListener(new DialogInterface.OnDismissListener() {
@Override
public final void onDismiss(DialogInterface dialogInterface) {
r.this.c(dialogInterface);
}
});
Window window = this.f18317a.getWindow();
window.setBackgroundDrawableResource(17170445);
window.setContentView(inflate);
this.f18317a.show();
a(context, window);
}
public void a(b2 b2Var) {
this.f18319e = b2Var;
}
}