-
Notifications
You must be signed in to change notification settings - Fork 37
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use odrcode http #380
base: main
Are you sure you want to change the base?
Use odrcode http #380
Conversation
andiwand
commented
Jan 10, 2025
- Switch to use http for new odrcore
- Use odrcode pdf2htmlex
- Allows lazy loading for pdf
// TODO can and should this be architecture dependent? | ||
sourceSets.main.assets.srcDirs += "build/conan/armv8/assets" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@TomTasche not sure if this is even relevant
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess the assets we care about are not arch-dependent? still makes sense to keep the TODO in case someone considers adding arch-dependent assets...
odrcore/4.1.1@ | ||
odrcore/9.9.9@ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
TODO: use newly tagged version when it is published
@@ -49,6 +49,7 @@ | |||
android:label="@string/app_title" | |||
android:roundIcon="@mipmap/ic_launcher_round" | |||
android:theme="@style/MainTheme" | |||
android:networkSecurityConfig="@xml/network_security_config" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@TomTasche this was necessary to get HTTP working. without that we have to use HTTPS
JNIEXPORT void JNICALL | ||
Java_at_tomtasche_reader_background_CoreWrapper_listenServerNative(JNIEnv *env, jclass clazz) { | ||
s_server->listen("127.0.0.1", 29665); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
TODO: configure port
String id = CoreWrapper.hostFile(coreOptions); | ||
|
||
result.partTitles.add("document"); | ||
result.partUris.add(Uri.parse("http://localhost:29665/" + id + "/document.html")); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
TODO: configure port
loader = odfLoader; | ||
loader = coreHttpLoader; | ||
break; | ||
case DOC: | ||
loader = docLoader; | ||
loader = coreHttpLoader; | ||
break; | ||
case OOXML: | ||
loader = ooxmlLoader; | ||
loader = coreHttpLoader; | ||
break; | ||
case PDF: | ||
loader = pdfLoader; | ||
loader = coreHttpLoader; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
TODO
@@ -5,11 +5,11 @@ | |||
|
|||
public class CoreWrapper { | |||
|
|||
public void initialize() { | |||
static { | |||
System.loadLibrary("odr-core"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
TODO: communicate data paths for core