Skip to content

Commit a0751e3

Browse files
committed
fix doc
1 parent 01f85de commit a0751e3

2 files changed

Lines changed: 9 additions & 4 deletions

File tree

app/src/main/AndroidManifest.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
33
xmlns:tools="http://schemas.android.com/tools"
44
android:installLocation="auto"
5-
android:versionCode="195"
6-
android:versionName="3.40"
5+
android:versionCode="196"
6+
android:versionName="4.0"
77
tools:ignore="GoogleAppIndexingWarning">
88

99
<uses-permission android:name="android.permission.INTERNET" />

app/src/main/cpp/core_wrapper.cpp

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,8 @@ Java_at_tomtasche_reader_background_CoreWrapper_parseNative(JNIEnv *env, jclass
185185
}
186186
}
187187

188-
if (file.is_document_file()) {
188+
// .doc-files are not real documents in core
189+
if (file.is_document_file() && fileType != odr::FileType::legacy_word_document) {
189190
// TODO this will cause a second load
190191
s_document = file.as_document_file().document();
191192
}
@@ -399,7 +400,11 @@ Java_at_tomtasche_reader_background_CoreWrapper_hostFileNative(JNIEnv *env, jcla
399400
}
400401
}
401402

402-
if (file.is_document_file()) {
403+
__android_log_print(ANDROID_LOG_INFO, "smn", "type=%s",
404+
file_type_to_string(file.file_type()).c_str());
405+
406+
// .doc-files are not real documents in core
407+
if (file.is_document_file() && file.file_type() != odr::FileType::legacy_word_document) {
403408
// TODO this will cause a second load
404409
s_document = file.as_document_file().document();
405410
}

0 commit comments

Comments
 (0)