删除无效代码

pull/946/head
gedoor 4 years ago
parent e60e9e2c12
commit f6fcd2b3b6
  1. 25
      app/src/main/java/io/legado/app/help/BookHelp.kt

@ -77,31 +77,6 @@ object BookHelp {
postEvent(EventBus.SAVE_CONTENT, bookChapter) postEvent(EventBus.SAVE_CONTENT, bookChapter)
} }
@Suppress("unused")
fun saveFont(book: Book, bookChapter: BookChapter, font: ByteArray) {
FileUtils.createFileIfNotExist(
downloadDir,
cacheFolderName,
book.getFolderName(),
"font",
bookChapter.getFontName()
).writeBytes(font)
}
fun getFontPath(book: Book, bookChapter: BookChapter): String? {
val fontFile = FileUtils.getFile(
downloadDir,
cacheFolderName,
book.getFolderName(),
"font",
bookChapter.getFontName()
)
if (fontFile.exists()) {
return fontFile.absolutePath
}
return null
}
suspend fun saveImage(book: Book, src: String) { suspend fun saveImage(book: Book, src: String) {
while (downloadImages.contains(src)) { while (downloadImages.contains(src)) {
delay(100) delay(100)

Loading…
Cancel
Save