#include <jni.h>
#include <string>
extern "C" JNIEXPORT jstring JNICALL
Java_com_example_cs_MainActivity_stringFromJNI(
JNIEnv* env,
jobject /* this */) {
std::string hello = "Hello from C++";
return env->NewStringUTF(hello.c_str());
}
目前這樣 我要怎么修改才能(*env)->NewStringUTF(hello.c_str());
現在剛剛學習用ndk開發android 希望有前輩指點下
轉載請註明出處,本文鏈接:https://www.uj5u.com/yidong/198867.html
標籤:Android
上一篇:SingleTask型別的activity怎么區分是新呼叫的還是亮屏恢復的?
下一篇:Android登錄界面
