18034727885
2026-09-16 1dd795143830b92247cd2c79841fe49a134b4352
mylibrary/src/main/java/com/example/mylibrary/WebPayActivity.kt
@@ -90,6 +90,7 @@
            v.setPadding(systemBars.left, systemBars.top, systemBars.right, systemBars.bottom)
            insets
        }
        title?.takeIf { !it.isEmpty() }?.also { tvTitle.text = it }
        ivClose.setOnClickListener { finish() }
        clearWebViewCache()
        initWebView()
@@ -196,7 +197,9 @@
        webView.webChromeClient = object : WebChromeClient() {
            override fun onReceivedTitle(view: WebView?, title: String?) {
                super.onReceivedTitle(view, title)
                tvTitle.text = title?.ifEmpty { this@WebPayActivity.title } ?: ""
                if (this@WebPayActivity.title.isNullOrEmpty() && !title.isNullOrEmpty()) {
                    tvTitle.text = title
                }
            }
            /**