mirror of
https://github.com/Relintai/pandemonium_engine.git
synced 2024-12-22 03:46:50 +01:00
Updated old paths in the android jni wrapper classes. This fixes the export templates.
This commit is contained in:
parent
c306c1ba1e
commit
d328372f38
@ -31,7 +31,7 @@ while IFS= read -rd '' f; do
|
||||
continue 2
|
||||
elif [[ "$f" == *"theme_data.h" ]]; then
|
||||
continue 2
|
||||
elif [[ "$f" == "platform/android/java/lib/src/org/pandemoniumengine/pandemonium/input/InputManager"* ]]; then
|
||||
elif [[ "$f" == "platform/android/java/lib/src/net/relintai/pandemonium/pandemonium/input/InputManager"* ]]; then
|
||||
continue 2
|
||||
fi
|
||||
#python misc/scripts/copyright_headers.py "$f"
|
||||
|
@ -2129,7 +2129,7 @@ bool EditorExportPlatformAndroid::can_export(const Ref<EditorExportPreset> &p_pr
|
||||
// The PandemoniumPaymentV3 module was converted to the external PandemoniumGooglePlayBilling plugin in Pandemonium 3.2.2,
|
||||
// this check helps users to notice the change to ensure that they change their settings.
|
||||
String modules = ProjectSettings::get_singleton()->get("android/modules");
|
||||
if (modules.find("org/pandemoniumengine/pandemonium/PandemoniumPaymentV3") != -1) {
|
||||
if (modules.find("net/relintai/pandemonium/pandemonium/PandemoniumPaymentV3") != -1) {
|
||||
bool pandemonium_google_play_billing_enabled = p_preset->get("plugins/PandemoniumGooglePlayBilling");
|
||||
if (!pandemonium_google_play_billing_enabled) {
|
||||
valid = false;
|
||||
|
@ -38,7 +38,7 @@
|
||||
|
||||
#include "string_android.h"
|
||||
|
||||
// Class that makes functions in java/src/org/pandemoniumengine/pandemonium/PandemoniumIO.java callable from C++
|
||||
// Class that makes functions in java/src/net/relintai/pandemonium/pandemonium/PandemoniumIO.java callable from C++
|
||||
class PandemoniumIOJavaWrapper {
|
||||
private:
|
||||
jobject pandemonium_io_instance;
|
||||
|
@ -91,7 +91,7 @@ static void _initialize_java_modules() {
|
||||
String m = mods[i];
|
||||
|
||||
// Deprecated in Pandemonium 3.2.2, it's now a plugin to enable in export preset.
|
||||
if (m == "org/pandemoniumengine/pandemonium/PandemoniumPaymentV3") {
|
||||
if (m == "java/src/net/relintai/pandemonium/pandemonium/PandemoniumPaymentV3") {
|
||||
WARN_PRINT("PandemoniumPaymentV3 is deprecated and is replaced by the 'PandemoniumPayment' plugin, which should be enabled in the Android export preset.");
|
||||
print_line("Skipping Android module: " + m);
|
||||
continue;
|
||||
@ -102,7 +102,7 @@ static void _initialize_java_modules() {
|
||||
jclass singletonClass = (jclass)env->CallObjectMethod(cls, findClass, strClassName);
|
||||
ERR_CONTINUE_MSG(!singletonClass, "Couldn't find singleton for class: " + m + ".");
|
||||
|
||||
jmethodID initialize = env->GetStaticMethodID(singletonClass, "initialize", "(Landroid/app/Activity;)Lorg/pandemoniumengine/pandemonium/Pandemonium$SingletonBase;");
|
||||
jmethodID initialize = env->GetStaticMethodID(singletonClass, "initialize", "(Landroid/app/Activity;)Ljava/src/net/relintai/pandemonium/pandemonium/Pandemonium$SingletonBase;");
|
||||
ERR_CONTINUE_MSG(!initialize, "Couldn't find proper initialize function 'public static Pandemonium.SingletonBase Class::initialize(Activity p_activity)' initializer for singleton class: " + m + ".");
|
||||
|
||||
jobject obj = env->CallStaticObjectMethod(singletonClass, initialize, pandemonium_java->get_activity());
|
||||
@ -127,7 +127,7 @@ JNIEXPORT void JNICALL Java_net_relintai_pandemonium_pandemonium_PandemoniumLib_
|
||||
|
||||
// create our wrapper classes
|
||||
pandemonium_java = new PandemoniumJavaWrapper(env, activity, pandemonium_instance);
|
||||
pandemonium_io_java = new PandemoniumIOJavaWrapper(env, pandemonium_java->get_member_object("io", "Lorg/pandemoniumengine/pandemonium/PandemoniumIO;", env));
|
||||
pandemonium_io_java = new PandemoniumIOJavaWrapper(env, pandemonium_java->get_member_object("io", "Lnet/relintai/pandemonium/pandemonium/PandemoniumIO;", env));
|
||||
|
||||
init_thread_jandroid(jvm, env);
|
||||
|
||||
@ -136,7 +136,7 @@ JNIEXPORT void JNICALL Java_net_relintai_pandemonium_pandemonium_PandemoniumLib_
|
||||
FileAccessAndroid::asset_manager = AAssetManager_fromJava(env, amgr);
|
||||
|
||||
DirAccessJAndroid::setup(pandemonium_io_java->get_instance());
|
||||
NetSocketAndroid::setup(pandemonium_java->get_member_object("netUtils", "Lorg/pandemoniumengine/pandemonium/utils/PandemoniumNetUtils;", env));
|
||||
NetSocketAndroid::setup(pandemonium_java->get_member_object("netUtils", "Lnet/relintai/pandemonium/pandemonium/utils/PandemoniumNetUtils;", env));
|
||||
|
||||
os_android = new OS_Android(pandemonium_java, pandemonium_io_java, p_use_apk_expansion);
|
||||
|
||||
|
@ -34,7 +34,7 @@
|
||||
#include <jni.h>
|
||||
|
||||
// These functions can be called from within JAVA and are the means by which our JAVA implementation calls back into our C++ code.
|
||||
// See java/src/org/pandemoniumengine/pandemonium/PandemoniumLib.java for the JAVA side of this (yes that's why we have the long names)
|
||||
// See java/src/net/relintai/pandemonium/pandemonium/PandemoniumLib.java for the JAVA side of this (yes that's why we have the long names)
|
||||
extern "C" {
|
||||
JNIEXPORT void JNICALL Java_net_relintai_pandemonium_pandemonium_PandemoniumLib_initialize(JNIEnv *env, jclass clazz, jobject activity, jobject pandemonium_instance, jobject p_asset_manager, jboolean p_use_apk_expansion);
|
||||
JNIEXPORT void JNICALL Java_net_relintai_pandemonium_pandemonium_PandemoniumLib_ondestroy(JNIEnv *env, jclass clazz);
|
||||
|
@ -42,7 +42,7 @@ PandemoniumJavaWrapper::PandemoniumJavaWrapper(JNIEnv *p_env, jobject p_activity
|
||||
activity = p_env->NewGlobalRef(p_activity);
|
||||
|
||||
// get info about our Pandemonium class so we can get pointers and stuff...
|
||||
pandemonium_class = p_env->FindClass("org/pandemoniumengine/pandemonium/Pandemonium");
|
||||
pandemonium_class = p_env->FindClass("net/relintai/pandemonium/pandemonium/Pandemonium");
|
||||
if (pandemonium_class) {
|
||||
pandemonium_class = (jclass)p_env->NewGlobalRef(pandemonium_class);
|
||||
} else {
|
||||
|
@ -100,7 +100,7 @@ jvalret _variant_to_jvalue(JNIEnv *env, Variant::Type p_type, const Variant *p_a
|
||||
|
||||
case Variant::DICTIONARY: {
|
||||
Dictionary dict = *p_arg;
|
||||
jclass dclass = env->FindClass("org/pandemoniumengine/pandemonium/Dictionary");
|
||||
jclass dclass = env->FindClass("net/relintai/pandemonium/pandemonium/Dictionary");
|
||||
jmethodID ctor = env->GetMethodID(dclass, "<init>", "()V");
|
||||
jobject jdict = env->NewObject(dclass, ctor);
|
||||
|
||||
@ -377,7 +377,7 @@ const char *get_jni_sig(const String &p_type) {
|
||||
{ "float", "F" },
|
||||
{ "double", "D" },
|
||||
{ "java.lang.String", "Ljava/lang/String;" },
|
||||
{ "net.relintai.pandemonium.pandemonium.Dictionary", "Lorg/pandemoniumengine/pandemonium/Dictionary;" },
|
||||
{ "net.relintai.pandemonium.pandemonium.Dictionary", "Lnet/relintai/pandemonium/pandemonium/Dictionary;" },
|
||||
{ "[I", "[I" },
|
||||
{ "[B", "[B" },
|
||||
{ "[F", "[F" },
|
||||
|
Loading…
Reference in New Issue
Block a user