void CTextService::_EndComposition(ITfContext *pContext) { CEndCompositionEditSession *pEditSession; HRESULT hr; if (pEditSession = new CEndCompositionEditSession(this, pContext)) { pContext->RequestEditSession(_tfClientId, pEditSession, TF_ES_ASYNCDONTCARE | TF_ES_READWRITE, &hr); pEditSession->Release(); } }
void WeaselTSF::_EndComposition(ITfContext *pContext) { CEndCompositionEditSession *pEditSession; HRESULT hr; if ((pEditSession = new CEndCompositionEditSession(this, pContext, _pComposition)) != NULL) { pContext->RequestEditSession(_tfClientId, pEditSession, TF_ES_SYNC | TF_ES_READWRITE, &hr); pEditSession->Release(); } }
void CSampleIME::_EndComposition(_In_opt_ ITfContext *pContext) { CEndCompositionEditSession *pEditSession = new (std::nothrow) CEndCompositionEditSession(this, pContext); HRESULT hr = S_OK; if (nullptr != pEditSession) { pContext->RequestEditSession(_tfClientId, pEditSession, TF_ES_ASYNCDONTCARE | TF_ES_READWRITE, &hr); pEditSession->Release(); } }