From af5ef7fc9ed0bb5af52e0ec9c893502448f78917 Mon Sep 17 00:00:00 2001 From: Nikolay Igotti Date: Tue, 18 Feb 2025 18:03:42 +0300 Subject: [PATCH 1/2] Fix ANI typo Signed-off-by: Nikolay Igotti --- interop/src/cpp/ani/convertors-ani.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/interop/src/cpp/ani/convertors-ani.h b/interop/src/cpp/ani/convertors-ani.h index 6ca8e43d9..c6aaaf46c 100644 --- a/interop/src/cpp/ani/convertors-ani.h +++ b/interop/src/cpp/ani/convertors-ani.h @@ -1367,11 +1367,11 @@ void getKoalaEtsNapiCallbackDispatcher(ani_class* clazz, ani_method* method); #else #define KOALA_INTEROP_CALL_VOID(venv, id, length, args) -#define KOALA_INTEROP_CALL_INT(venv, id, length, args) -#define KOALA_INTEROP_CALL_VOID_INTS32(venv, id, argc, args) -#define KOALA_INTEROP_CALL_INT_INTS32(venv, id, argc, args) -#define KOALA_INTEROP_THROW(vmContext, object, ...) -#define KOALA_INTEROP_THROW_STRING(vmContext, message, ...) +#define KOALA_INTEROP_CALL_INT(venv, id, length, args) { return 0; } +#define KOALA_INTEROP_CALL_VOID_INTS32(venv, id, argc, args) { return; } +#define KOALA_INTEROP_CALL_INT_INTS32(venv, id, argc, args) { return 0; } +#define KOALA_INTEROP_THROW(vmContext, object, ...) { return __VA_ARGS__; } +#define KOALA_INTEROP_THROW_STRING(vmContext, message, ...) { return __VA_ARGS__; } #endif #endif // KOALA_ETS_NAPI -- Gitee From 8a0f8edfe5917b0047d30e08daf676edff3e0b91 Mon Sep 17 00:00:00 2001 From: Nikolay Igotti Date: Tue, 18 Feb 2025 18:08:18 +0300 Subject: [PATCH 2/2] Fix Java Signed-off-by: Nikolay Igotti --- interop/src/cpp/common-interop.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/interop/src/cpp/common-interop.cc b/interop/src/cpp/common-interop.cc index cd3146017..f7f5b74a6 100644 --- a/interop/src/cpp/common-interop.cc +++ b/interop/src/cpp/common-interop.cc @@ -310,7 +310,7 @@ KBoolean impl_RunApplication(const KInt arg0, const KInt arg1) { } KOALA_INTEROP_2(RunApplication, KBoolean, KInt, KInt) -KStringPtr impl_EmitEvent(const KInt type, const KInt target, const KInt arg0, const KInt arg1) { +KStringPtr impl_EmitEvent(KVMContext vmContext, KInt type, KInt target, KInt arg0, KInt arg1) { static EmitEvent_t impl = nullptr; if (!impl) impl = reinterpret_cast(getImpl(nullptr, "EmitEvent")); const char* out = impl(type, target, arg0, arg1); @@ -318,7 +318,7 @@ KStringPtr impl_EmitEvent(const KInt type, const KInt target, const KInt arg0, c KStringPtr result(out, size, true); return result; } -KOALA_INTEROP_4(EmitEvent,KStringPtr, KInt, KInt, KInt, KInt) +KOALA_INTEROP_CTX_4(EmitEvent, KStringPtr, KInt, KInt, KInt, KInt) void impl_RestartWith(const KStringPtr& page) { static RestartWith_t impl = nullptr; -- Gitee