diff --git a/app/build.gradle b/app/build.gradle index 23f23ca..1a5492d 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -44,7 +44,7 @@ def getVersionName(){ def hun = (version / 100).toInteger() def ten = (version / 10).toInteger() % 10 def one = version % 10 - return hun + "." + ten + "." + one + "-debug" + return hun + "." + ten + "." + one } def versionN = getVersionName() diff --git a/app/src/main/java/xyz/fycz/myreader/entity/sourceedit/EditEntityUtil.kt b/app/src/main/java/xyz/fycz/myreader/entity/sourceedit/EditEntityUtil.kt index 72d9b4a..492b78c 100644 --- a/app/src/main/java/xyz/fycz/myreader/entity/sourceedit/EditEntityUtil.kt +++ b/app/src/main/java/xyz/fycz/myreader/entity/sourceedit/EditEntityUtil.kt @@ -33,7 +33,7 @@ object EditEntityUtil { ) add(EditEntity("loginUrl", source?.loginUrl, R.string.login_url, "")) add(EditEntity("sourceComment", source?.sourceComment, R.string.comment, "这是您留给使用者的说明")) - add(EditEntity("concurrentRate", source?.concurrentRate, R.string.comment, "")) + add(EditEntity("concurrentRate", source?.concurrentRate, R.string.source_concurrent_rate, "")) } return sourceEntities } diff --git a/app/src/main/java/xyz/fycz/myreader/ui/activity/SourceLoginActivity.java b/app/src/main/java/xyz/fycz/myreader/ui/activity/SourceLoginActivity.java index 16aaec5..250a9f1 100644 --- a/app/src/main/java/xyz/fycz/myreader/ui/activity/SourceLoginActivity.java +++ b/app/src/main/java/xyz/fycz/myreader/ui/activity/SourceLoginActivity.java @@ -1,5 +1,6 @@ package xyz.fycz.myreader.ui.activity; +import android.annotation.SuppressLint; import android.graphics.Bitmap; import android.os.Bundle; import android.view.Menu; @@ -54,12 +55,16 @@ public class SourceLoginActivity extends BaseActivity { } @Override + @SuppressLint("SetJavaScriptEnabled") protected void initWidget() { WebSettings settings = binding.webView.getSettings(); settings.setSupportZoom(true); settings.setBuiltInZoomControls(true); settings.setDefaultTextEncodingName("UTF-8"); - //settings.setUserAgentString(APPCONST.DEFAULT_USER_AGENT); + settings.setLoadWithOverviewMode(true); + if (bookSource.getHeaderMap(false).containsKey(APPCONST.UA_NAME)){ + settings.setUserAgentString(bookSource.getHeaderMap(false).get(APPCONST.UA_NAME)); + } settings.setJavaScriptEnabled(true); CookieManager cookieManager = CookieManager.getInstance(); binding.webView.setWebViewClient(new WebViewClient() {