https://git.reactos.org/?p=reactos.git;a=commitdiff;h=bfd5d37fe6223351d3606…
commit bfd5d37fe6223351d36066c28cf06e45664a021f
Author: Katayama Hirofumi MZ <katayama.hirofumi.mz(a)gmail.com>
AuthorDate: Wed Dec 13 07:37:45 2023 +0900
Commit: GitHub <noreply(a)github.com>
CommitDate: Wed Dec 13 07:37:45 2023 +0900
[MSCTF][SDK][UUID] Strengthen msctf.idl and msctf.spec (#6158)
- Add some function prototypes to
sdk/include/psdk/msctf.idl.
- Modify dll/win32/msctf/msctf.spec.
- Modify uuid.
CORE-19362
---
dll/win32/msctf/msctf.spec | 10 ++++++----
sdk/include/psdk/msctf.idl | 20 +++++++++++++-------
sdk/lib/uuid/CMakeLists.txt | 2 +-
sdk/lib/uuid/msctf_g.c | 44 ++++++++++++++++++++++++++++++++++++++++++++
4 files changed, 64 insertions(+), 12 deletions(-)
diff --git a/dll/win32/msctf/msctf.spec b/dll/win32/msctf/msctf.spec
index c3d909ccf5d..779ef12c79f 100644
--- a/dll/win32/msctf/msctf.spec
+++ b/dll/win32/msctf/msctf.spec
@@ -9,14 +9,14 @@
@ stub TF_CheckThreadInputIdle
@ stub TF_ClearLangBarAddIns
@ stub TF_CreateCategoryMgr
-@ stub TF_CreateCicLoadMutex
+@ stdcall -stub TF_CreateCicLoadMutex(ptr)
@ stub TF_CreateDisplayAttributeMgr
@ stdcall TF_CreateInputProcessorProfiles(ptr)
@ stdcall TF_CreateLangBarItemMgr(ptr)
@ stdcall TF_CreateLangBarMgr(ptr)
@ stdcall TF_CreateThreadMgr(ptr)
@ stub TF_DllDetachInOther
-@ stub TF_GetGlobalCompartment
+@ stdcall -stub TF_GetGlobalCompartment(ptr)
@ stub TF_GetInputScope
@ stub TF_GetLangIcon
@ stub TF_GetMlngHKL
@@ -25,10 +25,12 @@
@ stdcall TF_GetThreadMgr(ptr)
@ stub TF_InatExtractIcon
@ stdcall TF_InitMlngInfo()
-@ stub TF_InitSystem
-@ stub TF_InvalidAssemblyListCache
+@ stdcall -stub TF_InitSystem()
+@ stdcall -stub TF_UninitSystem()
+@ stdcall -stub TF_InvalidAssemblyListCache()
@ stdcall TF_InvalidAssemblyListCacheIfExist()
@ stub TF_IsCtfmonRunning
@ stub TF_IsInMarshaling
@ stub TF_MlngInfoCount
@ stub TF_RunInputCPL
+@ stdcall -stub TF_PostAllThreadMsg(long long)
diff --git a/sdk/include/psdk/msctf.idl b/sdk/include/psdk/msctf.idl
index 5ef33119fd8..ea487273a5b 100644
--- a/sdk/include/psdk/msctf.idl
+++ b/sdk/include/psdk/msctf.idl
@@ -28,15 +28,21 @@ cpp_quote("#define TF_E_DISCONNECTED
MAKE_HRESULT(SEVERITY_ERROR, FACILITY_IT
cpp_quote("#define TF_E_ALREADY_EXISTS MAKE_HRESULT(SEVERITY_ERROR, FACILITY_ITF,
0x0506)")
cpp_quote("#define TF_E_NOLOCK MAKE_HRESULT(SEVERITY_ERROR, FACILITY_ITF,
0x0201)")
-cpp_quote("HRESULT WINAPI TF_CreateThreadMgr(ITfThreadMgr **pptim);")
-cpp_quote("HRESULT WINAPI TF_GetThreadMgr(ITfThreadMgr **pptim);")
-cpp_quote("HRESULT WINAPI TF_CreateInputProcessorProfiles(ITfInputProcessorProfiles
**ppipr);")
-cpp_quote("HRESULT WINAPI TF_CreateLangBarMgr(ITfLangBarMgr **pppbm);")
-cpp_quote("HRESULT WINAPI TF_CreateLangBarItemMgr(ITfLangBarItemMgr
**pplbim);")
-cpp_quote("HRESULT WINAPI TF_InvalidAssemblyListCacheIfExist(void);")
+cpp_quote("EXTERN_C HRESULT WINAPI TF_InitSystem(VOID);")
+cpp_quote("EXTERN_C HRESULT WINAPI TF_UninitSystem(VOID);")
+cpp_quote("EXTERN_C HRESULT WINAPI TF_GetGlobalCompartment(_Out_ ITfCompartmentMgr
**ppCompMgr);")
+cpp_quote("EXTERN_C HRESULT WINAPI TF_PostAllThreadMsg(DWORD dwUnknown1, DWORD
dwUnknown2);")
+cpp_quote("EXTERN_C HRESULT WINAPI TF_CreateThreadMgr(_Out_ ITfThreadMgr
**pptim);")
+cpp_quote("EXTERN_C HRESULT WINAPI TF_GetThreadMgr(_Out_ ITfThreadMgr
**pptim);")
+cpp_quote("EXTERN_C HRESULT WINAPI TF_CreateInputProcessorProfiles(_Out_
ITfInputProcessorProfiles **ppipr);")
+cpp_quote("EXTERN_C HRESULT WINAPI TF_CreateLangBarMgr(_Out_ ITfLangBarMgr
**pppbm);")
+cpp_quote("EXTERN_C HRESULT WINAPI TF_CreateLangBarItemMgr(_Out_ ITfLangBarItemMgr
**pplbim);")
+cpp_quote("EXTERN_C HANDLE WINAPI TF_CreateCicLoadMutex(_Out_ LPBOOL
pfWinLogon);")
+cpp_quote("EXTERN_C HRESULT WINAPI TF_InvalidAssemblyListCache(VOID);")
+cpp_quote("EXTERN_C HRESULT WINAPI TF_InvalidAssemblyListCacheIfExist(VOID);")
cpp_quote("EXTERN_C const GUID GUID_PROP_TEXTOWNER;")
-cpp_quote("DEFINE_GUID(GUID_PROP_ATTRIBUTE,0x34b45670,0x7526,0x11d2,0xa1,0x47,0x00,0x10,0x5a,0x27,0x99,0xb5);")
+cpp_quote("EXTERN_C const GUID GUID_PROP_ATTRIBUTE;")
cpp_quote("EXTERN_C const GUID GUID_PROP_LANGID;")
cpp_quote("EXTERN_C const GUID GUID_PROP_READING;")
cpp_quote("EXTERN_C const GUID GUID_PROP_COMPOSING;")
diff --git a/sdk/lib/uuid/CMakeLists.txt b/sdk/lib/uuid/CMakeLists.txt
index 9ebde406866..c988e1c9764 100644
--- a/sdk/lib/uuid/CMakeLists.txt
+++ b/sdk/lib/uuid/CMakeLists.txt
@@ -205,7 +205,7 @@ list(APPEND SOURCE
# hnclsid.c
ieguids.c
# iid.c
-# msctf_g.c
+ msctf_g.c
# ncclsid.c
# ndisguid.c
netfwv6clsid.c
diff --git a/sdk/lib/uuid/msctf_g.c b/sdk/lib/uuid/msctf_g.c
new file mode 100644
index 00000000000..59e36f2d496
--- /dev/null
+++ b/sdk/lib/uuid/msctf_g.c
@@ -0,0 +1,44 @@
+
+#include <initguid.h>
+
+DEFINE_GUID(GUID_COMPARTMENT_KEYBOARD_DISABLED, 0x71A5B253, 0x1951, 0x466B, 0x9F,
0xBC, 0x9C, 0x88, 0x08, 0xFA, 0x84, 0xF2);
+DEFINE_GUID(GUID_COMPARTMENT_KEYBOARD_OPENCLOSE, 0x58273AAD, 0x01BB, 0x4164, 0x95,
0xC6, 0x75, 0x5B, 0xA0, 0xB5, 0x16, 0x2D);
+DEFINE_GUID(GUID_COMPARTMENT_HANDWRITING_OPENCLOSE, 0xF9AE2C6B, 0x1866, 0x4361, 0xAF,
0x72, 0x7A, 0xA3, 0x09, 0x48, 0x89, 0x0E);
+DEFINE_GUID(GUID_COMPARTMENT_SPEECH_DISABLED, 0x56C5C607, 0x0703, 0x4E59, 0x8E,
0x52, 0xCB, 0xC8, 0x4E, 0x8B, 0xBE, 0x35);
+DEFINE_GUID(GUID_COMPARTMENT_SPEECH_OPENCLOSE, 0x544D6A63, 0xE2E8, 0x4752, 0xBB,
0xD1, 0x00, 0x09, 0x60, 0xBC, 0xA0, 0x83);
+DEFINE_GUID(GUID_COMPARTMENT_SPEECH_GLOBALSTATE, 0x2A54FE8E, 0x0D08, 0x460C, 0xA7,
0x5D, 0x87, 0x03, 0x5F, 0xF4, 0x36, 0xC5);
+DEFINE_GUID(GUID_COMPARTMENT_PERSISTMENUENABLED, 0x575F3783, 0x70C8, 0x47C8, 0xAE,
0x5D, 0x91, 0xA0, 0x1A, 0x1F, 0x75, 0x92);
+DEFINE_GUID(GUID_COMPARTMENT_EMPTYCONTEXT, 0xD7487DBF, 0x804E, 0x41C5, 0x89,
0x4D, 0xAD, 0x96, 0xFD, 0x4E, 0xEA, 0x13);
+DEFINE_GUID(GUID_COMPARTMENT_TIPUISTATUS, 0x148CA3EC, 0x0366, 0x401C, 0x8D,
0x75, 0xED, 0x97, 0x8D, 0x85, 0xFB, 0xC9);
+
+DEFINE_GUID(GUID_PROP_TEXTOWNER, 0xF1E2D520, 0x0969, 0x11D3, 0x8D,
0xF0, 0x00, 0x10, 0x5A, 0x27, 0x99, 0xB5);
+DEFINE_GUID(GUID_PROP_ATTRIBUTE, 0x34B45670, 0x7526, 0x11D2, 0xA1,
0x47, 0x00, 0x10, 0x5A, 0x27, 0x99, 0xB5);
+DEFINE_GUID(GUID_PROP_LANGID, 0x3280CE20, 0x8032, 0x11D2, 0xB6,
0x03, 0x00, 0x10, 0x5A, 0x27, 0x99, 0xB5);
+DEFINE_GUID(GUID_PROP_READING, 0x5463F7C0, 0x8E31, 0x11D2, 0xBF,
0x46, 0x00, 0x10, 0x5A, 0x27, 0x99, 0xB5);
+DEFINE_GUID(GUID_PROP_COMPOSING, 0xE12AC060, 0xAF15, 0x11D2, 0xAF,
0xC5, 0x00, 0x10, 0x5A, 0x27, 0x99, 0xB5);
+
+DEFINE_GUID(GUID_TFCAT_TIP_KEYBOARD, 0x34745C63, 0xB2F0, 0x4784, 0x8B,
0x67, 0x5E, 0x12, 0xC8, 0x70, 0x1A, 0x31);
+DEFINE_GUID(GUID_TFCAT_TIP_SPEECH, 0xB5A73CD1, 0x8355, 0x426B, 0xA1,
0x61, 0x25, 0x98, 0x08, 0xF2, 0x6B, 0x14);
+DEFINE_GUID(GUID_TFCAT_TIP_HANDWRITING, 0x246ECB87, 0xC2F2, 0x4ABE, 0x90,
0x5B, 0xC8, 0xB3, 0x8A, 0xDD, 0x2C, 0x43);
+DEFINE_GUID(GUID_TFCAT_DISPLAYATTRIBUTEPROVIDER, 0x046B8C80, 0x1647, 0x40F7, 0x9B,
0x21, 0xB9, 0x3B, 0x81, 0xAA, 0xBC, 0x1B);
+
+DEFINE_GUID(CLSID_TF_ThreadMgr, 0x529A9E6B, 0x6587, 0x4F23, 0xAB,
0x9E, 0x9C, 0x7D, 0x68, 0x3E, 0x3C, 0x50);
+DEFINE_GUID(CLSID_TF_InputProcessorProfiles, 0x33C53A50, 0xF456, 0x4884, 0xB0,
0x49, 0x85, 0xFD, 0x64, 0x3E, 0xCF, 0xED);
+DEFINE_GUID(CLSID_TF_LangBarMgr, 0xEBB08C45, 0x6C4A, 0x4FDC, 0xAE,
0x53, 0x4E, 0xB8, 0xC4, 0xC7, 0xDB, 0x8E);
+DEFINE_GUID(CLSID_TF_CategoryMgr, 0xA4B544A1, 0x438D, 0x4B41, 0x93,
0x25, 0x86, 0x95, 0x23, 0xE2, 0xD6, 0xC7);
+DEFINE_GUID(CLSID_TF_DisplayAttributeMgr, 0x3CE74DE4, 0x53D3, 0x4D74, 0x8B,
0x83, 0x43, 0x1B, 0x38, 0x28, 0xBA, 0x53);
+
+DEFINE_GUID(IID_IEnumTfContexts, 0x8F1A7EA6, 0x1654, 0x4502, 0xA8,
0x6E, 0xB2, 0x90, 0x23, 0x44, 0xD5, 0x07);
+DEFINE_GUID(IID_IEnumTfDocumentMgrs, 0xAA80E808, 0x2021, 0x11D2, 0x93,
0xE0, 0x00, 0x60, 0xB0, 0x67, 0xB8, 0x6E);
+DEFINE_GUID(IID_IEnumTfLanguageProfiles, 0x3D61BF11, 0xAC5F, 0x42C8, 0xA4,
0xCB, 0x93, 0x1B, 0xCC, 0x28, 0xC7, 0x44);
+DEFINE_GUID(IID_ITfCompartmentMgr, 0x7DCF57AC, 0x18AD, 0x438B, 0x82,
0x4D, 0x97, 0x9B, 0xFF, 0xB7, 0x4B, 0x7C);
+DEFINE_GUID(IID_ITfCompositionView, 0xD7540241, 0xF9A1, 0x4364, 0xBE,
0xFC, 0xDB, 0xCD, 0x2C, 0x43, 0x95, 0xB7);
+DEFINE_GUID(IID_ITfContext, 0xAA80E7FD, 0x2021, 0x11D2, 0x93,
0xE0, 0x00, 0x60, 0xB0, 0x67, 0xB8, 0x6E);
+DEFINE_GUID(IID_ITfDocumentMgr, 0xAA80E7F4, 0x2021, 0x11D2, 0x93,
0xE0, 0x00, 0x60, 0xB0, 0x67, 0xB8, 0x6E);
+DEFINE_GUID(IID_ITfEditSession, 0xAA80E803, 0x2021, 0x11D2, 0x93,
0xE0, 0x00, 0x60, 0xB0, 0x67, 0xB8, 0x6E);
+DEFINE_GUID(IID_ITfKeyEventSink, 0xAA80E7F5, 0x2021, 0x11D2, 0x93,
0xE0, 0x00, 0x60, 0xB0, 0x67, 0xB8, 0x6E);
+DEFINE_GUID(IID_ITfPersistentPropertyLoaderACP, 0x4EF89150, 0x0807, 0x11D3, 0x8D,
0xF0, 0x00, 0x10, 0x5A, 0x27, 0x99, 0xB5);
+DEFINE_GUID(IID_ITfProperty, 0xE2449660, 0x9542, 0x11D2, 0xBF,
0x46, 0x00, 0x10, 0x5A, 0x27, 0x99, 0xB5);
+DEFINE_GUID(IID_ITfRange, 0xAA80E7FF, 0x2021, 0x11D2, 0x93,
0xE0, 0x00, 0x60, 0xB0, 0x67, 0xB8, 0x6E);
+DEFINE_GUID(IID_ITfRangeACP, 0x057A6296, 0x029B, 0x4154, 0xB7,
0x9A, 0x0D, 0x46, 0x1D, 0x4E, 0xA9, 0x4C);
+DEFINE_GUID(IID_ITfReadOnlyProperty, 0x17D49A3D, 0xF8B8, 0x4B2F, 0xB2,
0x54, 0x52, 0x31, 0x9D, 0xD6, 0x4C, 0x53);