NVDA Helper
In-process and lite high-speed utilities for NVDA
tsf.cpp File Reference
#include <map>
#include <algorithm>
#include <windows.h>
#include <wchar.h>
#include <msctf.h>
#include <common/log.h>
#include <common/lock.h>
#include "nvdaHelperRemote.h"
#include <remote/nvdaControllerInternal.h>
#include "typedCharacter.h"
#include "ime.h"
#include "tsf.h"
#include "inputLangChange.h"

Go to the source code of this file.

Classes

class  TsfSink
 

Typedefs

typedef map< DWORD, TsfSink * > sinkMap_t
 
typedef HRESULT(WINAPI * TF_GetThreadMgr_t) (ITfThreadMgr **)
 
typedef HRESULT(WINAPI * TF_CreateThreadMgr_t) (ITfThreadMgr **)
 
typedef HRESULT(WINAPI * TF_CreateInputProcessorProfiles_t) (ITfInputProcessorProfiles **)
 

Functions

bool fetchRangeExtent (ITfRange *pRange, long *start, ULONG *length)
 
ITfThreadMgr * create_thread_manager ()
 
ITfInputProcessorProfiles * create_input_processor_profiles ()
 
 STDMETHODIMP_ (ULONG) TsfSink
 
static void CALLBACK TSF_winEventHook (HWINEVENTHOOK hookID, DWORD eventID, HWND hwnd, long objectID, long childID, DWORD threadID, DWORD time)
 
TsfSinkfetchCurrentTsfSink ()
 
void TSF_inProcess_initialize ()
 
void TSF_inProcess_terminate ()
 
void TSF_thread_detached ()
 
bool isTSFThread ()
 

Variables

CLSID curTSFClsID ={0, 0, 0, {0, 0, 0, 0, 0, 0, 0, 0}}
 
static DWORD gTsfIndex = TLS_OUT_OF_INDEXES
 
static sinkMap_t gTsfSinks
 
static LockableObject gTsfSinksLock
 
static PVOID gLastCompStr = NULL
 

Typedef Documentation

◆ sinkMap_t

typedef map<DWORD,TsfSink*> sinkMap_t

◆ TF_GetThreadMgr_t

typedef HRESULT(WINAPI * TF_GetThreadMgr_t) (ITfThreadMgr **)

◆ TF_CreateThreadMgr_t

typedef HRESULT(WINAPI * TF_CreateThreadMgr_t) (ITfThreadMgr **)

◆ TF_CreateInputProcessorProfiles_t

typedef HRESULT(WINAPI * TF_CreateInputProcessorProfiles_t) (ITfInputProcessorProfiles **)

Function Documentation

◆ fetchRangeExtent()

bool fetchRangeExtent ( ITfRange * pRange,
long * start,
ULONG * length )

References HRESULT().

Referenced by TsfSink::OnEndEdit().

◆ create_thread_manager()

ITfThreadMgr * create_thread_manager ( )

Referenced by TsfSink::Initialize().

◆ create_input_processor_profiles()

ITfInputProcessorProfiles * create_input_processor_profiles ( )

◆ STDMETHODIMP_()

STDMETHODIMP_ ( ULONG )

◆ TSF_winEventHook()

static void CALLBACK TSF_winEventHook ( HWINEVENTHOOK hookID,
DWORD eventID,
HWND hwnd,
long objectID,
long childID,
DWORD threadID,
DWORD time )
static

◆ fetchCurrentTsfSink()

TsfSink * fetchCurrentTsfSink ( )

References gTsfIndex.

Referenced by isTSFThread(), and TSF_thread_detached().

◆ TSF_inProcess_initialize()

void TSF_inProcess_initialize ( )

◆ TSF_inProcess_terminate()

◆ TSF_thread_detached()

◆ isTSFThread()

Variable Documentation

◆ curTSFClsID

CLSID curTSFClsID ={0, 0, 0, {0, 0, 0, 0, 0, 0, 0, 0}}

◆ gTsfIndex

◆ gTsfSinks

◆ gTsfSinksLock

◆ gLastCompStr

PVOID gLastCompStr = NULL
static