pull/2533/head
kunfei 2 years ago
parent b4f1a79633
commit c253ced3aa
  1. 4
      app/src/main/java/io/legado/app/ui/association/AddToBookshelfDialog.kt

@ -1,5 +1,6 @@
package io.legado.app.ui.association package io.legado.app.ui.association
import android.annotation.SuppressLint
import android.app.Application import android.app.Application
import android.content.DialogInterface import android.content.DialogInterface
import android.os.Bundle import android.os.Bundle
@ -45,6 +46,7 @@ class AddToBookshelfDialog() : BaseDialogFragment(R.layout.dialog_add_to_bookshe
} }
} }
@SuppressLint("SetTextI18n")
override fun onFragmentCreated(view: View, savedInstanceState: Bundle?) { override fun onFragmentCreated(view: View, savedInstanceState: Bundle?) {
val bookUrl = arguments?.getString("bookUrl") val bookUrl = arguments?.getString("bookUrl")
if (bookUrl.isNullOrBlank()) { if (bookUrl.isNullOrBlank()) {
@ -64,7 +66,7 @@ class AddToBookshelfDialog() : BaseDialogFragment(R.layout.dialog_add_to_bookshe
dismiss() dismiss()
} }
viewModel.load(bookUrl) { viewModel.load(bookUrl) {
binding.tvMessage binding.tvMessage.text = "${it.name}(${it.author})"
} }
binding.tvCancel.setOnClickListener { binding.tvCancel.setOnClickListener {
dismiss() dismiss()

Loading…
Cancel
Save