File tree Expand file tree Collapse file tree 1 file changed +7
-4
lines changed Expand file tree Collapse file tree 1 file changed +7
-4
lines changed Original file line number Diff line number Diff line change @@ -15,6 +15,7 @@ CandidateList::CandidateList(WeaselTSF * pTextService)
15
15
_cRef = 1 ;
16
16
_tsf = pTextService;
17
17
_tsf->AddRef ();
18
+
18
19
}
19
20
20
21
CandidateList::~CandidateList ()
@@ -303,8 +304,9 @@ HWND CandidateList::_GetActiveWnd()
303
304
void CandidateList::_StartUI ()
304
305
{
305
306
BOOL pbShow = TRUE ;
306
- ComPtr<ITfUIElementMgr> emgr;
307
- _tsf->_pThreadMgr ->QueryInterface (emgr.GetAddressOf ());
307
+ ComPtr<ITfThreadMgr> pThreadMgr;
308
+ pThreadMgr.Copy (_tsf->_pThreadMgr );
309
+ ComPtr<ITfUIElementMgr> emgr = pThreadMgr.As <ITfUIElementMgr>();
308
310
309
311
if (emgr) {
310
312
if (!_ui->IsShown ())
@@ -317,8 +319,9 @@ void CandidateList::_StartUI()
317
319
318
320
void CandidateList::_EndUI ()
319
321
{
320
- ComPtr<ITfUIElementMgr> emgr;
321
- _tsf->_pThreadMgr ->QueryInterface (emgr.GetAddressOf ());
322
+ ComPtr<ITfThreadMgr> pThreadMgr;
323
+ pThreadMgr.Copy (_tsf->_pThreadMgr );
324
+ ComPtr<ITfUIElementMgr> emgr = pThreadMgr.As <ITfUIElementMgr>();
322
325
if (emgr)
323
326
emgr->EndUIElement (uiid);
324
327
if (_ui->IsShown ())
You can’t perform that action at this time.
0 commit comments