package pi0; import android.view.View; import android.view.ViewStub; import android.webkit.WebSettings; import android.webkit.WebView; import android.widget.ProgressBar; import b.d; import em3.q; import jp.naver.line.android.R; import kotlin.Unit; import z1.g; public final class k { /* renamed from: a reason: collision with root package name */ public final View f127821a; /* renamed from: b reason: collision with root package name */ public final dm3.a<Unit> f127822b; /* renamed from: c reason: collision with root package name */ public final WebView f127823c; /* renamed from: d reason: collision with root package name */ public final View f127824d; /* renamed from: e reason: collision with root package name */ public final ProgressBar f127825e; /* renamed from: f reason: collision with root package name */ public final a f127826f = new a(); /* renamed from: g reason: collision with root package name */ public final ViewStub f127827g; /* renamed from: h reason: collision with root package name */ public final String f127828h; /* renamed from: i reason: collision with root package name */ public View f127829i; public final class a extends l { /* JADX WARN: Incorrect args count in method signature: ()V */ public a() { } } public k(View view, dm3.a<Unit> aVar) { this.f127821a = view; this.f127822b = aVar; View findViewById = view.findViewById(R.id.webview_RES_2131372356); q.e(findViewById, "baseView.findViewById(R.id.webview)"); WebView webView = (WebView) findViewById; this.f127823c = webView; View findViewById2 = view.findViewById(R.id.ocr_user_agreement_content_layout); q.e(findViewById2, "baseView.findViewById(R.…agreement_content_layout)"); this.f127824d = findViewById2; View findViewById3 = view.findViewById(R.id.progressBar); q.e(findViewById3, "baseView.findViewById(R.id.progressBar)"); this.f127825e = (ProgressBar) findViewById3; this.f127827g = (ViewStub) view.findViewById(R.id.ocr_user_agreement_error_view_stub); String c14 = g.c(); q.e(c14, "getLanguage()"); this.f127828h = c14; WebSettings settings = webView.getSettings(); settings.setJavaScriptEnabled(true); settings.setAllowContentAccess(false); settings.setAllowFileAccess(false); settings.setDomStorageEnabled(true); settings.setGeolocationEnabled(true); settings.setUseWideViewPort(true); settings.setLoadWithOverviewMode(true); settings.setBuiltInZoomControls(true); settings.setDisplayZoomControls(false); settings.setSupportMultipleWindows(true); try { settings.setLayoutAlgorithm(WebSettings.LayoutAlgorithm.TEXT_AUTOSIZING); settings.setMixedContentMode(2); } catch (Exception unused) { } this.f127823c.setScrollBarStyle(33554432); this.f127823c.setWebViewClient(this.f127826f); WebView webView2 = this.f127823c; StringBuilder a14 = d.a("https://terms.line.me/line_ocr_ml/sp?lang="); a14.append(this.f127828h); webView2.loadUrl(a14.toString()); } public final void a() { this.f127826f.f127831a = false; View view = this.f127829i; if (view != null) { view.setVisibility(8); } this.f127824d.setVisibility(8); WebView webView = this.f127823c; StringBuilder a14 = d.a("https://terms.line.me/line_ocr_ml/sp?lang="); a14.append(this.f127828h); webView.loadUrl(a14.toString()); } }