|
|
@ -17,7 +17,6 @@ import io.legado.app.ui.book.read.page.provider.ChapterProvider |
|
|
|
import io.legado.app.utils.activity |
|
|
|
import io.legado.app.utils.activity |
|
|
|
import io.legado.app.utils.screenshot |
|
|
|
import io.legado.app.utils.screenshot |
|
|
|
import kotlinx.android.synthetic.main.activity_book_read.view.* |
|
|
|
import kotlinx.android.synthetic.main.activity_book_read.view.* |
|
|
|
import java.util.* |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class PageView(context: Context, attrs: AttributeSet) : |
|
|
|
class PageView(context: Context, attrs: AttributeSet) : |
|
|
|
FrameLayout(context, attrs), |
|
|
|
FrameLayout(context, attrs), |
|
|
@ -110,9 +109,7 @@ class PageView(context: Context, attrs: AttributeSet) : |
|
|
|
fun upPageAnim() { |
|
|
|
fun upPageAnim() { |
|
|
|
pageDelegate?.onDestroy() |
|
|
|
pageDelegate?.onDestroy() |
|
|
|
pageDelegate = null |
|
|
|
pageDelegate = null |
|
|
|
pageDelegate = if (ReadBook.imageStyle?.toUpperCase(Locale.ROOT) == "FULL") { |
|
|
|
pageDelegate = when (ReadBookConfig.pageAnim) { |
|
|
|
ScrollPageDelegate(this) |
|
|
|
|
|
|
|
} else when (ReadBookConfig.pageAnim) { |
|
|
|
|
|
|
|
0 -> CoverPageDelegate(this) |
|
|
|
0 -> CoverPageDelegate(this) |
|
|
|
1 -> SlidePageDelegate(this) |
|
|
|
1 -> SlidePageDelegate(this) |
|
|
|
2 -> SimulationPageDelegate(this) |
|
|
|
2 -> SimulationPageDelegate(this) |
|
|
|