Shandong video conference v3.2.10版本的 MD5 值为:e9e908f971313b4c4bca5737f96781ef

以下内容为反编译后的 a.java 源代码,内容仅作参考


package e.l.b.c;

import android.os.Build;
import android.os.Bundle;
import android.text.SpannableString;
import android.text.TextUtils;
import android.text.method.LinkMovementMethod;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.view.Window;
import android.view.WindowManager;
import android.widget.Button;
import android.widget.TextView;
import androidx.annotation.g0;
import androidx.annotation.h0;
import androidx.annotation.q;
import androidx.fragment.app.FragmentActivity;
import androidx.fragment.app.g;
import androidx.fragment.app.m;
import cn.gov.sdongmeeting.video.R;
import com.ainemo.android.business.rest.BusinessConst;
import com.xylink.common.e.e;
import java.util.Locale;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
public class a extends androidx.fragment.app.b {
    private d a;
    private Button f16357b;
    private Button f16358c;
    private String f16359d;
    private CharSequence f16360e;
    private int f16361f = 1;
    private String f16362g;
    private String f16363h;
    private String f16364i;
    @q
    private int f16365j;
    @q
    private int f16366k;

    class C0301a extends com.xylink.common.widget.a {
        C0301a() {
        }

        @Override
        public void onSingleClick(View view) {
            a.this.dismissAllowingStateLoss();
            if (a.this.a != null) {
                a.this.a.onPrimaryButtonClicked(a.this.f16357b);
            }
        }
    }

    class b extends com.xylink.common.widget.a {
        b() {
        }

        @Override
        public void onSingleClick(View view) {
            a.this.dismissAllowingStateLoss();
            if (a.this.a != null) {
                a.this.a.onSecondButtonClicked(a.this.f16358c);
            }
        }
    }

    public static class c {
        private static final String f16367b = "title";
        private static final String f16368c = "content";
        private static final String f16369d = "contentGravity";
        private static final String f16370e = "primaryButton";
        private static final String f16371f = "secondButton";
        private static final String f16372g = "tag";
        private static final String f16373h = "sureButtonBg";
        private static final String f16374i = "cancelButtonBg";
        private Bundle a = new Bundle();

        public c a(int i2) {
            this.a.putInt(f16374i, i2);
            return this;
        }

        public c b(int i2) {
            this.a.putInt(f16369d, i2);
            return this;
        }

        public c c(int i2) {
            this.a.putInt(f16373h, i2);
            return this;
        }

        public c d(String str) {
            this.a.putString("title", str);
            return this;
        }

        public c a(CharSequence charSequence) {
            this.a.putCharSequence("content", charSequence);
            return this;
        }

        public c b(String str) {
            this.a.putString(f16371f, str);
            return this;
        }

        public c c(String str) {
            this.a.putString("tag", str);
            return this;
        }

        public c a(String str) {
            this.a.putString(f16370e, str);
            return this;
        }

        public a a() {
            a aVar = new a();
            aVar.setArguments(this.a);
            return aVar;
        }
    }

    public interface d {
        void onPrimaryButtonClicked(Button button);

        void onSecondButtonClicked(Button button);
    }

    @Override
    public void onCreate(@h0 Bundle bundle) {
        super.onCreate(bundle);
        if (bundle != null) {
            dismissAllowingStateLoss();
        }
        Bundle arguments = getArguments();
        if (arguments != null) {
            this.f16359d = arguments.getString("title");
            this.f16360e = arguments.getCharSequence("content");
            this.f16361f = arguments.getInt("contentGravity", 1);
            this.f16362g = arguments.getString("primaryButton");
            this.f16363h = arguments.getString("secondButton");
            this.f16364i = arguments.getString(BusinessConst.KEY_TAG);
            this.f16365j = arguments.getInt("sureButtonBg");
            this.f16366k = arguments.getInt("cancelButtonBg");
        }
    }

    @Override
    @h0
    public View onCreateView(@g0 LayoutInflater layoutInflater, @h0 ViewGroup viewGroup, @h0 Bundle bundle) {
        return layoutInflater.inflate(R.layout.fragment_license_dialog, viewGroup, true);
    }

