From 7f6eadd8dcb4abf80a0f53603c5feb81602e5636 Mon Sep 17 00:00:00 2001 From: kunfei Date: Thu, 10 Oct 2019 17:28:34 +0800 Subject: [PATCH] up --- .../java/io/legado/app/ui/rss/read/ReadRssActivity.kt | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/app/src/main/java/io/legado/app/ui/rss/read/ReadRssActivity.kt b/app/src/main/java/io/legado/app/ui/rss/read/ReadRssActivity.kt index 4220d7575..fabb34ef9 100644 --- a/app/src/main/java/io/legado/app/ui/rss/read/ReadRssActivity.kt +++ b/app/src/main/java/io/legado/app/ui/rss/read/ReadRssActivity.kt @@ -1,6 +1,7 @@ package io.legado.app.ui.rss.read import android.os.Bundle +import android.webkit.WebViewClient import androidx.lifecycle.Observer import io.legado.app.R import io.legado.app.base.VMBaseActivity @@ -14,11 +15,16 @@ class ReadRssActivity : VMBaseActivity(R.layout.activity_rss_r get() = getViewModel(ReadRssViewModel::class.java) override fun onActivityCreated(savedInstanceState: Bundle?) { - initLiveData() title = intent.getStringExtra("title") + initWebView() + initLiveData() viewModel.initData(intent) } + private fun initWebView() { + webView.webViewClient = WebViewClient() + } + private fun initLiveData() { viewModel.contentLiveData.observe(this, Observer { content -> viewModel.rssArticle?.let {