Library update (#78)
* Added print functionality to PDF viewer * feat(pdf): add interactive button support and visibility reveal heuristic * Moved search state management to MainViewModel and improved search UI interaction. * Updated `pdfiumandroid` to version 2.0.0 and handled resulting API changes, including nullable page/text page returns and revised native pointer access. increased compileSdk to 36. * Fixed Table of Contents (TOC) truncation bug and improved the TOC UI in `PdfViewerScreen`. - Implemented `getFixedTableOfContents` using reflection to bypass a library issue where sibling nodes were incorrectly truncated during traversal. - Enhanced the TOC drawer with a nested, expandable tree structure using the new `PdfTocTreeItem` component. - Added a custom `VerticalScrollbar` with draggable support for better navigation within long TOC lists. - Integrated `animateColorAsState` and `animateFloatAsState` for smoother UI transitions in the TOC and scrollbar. - Optimized TOC loading by flattening the tree structure and managing expansion states with `rememberSaveable`. * Improved zoom pivot calculation and interaction handling in PdfVerticalReader * Fixed high-res PDF tile bleeding by implementing clipRect in PdfBitmapLayer * fix(pdf): resolve zoom stuttering, in pagination mode, by removing eager scale snapping * Added book pinning and library filtering functionality * Updated folder sync logic, improved metadata extraction, and added persistent banner message while syncing * build: bump version to 1.0.37 (38)
This commit is contained in:
parent
1884ace646
commit
d6f7509e81
7 changed files with 338 additions and 37 deletions
|
|
@ -15,7 +15,6 @@ data class FolderBookMetadata(
|
|||
val lastPositionCfi: String?,
|
||||
val progressPercentage: Float,
|
||||
val isRecent: Boolean,
|
||||
// REMOVED: val isDeleted: Boolean,
|
||||
val lastModifiedTimestamp: Long,
|
||||
val bookmarksJson: String?,
|
||||
val locatorBlockIndex: Int?,
|
||||
|
|
@ -33,7 +32,6 @@ data class FolderBookMetadata(
|
|||
json.put("lastPositionCfi", lastPositionCfi)
|
||||
json.put("progressPercentage", progressPercentage.toDouble())
|
||||
json.put("isRecent", isRecent)
|
||||
// REMOVED: json.put("isDeleted", isDeleted)
|
||||
json.put("lastModifiedTimestamp", lastModifiedTimestamp)
|
||||
json.put("bookmarksJson", bookmarksJson)
|
||||
json.put("locatorBlockIndex", locatorBlockIndex ?: -1)
|
||||
|
|
@ -65,7 +63,6 @@ data class FolderBookMetadata(
|
|||
lastPositionCfi = json.optStringNull("lastPositionCfi"),
|
||||
progressPercentage = json.optDouble("progressPercentage", 0.0).toFloat(),
|
||||
isRecent = json.optBoolean("isRecent", true),
|
||||
// REMOVED: isDeleted deserialization
|
||||
lastModifiedTimestamp = json.optLong("lastModifiedTimestamp", 0L),
|
||||
bookmarksJson = json.optStringNull("bookmarksJson"),
|
||||
locatorBlockIndex = json.optIntNull("locatorBlockIndex"),
|
||||
|
|
@ -75,7 +72,6 @@ data class FolderBookMetadata(
|
|||
}
|
||||
}
|
||||
|
||||
// Update the converter
|
||||
fun FolderBookMetadata.toRecentFileItem(uriString: String?, coverPath: String?, sourceFolderUri: String?): RecentFileItem {
|
||||
return RecentFileItem(
|
||||
bookId = this.bookId,
|
||||
|
|
@ -95,7 +91,7 @@ fun FolderBookMetadata.toRecentFileItem(uriString: String?, coverPath: String?,
|
|||
isRecent = this.isRecent,
|
||||
isAvailable = true,
|
||||
lastModifiedTimestamp = this.lastModifiedTimestamp,
|
||||
isDeleted = false, // ALWAYS FALSE for folder sync
|
||||
isDeleted = false,
|
||||
bookmarksJson = this.bookmarksJson,
|
||||
sourceFolderUri = sourceFolderUri
|
||||
)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue