|
|
@ -63,7 +63,7 @@ class TextFile(private val book: Book) { |
|
|
|
var blockContent: String |
|
|
|
var blockContent: String |
|
|
|
var length = bis.read(buffer) |
|
|
|
var length = bis.read(buffer) |
|
|
|
if (book.charset.isNullOrBlank()) { |
|
|
|
if (book.charset.isNullOrBlank()) { |
|
|
|
book.charset = EncodingDetect.getEncode(buffer) |
|
|
|
book.charset = EncodingDetect.getEncode(buffer.copyOf(length)) |
|
|
|
} |
|
|
|
} |
|
|
|
charset = book.fileCharset() |
|
|
|
charset = book.fileCharset() |
|
|
|
blockContent = String(buffer, 0, length, charset) |
|
|
|
blockContent = String(buffer, 0, length, charset) |
|
|
|