    @Override
    public void onDestroyView() {
        super.onDestroyView();
    }

    @Override
    public void onStart() {
        super.onStart();
        Window window = getDialog().getWindow();
        if (window != null) {
            window.setBackgroundDrawableResource(R.drawable.bg_dialog);
            WindowManager.LayoutParams attributes = window.getAttributes();
            if ("Pixel 3 XL".equals(Build.MODEL)) {
                attributes.width = e.a(getContext(), 310.0f);
            } else if ("Pixel 2 XL".equals(Build.MODEL)) {
                attributes.width = e.a(getContext(), 300.0f);
            } else {
                attributes.width = e.a(getContext(), 288.0f);
            }
            window.setAttributes(attributes);
        }
    }

    @Override
    public void onViewCreated(@g0 View view, @h0 Bundle bundle) {
        super.onViewCreated(view, bundle);
        TextView textView = (TextView) view.findViewById(R.id.dialog_title_tv);
        TextView textView2 = (TextView) view.findViewById(R.id.dialog_content_tv);
        this.f16357b = (Button) view.findViewById(R.id.dialog_primary_button);
        this.f16358c = (Button) view.findViewById(R.id.dialog_second_button);
        if (!TextUtils.isEmpty(this.f16362g)) {
            this.f16357b.setText(this.f16362g);
        }
        if (!TextUtils.isEmpty(this.f16363h)) {
            this.f16358c.setText(this.f16363h);
        }
        textView.setText(this.f16359d);
        String language = Locale.getDefault().getLanguage();
        if (!TextUtils.isEmpty(language) && language.equals("en")) {
            textView.getPaint().setFakeBoldText(true);
        }
        if (this.f16360e != null) {
            String string = getString(R.string.service_license_two);
            String string2 = getString(R.string.service_policy_two);
            SpannableString spannableString = new SpannableString(this.f16360e);
            Matcher matcher = Pattern.compile(string).matcher(this.f16360e);
            int i2 = 0;
            int i3 = 0;
            while (matcher.find()) {
                i2 = matcher.start();
                i3 = matcher.end();
            }
            if (i2 != 0 && i3 != 0) {
                spannableString.setSpan(new e.l.b.a(getContext(), TextUtils.isEmpty("") ? "https://cdn.xylink.com/agreement/xylink-agreement.html" : ""), i2, i3, 33);
                i2 = 0;
                i3 = 0;
            }
            Matcher matcher2 = Pattern.compile(string2).matcher(this.f16360e);
            while (matcher2.find()) {
                i2 = matcher2.start();
                i3 = matcher2.end();
            }
            if (i2 != 0 && i3 != 0) {
                spannableString.setSpan(new e.l.b.a(getContext(), TextUtils.isEmpty("") ? "https://cdn.xylink.com/agreement/privacy-agreement.html" : ""), i2, i3, 33);
            }
            textView2.setText(spannableString);
            textView2.setMovementMethod(LinkMovementMethod.getInstance());
        }
        textView2.setGravity(0);
        this.f16357b.setOnClickListener(new C0301a());
        this.f16358c.setOnClickListener(new b());
        int i4 = this.f16365j;
        if (i4 != 0) {
            this.f16357b.setBackgroundResource(i4);
        }
        int i5 = this.f16366k;
        if (i5 != 0) {
            this.f16358c.setBackgroundResource(i5);
        }
    }

    public void show(FragmentActivity fragmentActivity) {
        m a = fragmentActivity.getSupportFragmentManager().a();
        a.a(this, this.f16364i);
        a.f();
    }

    public void a(d dVar) {
        this.a = dVar;
    }

    public static void a(g gVar, String str, String str2, String str3, String str4, d dVar, String str5) {
        m a = gVar.a();
        if (gVar.a(str5) != null) {
            a.d(gVar.a(str5)).f();
        }
        a a2 = new c().d(str).a((CharSequence) str2).a(str3).b(str4).a();
        a2.a(dVar);
        a2.setCancelable(false);
        gVar.a().a(a2, str5).f();
    }
}