https://git.reactos.org/?p=reactos.git;a=commitdiff;h=e6cb6d257a6f6d9c4aa28…
commit e6cb6d257a6f6d9c4aa283419525ddc039edde96
Author: Katayama Hirofumi MZ <katayama.hirofumi.mz(a)gmail.com>
AuthorDate: Thu Dec 21 11:04:02 2023 +0900
Commit: Katayama Hirofumi MZ <katayama.hirofumi.mz(a)gmail.com>
CommitDate: Thu Dec 21 11:04:02 2023 +0900
[MSCTFIME] Implement CicInputContext::GetGuidAtom
CORE-19360
---
dll/ime/msctfime/msctfime.cpp | 38 ++++++++++++++++++++++++++++++++------
1 file changed, 32 insertions(+), 6 deletions(-)
diff --git a/dll/ime/msctfime/msctfime.cpp b/dll/ime/msctfime/msctfime.cpp
index f5f2e592ea4..c63aab280f3 100644
--- a/dll/ime/msctfime/msctfime.cpp
+++ b/dll/ime/msctfime/msctfime.cpp
@@ -503,10 +503,32 @@ HRESULT CCompartmentEventSink::_Unadvise()
* CicInputContext
*/
+class CInputContextOwnerCallBack;
+
/* FIXME */
class CicInputContext : public ITfContextOwnerCompositionSink
{
+ DWORD m_dw[2];
LONG m_cRefs;
+ HIMC m_hIMC;
+ ITfDocumentMgr *m_pDocumentMgr;
+ ITfContext *m_pContext;
+ DWORD m_dw0_0[1];
+ CInputContextOwnerCallBack *m_pICOwnerCallback;
+ DWORD m_dw0;
+ CCompartmentEventSink *m_pCompEventSink1;
+ CCompartmentEventSink *m_pCompEventSink2;
+ DWORD m_dw0_5[4];
+ DWORD m_dw1[2];
+ DWORD m_dwQueryPos;
+ DWORD m_dw1_5[1];
+ GUID m_guid;
+ DWORD m_dw2[19];
+ WORD m_cGuidAtoms;
+ WORD m_padding;
+ DWORD m_adwGuidAtoms[256];
+ DWORD m_dw3[19];
+
public:
CicInputContext()
{
@@ -529,7 +551,7 @@ public:
HRESULT
GetGuidAtom(
_Inout_ IMCLock& imcLock,
- _In_ DWORD dwUnknown,
+ _In_ BYTE iAtom,
_Out_opt_ LPDWORD pdwGuidAtom);
HRESULT DestroyInputContext();
@@ -612,24 +634,28 @@ CicInputContext::OnEndComposition(
}
/**
- * @unimplemented
+ * @implemented
*/
HRESULT
CicInputContext::GetGuidAtom(
_Inout_ IMCLock& imcLock,
- _In_ DWORD dwUnknown,
+ _In_ BYTE iAtom,
_Out_opt_ LPDWORD pdwGuidAtom)
{
IMCCLock<CTFIMECONTEXT> imeContext(imcLock.get().hCompStr);
-
HRESULT hr = imeContext.m_hr;
if (!imeContext)
hr = E_FAIL;
-
if (FAILED(hr))
return hr;
- // FIXME
+ hr = E_FAIL;
+ if (iAtom < m_cGuidAtoms)
+ {
+ *pdwGuidAtom = m_adwGuidAtoms[iAtom];
+ hr = S_OK;
+ }
+
return hr;
}