mirror of
https://github.com/geometer/FBReaderJ.git
synced 2025-10-03 17:59:33 +02:00
language/encoding detection (in progress)
This commit is contained in:
parent
bc97e8420a
commit
092c1f00d2
4 changed files with 14 additions and 20 deletions
|
@ -101,6 +101,17 @@ JNIEXPORT jboolean JNICALL Java_org_geometerplus_fbreader_formats_NativeFormatPl
|
|||
extern "C"
|
||||
JNIEXPORT void JNICALL Java_org_geometerplus_fbreader_formats_NativeFormatPlugin_detectLanguageAndEncoding(JNIEnv* env, jobject thiz, jobject javaBook) {
|
||||
// TODO: implement
|
||||
shared_ptr<FormatPlugin> plugin = findCppPlugin(env, thiz);
|
||||
if (plugin.isNull()) {
|
||||
return;
|
||||
}
|
||||
|
||||
shared_ptr<Book> book = Book::loadFromJavaBook(env, javaBook);
|
||||
if (!plugin->readLanguageAndEncoding(*book)) {
|
||||
return;
|
||||
}
|
||||
|
||||
//fillLanguageAndEncoding(env, javaBook, *book);
|
||||
}
|
||||
|
||||
static bool initBookModel(JNIEnv *env, jobject javaModel, BookModel &model) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue