Skip to content

Commit 0f2b280

Browse files
committed
Harmony port: entrypoint
1 parent 231ed48 commit 0f2b280

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

src/core/ohos/SDL_ohos.c

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
#include "../../video/ohos/SDL_ohoskeyboard.h"
1717

1818
static OHNativeWindow *g_ohosNativeWindow;
19-
SDL_Mutex *g_ohosPageMutex = NULL;
19+
static SDL_Mutex *g_ohosPageMutex = NULL;
2020
static OH_NativeXComponent_Callback callback;
2121
static OH_NativeXComponent_MouseEvent_Callback mouseCallback;
2222
static int x, y, wid, hei;
@@ -187,6 +187,11 @@ static napi_value sdlCallbackInit(napi_env env, napi_callback_info info)
187187
return result;
188188
}
189189

190+
static napi_value sdlLaunchMain(napi_env env, napi_callback_info info)
191+
{
192+
193+
}
194+
190195
static void OnSurfaceCreatedCB(OH_NativeXComponent *component, void *window)
191196
{
192197
g_ohosNativeWindow = (OHNativeWindow *)window;
@@ -265,7 +270,8 @@ static napi_value SDL_OHOS_NAPI_Init(napi_env env, napi_value exports)
265270
{
266271
napi_property_descriptor desc[] = {
267272
{ "minus", NULL, minus, NULL, NULL, NULL, napi_default, NULL },
268-
{ "sdlCallbackInit", NULL, sdlCallbackInit, NULL, NULL, NULL, napi_default, NULL }
273+
{ "sdlCallbackInit", NULL, sdlCallbackInit, NULL, NULL, NULL, napi_default, NULL },
274+
{ "sdlLaunchMain", NULL, sdlLaunchMain, NULL, NULL, NULL, napi_default, NULL }
269275
};
270276
napi_define_properties(env, exports, sizeof(desc) / sizeof(desc[0]), desc);
271277

0 commit comments

Comments
 (0)