fix epub reader playback and trial navigation

This commit is contained in:
shen
2026-07-11 08:16:56 +08:00
parent d7fcda345d
commit 063a493b18
231 changed files with 435 additions and 36060 deletions
@@ -398,6 +398,7 @@ final class RDEPUBTextContentView: UIView, UIGestureRecognizerDelegate, RDEpubRe
pageNumber: Int,
totalPages: Int,
configuration: RDEPUBReaderConfiguration,
contentInsets: UIEdgeInsets? = nil,
chapterCFIMap: RDEPUBCFIMap? = nil,
chapterFragmentOffsets: [String: Int] = [:],
highlights: [RDEPUBHighlight] = [],
@@ -414,7 +415,7 @@ final class RDEPUBTextContentView: UIView, UIGestureRecognizerDelegate, RDEpubRe
currentHighlights = highlights
currentSearchState = searchState
selectionController.clearSelection(renderView: coreTextRenderView)
contentInsets = Self.safeContentInsets(
self.contentInsets = contentInsets ?? Self.safeContentInsets(
configuration: configuration,
safeAreaInsets: RDEPUBSafeArea.resolve(safeAreaInsets)
)
@@ -491,7 +492,8 @@ final class RDEPUBTextContentView: UIView, UIGestureRecognizerDelegate, RDEpubRe
func configureLoading(
pageNumber: Int,
totalPages: Int,
configuration: RDEPUBReaderConfiguration
configuration: RDEPUBReaderConfiguration,
contentInsets: UIEdgeInsets? = nil
) {
currentPage = nil
currentChapterCFIMap = nil
@@ -502,7 +504,7 @@ final class RDEPUBTextContentView: UIView, UIGestureRecognizerDelegate, RDEpubRe
currentHighlights = []
currentSearchState = nil
selectionController.clearSelection(renderView: coreTextRenderView)
contentInsets = Self.safeContentInsets(
self.contentInsets = contentInsets ?? Self.safeContentInsets(
configuration: configuration,
safeAreaInsets: RDEPUBSafeArea.resolve(safeAreaInsets)
)