From b39509705770ca0bf1b46d0cb5bf7a8199268715 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=81=8D=E5=85=AE=E6=83=9A=E5=85=AE?= <1173718158@qq.com> Date: Sun, 3 Nov 2024 23:56:19 +0800 Subject: [PATCH] api --- LunaHost/LunaHostDll.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/LunaHost/LunaHostDll.cpp b/LunaHost/LunaHostDll.cpp index b565325..e813b1c 100644 --- a/LunaHost/LunaHostDll.cpp +++ b/LunaHost/LunaHostDll.cpp @@ -150,14 +150,14 @@ C_LUNA_API void Luna_useembed(ThreadParam tp, bool use) } } -C_LUNA_API void Luna_embedcallback(DWORD pid, LPCWSTR text, LPCWSTR trans) +C_LUNA_API void Luna_embedcallback(ThreadParam tp, LPCWSTR text, LPCWSTR trans) { - auto sm = Host::GetCommonSharedMem(pid); + auto sm = Host::GetCommonSharedMem(tp.processId); if (!sm) return; wcsncpy(sm->text, trans, ARRAYSIZE(sm->text)); char eventname[1000]; - sprintf(eventname, LUNA_EMBED_notify_event, pid, simplehash::djb2_n2((const unsigned char *)(text), wcslen(text) * 2)); + sprintf(eventname, LUNA_EMBED_notify_event, tp.processId, simplehash::djb2_n2((const unsigned char *)(text), wcslen(text) * 2)); win_event event1(eventname); event1.signal(true); }