Skip to content
This repository has been archived by the owner on Nov 17, 2024. It is now read-only.

Commit

Permalink
api
Browse files Browse the repository at this point in the history
  • Loading branch information
HIllya51 committed Nov 3, 2024
1 parent d35fb7a commit b395097
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions LunaHost/LunaHostDll.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -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);
}
Expand Down

0 comments on commit b395097

Please sign in to comment.