mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Android: Add support for sharing debug.txt (#12370)
This commit is contained in:
parent
a69b7abe00
commit
4baf56520d
9 changed files with 81 additions and 2 deletions
|
@ -213,6 +213,18 @@ void openURIAndroid(const std::string &url)
|
|||
jnienv->CallVoidMethod(app_global->activity->clazz, url_open, jurl);
|
||||
}
|
||||
|
||||
void shareFileAndroid(const std::string &path)
|
||||
{
|
||||
jmethodID url_open = jnienv->GetMethodID(nativeActivity, "shareFile",
|
||||
"(Ljava/lang/String;)V");
|
||||
|
||||
FATAL_ERROR_IF(url_open == nullptr,
|
||||
"porting::shareFileAndroid unable to find java openURI method");
|
||||
|
||||
jstring jurl = jnienv->NewStringUTF(path.c_str());
|
||||
jnienv->CallVoidMethod(app_global->activity->clazz, url_open, jurl);
|
||||
}
|
||||
|
||||
int getInputDialogState()
|
||||
{
|
||||
jmethodID dialogstate = jnienv->GetMethodID(nativeActivity,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue