Using chapter number instead of chapter title for sharing pages
This commit is contained in:
parent
b6bdc1fc0d
commit
11598362b8
@ -83,6 +83,8 @@ import nucleus.factory.RequiresPresenter
|
|||||||
import timber.log.Timber
|
import timber.log.Timber
|
||||||
import uy.kohesive.injekt.injectLazy
|
import uy.kohesive.injekt.injectLazy
|
||||||
import java.io.File
|
import java.io.File
|
||||||
|
import java.text.DecimalFormat
|
||||||
|
import java.text.DecimalFormatSymbols
|
||||||
import java.util.Locale
|
import java.util.Locale
|
||||||
import kotlin.math.abs
|
import kotlin.math.abs
|
||||||
|
|
||||||
@ -649,7 +651,13 @@ class ReaderActivity : BaseRxActivity<ReaderPresenter>(),
|
|||||||
val manga = presenter.manga ?: return
|
val manga = presenter.manga ?: return
|
||||||
val chapter = page.chapter.chapter
|
val chapter = page.chapter.chapter
|
||||||
|
|
||||||
val text = "${manga.title}: ${chapter.name}, ${getString(R.string.page_, page.number)}"
|
val decimalFormat =
|
||||||
|
DecimalFormat("#.###", DecimalFormatSymbols().apply { decimalSeparator = '.' })
|
||||||
|
|
||||||
|
val text = "${manga.title}: ${getString(
|
||||||
|
R.string.chapter_,
|
||||||
|
decimalFormat.format(chapter.chapter_number)
|
||||||
|
)}, ${getString(R.string.page_, page.number)}"
|
||||||
|
|
||||||
val stream = file.getUriCompat(this)
|
val stream = file.getUriCompat(this)
|
||||||
val intent = Intent(Intent.ACTION_SEND).apply {
|
val intent = Intent(Intent.ACTION_SEND).apply {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user