diff --git a/app/src/main/java/io/legado/app/constant/Bus.kt b/app/src/main/java/io/legado/app/constant/Bus.kt index 6d7c7b872..12e72949d 100644 --- a/app/src/main/java/io/legado/app/constant/Bus.kt +++ b/app/src/main/java/io/legado/app/constant/Bus.kt @@ -8,4 +8,5 @@ object Bus { const val TTS_RANGE_START = "readAloudNumber" const val BATTERY_CHANGED = "batteryChanged" const val TIME_CHANGED = "timeChanged" + const val READ_ALOUD = "readAloud" } \ No newline at end of file diff --git a/app/src/main/java/io/legado/app/ui/readbook/ReadBookActivity.kt b/app/src/main/java/io/legado/app/ui/readbook/ReadBookActivity.kt index 629a0bfeb..f0389a93e 100644 --- a/app/src/main/java/io/legado/app/ui/readbook/ReadBookActivity.kt +++ b/app/src/main/java/io/legado/app/ui/readbook/ReadBookActivity.kt @@ -244,5 +244,8 @@ class ReadBookActivity : VMBaseActivity(R.layout.activity_rea observeEvent(Bus.ALOUD_STATE) { readAloudStatus = it } observeEvent(Bus.TTS_START) {} observeEvent(Bus.TTS_RANGE_START) {} + observeEvent(Bus.TIME_CHANGED) {} + observeEvent(Bus.BATTERY_CHANGED) {} + observeEvent(Bus.READ_ALOUD) { onClickReadAloud() } } } \ No newline at end of file