From 865e6acd7a2180c5bf6f46f2fc382b7c5fb790bf Mon Sep 17 00:00:00 2001 From: kunfei Date: Sun, 13 Oct 2019 18:04:22 +0800 Subject: [PATCH] up --- .../java/io/legado/app/receiver/SharedReceiverActivity.kt | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/app/src/main/java/io/legado/app/receiver/SharedReceiverActivity.kt b/app/src/main/java/io/legado/app/receiver/SharedReceiverActivity.kt index bdda26939..39118dc5f 100644 --- a/app/src/main/java/io/legado/app/receiver/SharedReceiverActivity.kt +++ b/app/src/main/java/io/legado/app/receiver/SharedReceiverActivity.kt @@ -3,7 +3,6 @@ package io.legado.app.receiver import android.content.Intent import android.os.Build import android.os.Bundle -import android.os.PersistableBundle import androidx.appcompat.app.AppCompatActivity import io.legado.app.ui.book.search.SearchActivity import io.legado.app.ui.main.MainActivity @@ -13,8 +12,8 @@ class SharedReceiverActivity : AppCompatActivity() { private val receivingType = "text/plain" - override fun onCreate(savedInstanceState: Bundle?, persistentState: PersistableBundle?) { - super.onCreate(savedInstanceState, persistentState) + override fun onCreate(savedInstanceState: Bundle?) { + super.onCreate(savedInstanceState) initIntent() finish() } @@ -25,7 +24,6 @@ class SharedReceiverActivity : AppCompatActivity() { if (openUrl(it)) { startActivity(Pair("key", it)) } - finish() } } else if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M && Intent.ACTION_PROCESS_TEXT == intent.action @@ -35,7 +33,6 @@ class SharedReceiverActivity : AppCompatActivity() { if (openUrl(it)) { startActivity(Pair("key", it)) } - finish() } } }