Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

849 lines
25 KiB

  1. //
  2. // mproxy.cpp
  3. //
  4. #include "private.h"
  5. #include "mproxy.h"
  6. #include "ithdmshl.h"
  7. /* 344E266C-FB48-4E81-9FD9-0CC8070F984A */
  8. const IID IID_CPROXYPRIV = {
  9. 0x344E266C,
  10. 0xFB48,
  11. 0x4E81,
  12. {0x9F, 0xD9, 0x0C, 0xC8, 0x07, 0x0F, 0x98, 0x4A}
  13. };
  14. DBG_ID_INSTANCE(CProxyIUnknown);
  15. DBG_ID_INSTANCE(CProxyITfLangBarMgr);
  16. DBG_ID_INSTANCE(CProxyITfLangBarItemMgr);
  17. DBG_ID_INSTANCE(CProxyITfLangBarItemSink);
  18. DBG_ID_INSTANCE(CProxyIEnumTfLangBarItems);
  19. DBG_ID_INSTANCE(CProxyITfLangBarItem);
  20. DBG_ID_INSTANCE(CProxyITfLangBarItemButton);
  21. DBG_ID_INSTANCE(CProxyITfLangBarItemBitmapButton);
  22. DBG_ID_INSTANCE(CProxyITfLangBarItemBitmap);
  23. DBG_ID_INSTANCE(CProxyITfLangBarItemBalloon);
  24. DBG_ID_INSTANCE(CProxyITfMenu);
  25. DBG_ID_INSTANCE(CProxyITfInputProcessorProfiles);
  26. //////////////////////////////////////////////////////////////////////////////
  27. //
  28. // ProxyCreator
  29. //
  30. //////////////////////////////////////////////////////////////////////////////
  31. #define CREATENEWPROXY(interface_name) \
  32. if (IsEqualIID(riid, IID_ ## interface_name ## )) \
  33. { \
  34. CProxy ## interface_name ## *pProxy = new CProxy ## interface_name ## (psfn);\
  35. if (!pProxy) \
  36. return NULL; \
  37. pProxy->Init(riid, 0, ulStubId, dwStubTime, dwThreadId, dwCurThreadId, dwCurProcessId); \
  38. return SAFECAST(pProxy, ## interface_name ## *); \
  39. }
  40. IUnknown *ProxyCreator(SYSTHREAD *psfn, REFIID riid, ULONG ulStubId, DWORD dwStubTime, DWORD dwThreadId, DWORD dwCurThreadId, DWORD dwCurProcessId)
  41. {
  42. CREATENEWPROXY(IUnknown)
  43. CREATENEWPROXY(ITfLangBarMgr)
  44. CREATENEWPROXY(ITfLangBarItemMgr)
  45. CREATENEWPROXY(ITfLangBarItemSink)
  46. CREATENEWPROXY(IEnumTfLangBarItems)
  47. CREATENEWPROXY(ITfLangBarItem)
  48. CREATENEWPROXY(ITfLangBarItemButton)
  49. CREATENEWPROXY(ITfLangBarItemBitmapButton)
  50. CREATENEWPROXY(ITfLangBarItemBitmap)
  51. CREATENEWPROXY(ITfLangBarItemBalloon)
  52. CREATENEWPROXY(ITfMenu)
  53. CREATENEWPROXY(ITfInputProcessorProfiles);
  54. return NULL;
  55. }
  56. //////////////////////////////////////////////////////////////////////////////
  57. //
  58. // CProxyIUnknown
  59. //
  60. //////////////////////////////////////////////////////////////////////////////
  61. CProxyIUnknown::CProxyIUnknown(SYSTHREAD *psfn) : CProxy(psfn)
  62. {
  63. Dbg_MemSetThisNameID(TEXT("CProxyIUnknown"));
  64. }
  65. HRESULT CProxyIUnknown::QueryInterface(REFIID riid, void **ppvObj)
  66. {
  67. TraceMsg(TF_FUNC, "CProxyIUnknown::QueryInterface");
  68. if (IsEqualIID(riid, IID_CPROXYPRIV))
  69. {
  70. *ppvObj = SAFECAST(this, CProxyIUnknown *);
  71. InternalAddRef();
  72. return S_OK;
  73. }
  74. HRESULT hr = _QueryInterface(riid, ppvObj);
  75. // if (SUCCEEDED(hr))
  76. // InternalAddRef();
  77. return hr;
  78. }
  79. HRESULT CProxyIUnknown::_QueryInterface(REFIID riid, void **ppvObj)
  80. {
  81. CPROXY_PARAM_START()
  82. CPROXY_PARAM_POINTER_IN(&riid)
  83. CPROXY_PARAM_INTERFACE_OUT(ppvObj, riid)
  84. CPROXY_PARAM_CALL(0)
  85. }
  86. STDAPI_(ULONG) CProxyIUnknown::AddRef()
  87. {
  88. #ifdef UNKNOWN_MARSHAL
  89. HRESULT hr;
  90. TraceMsg(TF_FUNC, "CProxyIUnknown::AddRef");
  91. CMarshalParamCreator cparam;
  92. cparam.Init(_iid, 1, 0);
  93. hr = cparam.SendReceiveULONG(this);
  94. if (FAILED(hr))
  95. return hr;
  96. #endif
  97. return InternalAddRef();
  98. }
  99. STDAPI_(ULONG) CProxyIUnknown::Release()
  100. {
  101. #ifdef UNKNOWN_MARSHAL
  102. HRESULT hr;
  103. TraceMsg(TF_FUNC, "CProxyIUnknown::Release");
  104. CMarshalParamCreator cparam;
  105. cparam.Init(_iid, 2, 0);
  106. hr = cparam.SendReceiveULONG(this);
  107. if (FAILED(hr))
  108. return hr;
  109. #endif
  110. return InternalRelease();
  111. }
  112. //////////////////////////////////////////////////////////////////////////////
  113. //
  114. // CProxyITfLangBarMgr
  115. //
  116. //////////////////////////////////////////////////////////////////////////////
  117. CProxyITfLangBarMgr::CProxyITfLangBarMgr(SYSTHREAD *psfn) : CProxyIUnknown(psfn)
  118. {
  119. Dbg_MemSetThisNameID(TEXT("CProxyITfLangBarMgr"));
  120. }
  121. STDAPI CProxyITfLangBarMgr::AdviseEventSink(ITfLangBarEventSink *pSink,
  122. HWND hwnd,
  123. DWORD dwFlags,
  124. DWORD *pdwCookie)
  125. {
  126. Assert(0);
  127. return E_NOTIMPL;
  128. }
  129. STDAPI CProxyITfLangBarMgr::UnadviseEventSink(DWORD dwCookie)
  130. {
  131. Assert(0);
  132. return E_NOTIMPL;
  133. }
  134. STDAPI CProxyITfLangBarMgr::GetThreadMarshalInterface(DWORD dwThreadId,
  135. DWORD dwType,
  136. REFIID riid,
  137. IUnknown **ppunk)
  138. {
  139. Assert(0);
  140. return E_NOTIMPL;
  141. }
  142. STDAPI CProxyITfLangBarMgr::GetThreadLangBarItemMgr(DWORD dwThreadId,
  143. ITfLangBarItemMgr **pplbi,
  144. DWORD *pdwThreadId)
  145. {
  146. Assert(0);
  147. return E_NOTIMPL;
  148. }
  149. STDAPI CProxyITfLangBarMgr::GetInputProcessorProfiles(DWORD dwThreadId,
  150. ITfInputProcessorProfiles **ppaip,
  151. DWORD *pdwThreadId)
  152. {
  153. Assert(0);
  154. return E_NOTIMPL;
  155. }
  156. STDAPI CProxyITfLangBarMgr::RestoreLastFocus(DWORD *pdwThreadId, BOOL fPrev)
  157. {
  158. Assert(0);
  159. return E_NOTIMPL;
  160. }
  161. STDAPI CProxyITfLangBarMgr::SetModalInput(ITfLangBarEventSink *pSink,
  162. DWORD dwThreadId,
  163. DWORD dwFlags)
  164. {
  165. Assert(0);
  166. return E_NOTIMPL;
  167. }
  168. STDAPI CProxyITfLangBarMgr::ShowFloating(DWORD dwFlags)
  169. {
  170. Assert(0);
  171. return E_NOTIMPL;
  172. }
  173. STDAPI CProxyITfLangBarMgr::GetShowFloatingStatus(DWORD *pdwFlags)
  174. {
  175. Assert(0);
  176. return E_NOTIMPL;
  177. }
  178. //////////////////////////////////////////////////////////////////////////////
  179. //
  180. // CProxyITfLangBarItemMgr
  181. //
  182. //////////////////////////////////////////////////////////////////////////////
  183. CProxyITfLangBarItemMgr::CProxyITfLangBarItemMgr(SYSTHREAD *psfn) : CProxyIUnknown(psfn)
  184. {
  185. Dbg_MemSetThisNameID(TEXT("CProxyITfLangBarItemMgr"));
  186. }
  187. STDMETHODIMP CProxyITfLangBarItemMgr::EnumItems(IEnumTfLangBarItems **ppEnum)
  188. {
  189. TraceMsg(TF_FUNC, "CProxyITfLangbarItemMgr::EnumItems");
  190. CPROXY_PARAM_START()
  191. CPROXY_PARAM_INTERFACE_OUT(ppEnum, IID_IEnumTfLangBarItems)
  192. CPROXY_PARAM_CALL(3)
  193. }
  194. STDMETHODIMP CProxyITfLangBarItemMgr::GetItem(REFGUID rguid, ITfLangBarItem **ppItem)
  195. {
  196. #if 1
  197. Assert(0);
  198. return E_NOTIMPL;
  199. #else
  200. TraceMsg(TF_FUNC, "CProxyITfLangbarItemMgr::GetItem");
  201. CPROXY_PARAM_START()
  202. CPROXY_PARAM_POINTER_IN(&rguid)
  203. CPROXY_PARAM_INTERFACE_OUT(ppItem, IID_ITfLangBarItem)
  204. CPROXY_PARAM_CALL(4)
  205. #endif
  206. }
  207. STDMETHODIMP CProxyITfLangBarItemMgr::AddItem(ITfLangBarItem *punk)
  208. {
  209. #if 1
  210. Assert(0);
  211. return E_NOTIMPL;
  212. #else
  213. TraceMsg(TF_FUNC, "CProxyITfLangbarItemMgr::AddItem");
  214. CPROXY_PARAM_START()
  215. CPROXY_PARAM_INTERFACE_IN(&punk, IID_ITfLangBarItem)
  216. CPROXY_PARAM_CALL(5)
  217. #endif
  218. }
  219. STDMETHODIMP CProxyITfLangBarItemMgr::RemoveItem(ITfLangBarItem *punk)
  220. {
  221. #if 1
  222. Assert(0);
  223. return E_NOTIMPL;
  224. #else
  225. TraceMsg(TF_FUNC, "CProxyITfLangbarItemMgr::RemoveItem");
  226. CPROXY_PARAM_START()
  227. CPROXY_PARAM_INTERFACE_IN(&punk, IID_ITfLangBarItem)
  228. CPROXY_PARAM_CALL(6)
  229. #endif
  230. }
  231. STDMETHODIMP CProxyITfLangBarItemMgr::AdviseItemSink(ITfLangBarItemSink *punk, DWORD *pdwCookie, REFGUID rguidItem)
  232. {
  233. TraceMsg(TF_FUNC, "CProxyITfLangbarItemMgr::AdviseItemSink");
  234. CPROXY_PARAM_START()
  235. CPROXY_PARAM_INTERFACE_IN(&punk, IID_ITfLangBarItemSink)
  236. CPROXY_PARAM_POINTER_OUT(pdwCookie)
  237. CPROXY_PARAM_POINTER_IN(&rguidItem)
  238. CPROXY_PARAM_CALL(7)
  239. }
  240. STDMETHODIMP CProxyITfLangBarItemMgr::UnadviseItemSink(DWORD dwCookie)
  241. {
  242. TraceMsg(TF_FUNC, "CProxyITfLangbarItemMgr::UnadviseItemSink");
  243. CPROXY_PARAM_START()
  244. CPROXY_PARAM_ULONG_IN(dwCookie)
  245. CPROXY_PARAM_CALL(8)
  246. }
  247. STDMETHODIMP CProxyITfLangBarItemMgr::GetItemFloatingRect(DWORD dwThreadId, REFGUID rguid, RECT *prc)
  248. {
  249. TraceMsg(TF_FUNC, "CProxyITfLangbarItemMgr::GetItemFloatingRect");
  250. CPROXY_PARAM_START()
  251. CPROXY_PARAM_ULONG_IN(dwThreadId)
  252. CPROXY_PARAM_POINTER_IN(&rguid)
  253. CPROXY_PARAM_POINTER_OUT(prc)
  254. CPROXY_PARAM_CALL(9)
  255. }
  256. STDMETHODIMP CProxyITfLangBarItemMgr::GetItemsStatus(ULONG ulCount, const GUID *prgguid, DWORD *pdwStatus)
  257. {
  258. TraceMsg(TF_FUNC, "CProxyITfLangbarItemMgr::GetItemsStatus");
  259. CPROXY_PARAM_START()
  260. CPROXY_PARAM_ULONG_IN(ulCount)
  261. CPROXY_PARAM_POINTER_ARRAY_IN(prgguid, ulCount)
  262. CPROXY_PARAM_POINTER_ARRAY_OUT(pdwStatus, ulCount)
  263. CPROXY_PARAM_CALL(10)
  264. }
  265. STDMETHODIMP CProxyITfLangBarItemMgr::GetItemNum(ULONG *pulCount)
  266. {
  267. TraceMsg(TF_FUNC, "CProxyITfLangbarItemMgr::GetItemNum");
  268. CPROXY_PARAM_START()
  269. CPROXY_PARAM_POINTER_OUT(pulCount)
  270. CPROXY_PARAM_CALL(11)
  271. }
  272. STDMETHODIMP CProxyITfLangBarItemMgr::GetItems(ULONG ulCount, ITfLangBarItem **ppItem, TF_LANGBARITEMINFO *pInfo, DWORD *pdwStatus, ULONG *pcFetched)
  273. {
  274. TraceMsg(TF_FUNC, "CProxyITfLangbarItemMgr::GetItems");
  275. CPROXY_PARAM_START()
  276. CPROXY_PARAM_ULONG_IN(ulCount)
  277. CPROXY_PARAM_INTERFACE_ARRAY_OUT(ppItem, IID_ITfLangBarItem, ulCount)
  278. CPROXY_PARAM_POINTER_ARRAY_OUT(pInfo, ulCount)
  279. CPROXY_PARAM_POINTER_ARRAY_OUT(pdwStatus, ulCount)
  280. CPROXY_PARAM_POINTER_OUT(pcFetched)
  281. CPROXY_PARAM_CALL(12)
  282. }
  283. STDMETHODIMP CProxyITfLangBarItemMgr::AdviseItemsSink(ULONG ulCount, ITfLangBarItemSink **ppunk, const GUID *pguidItem, DWORD *pdwCookie)
  284. {
  285. TraceMsg(TF_FUNC, "CProxyITfLangbarItemMgr::AdviseItemsSink");
  286. CPROXY_PARAM_START()
  287. CPROXY_PARAM_ULONG_IN(ulCount)
  288. CPROXY_PARAM_INTERFACE_ARRAY_IN(ppunk, IID_ITfLangBarItemSink, ulCount)
  289. CPROXY_PARAM_POINTER_ARRAY_IN(pguidItem, ulCount)
  290. CPROXY_PARAM_POINTER_ARRAY_OUT(pdwCookie, ulCount)
  291. CPROXY_PARAM_CALL(13)
  292. }
  293. STDMETHODIMP CProxyITfLangBarItemMgr::UnadviseItemsSink(ULONG ulCount, DWORD *pdwCookie)
  294. {
  295. TraceMsg(TF_FUNC, "CProxyITfLangbarItemMgr::AdviseItemsSink");
  296. CPROXY_PARAM_START()
  297. CPROXY_PARAM_ULONG_IN(ulCount)
  298. CPROXY_PARAM_POINTER_ARRAY_IN(pdwCookie, ulCount)
  299. CPROXY_PARAM_CALL(14)
  300. }
  301. //////////////////////////////////////////////////////////////////////////////
  302. //
  303. // CProxyITfLangBarItemSink
  304. //
  305. //////////////////////////////////////////////////////////////////////////////
  306. CProxyITfLangBarItemSink::CProxyITfLangBarItemSink(SYSTHREAD *psfn) : CProxyIUnknown(psfn)
  307. {
  308. Dbg_MemSetThisNameID(TEXT("CProxyITfLangBarItemSink"));
  309. }
  310. HRESULT CProxyITfLangBarItemSink::OnUpdate(DWORD dwFlags)
  311. {
  312. TraceMsg(TF_FUNC, "CProxyITfLangBarItemSink:OnUpdate");
  313. CPROXY_PARAM_START()
  314. CPROXY_PARAM_ULONG_IN(dwFlags)
  315. CPROXY_PARAM_CALL(3)
  316. }
  317. //////////////////////////////////////////////////////////////////////////////
  318. //
  319. // CProxyIEnumTfLangBarItems
  320. //
  321. //////////////////////////////////////////////////////////////////////////////
  322. CProxyIEnumTfLangBarItems::CProxyIEnumTfLangBarItems(SYSTHREAD *psfn) : CProxyIUnknown(psfn)
  323. {
  324. Dbg_MemSetThisNameID(TEXT("CProxyIEnumTfLangBarItems"));
  325. }
  326. HRESULT CProxyIEnumTfLangBarItems::Clone(IEnumTfLangBarItems **ppEnum)
  327. {
  328. TraceMsg(TF_FUNC, "CProxyIEnumTfLangBarItems:Clone");
  329. CPROXY_PARAM_START()
  330. CPROXY_PARAM_INTERFACE_OUT(ppEnum, IID_IEnumTfLangBarItems)
  331. CPROXY_PARAM_CALL(3)
  332. }
  333. HRESULT CProxyIEnumTfLangBarItems::Next(ULONG ulCount,
  334. ITfLangBarItem **ppItem,
  335. ULONG *pcFetched)
  336. {
  337. TraceMsg(TF_FUNC, "CProxyIEnumTfLangBarItems:Next");
  338. CPROXY_PARAM_START()
  339. CPROXY_PARAM_ULONG_IN(ulCount)
  340. CPROXY_PARAM_INTERFACE_ARRAY_OUT(ppItem, IID_ITfLangBarItem, ulCount)
  341. CPROXY_PARAM_POINTER_OUT(pcFetched)
  342. CPROXY_PARAM_CALL(4)
  343. }
  344. HRESULT CProxyIEnumTfLangBarItems::Reset()
  345. {
  346. TraceMsg(TF_FUNC, "CProxyIEnumTfLangBarItems:Reset");
  347. CPROXY_PARAM_CALL_NOPARAM(5)
  348. }
  349. HRESULT CProxyIEnumTfLangBarItems::Skip(ULONG ulCount)
  350. {
  351. TraceMsg(TF_FUNC, "CProxyIEnumTfLangBarItems:Skip");
  352. CPROXY_PARAM_START()
  353. CPROXY_PARAM_ULONG_IN(ulCount)
  354. CPROXY_PARAM_CALL(6)
  355. }
  356. //////////////////////////////////////////////////////////////////////////////
  357. //
  358. // CProxyITfLangBarItem
  359. //
  360. //////////////////////////////////////////////////////////////////////////////
  361. CProxyITfLangBarItem::CProxyITfLangBarItem(SYSTHREAD *psfn) : CProxyIUnknown(psfn)
  362. {
  363. Dbg_MemSetThisNameID(TEXT("CProxyITfLangBarItem"));
  364. }
  365. HRESULT CProxyITfLangBarItem::GetInfo(TF_LANGBARITEMINFO *pInfo)
  366. {
  367. TraceMsg(TF_FUNC, "CProxyITfLangBarItem::GetInfo");
  368. CPROXY_PARAM_START()
  369. CPROXY_PARAM_POINTER_OUT(pInfo)
  370. CPROXY_PARAM_CALL(3)
  371. }
  372. HRESULT CProxyITfLangBarItem::GetStatus(DWORD *pdwStatus)
  373. {
  374. TraceMsg(TF_FUNC, "CProxyITfLangBarItem::GetStatus");
  375. CPROXY_PARAM_START()
  376. CPROXY_PARAM_POINTER_OUT(pdwStatus)
  377. CPROXY_PARAM_CALL(4)
  378. }
  379. HRESULT CProxyITfLangBarItem::Show(BOOL fShow)
  380. {
  381. TraceMsg(TF_FUNC, "CProxyITfLangBarItem::Show");
  382. CPROXY_PARAM_START()
  383. CPROXY_PARAM_ULONG_IN(fShow)
  384. CPROXY_PARAM_CALL(5)
  385. }
  386. HRESULT CProxyITfLangBarItem::GetTooltipString(BSTR *pbstrToolTip)
  387. {
  388. TraceMsg(TF_FUNC, "CProxyITfLangBarItem::GetTooltipString");
  389. CPROXY_PARAM_START()
  390. CPROXY_PARAM_BSTR_OUT(pbstrToolTip)
  391. CPROXY_PARAM_CALL(6)
  392. }
  393. //////////////////////////////////////////////////////////////////////////////
  394. //
  395. // CProxyITfLangBarItemButton
  396. //
  397. //////////////////////////////////////////////////////////////////////////////
  398. CProxyITfLangBarItemButton::CProxyITfLangBarItemButton(SYSTHREAD *psfn) : CProxyITfLangBarItem(psfn)
  399. {
  400. Dbg_MemSetThisNameID(TEXT("CProxyITfLangBarItemButton"));
  401. }
  402. STDAPI CProxyITfLangBarItemButton::OnClick(TfLBIClick click, POINT pt, const RECT *prcArea)
  403. {
  404. TraceMsg(TF_FUNC, "CProxyITfLangBarItemButton::OnClick");
  405. CPROXY_PARAM_START()
  406. CPROXY_PARAM_ULONG_IN(click)
  407. CPROXY_PARAM_STRUCT_IN(pt)
  408. CPROXY_PARAM_POINTER_IN(prcArea)
  409. CPROXY_PARAM_CALL(7)
  410. }
  411. STDAPI CProxyITfLangBarItemButton::InitMenu(ITfMenu *pMenu)
  412. {
  413. CPROXY_PARAM_START()
  414. CPROXY_PARAM_INTERFACE_IN(&pMenu, IID_ITfMenu)
  415. CPROXY_PARAM_CALL(8)
  416. }
  417. STDAPI CProxyITfLangBarItemButton::OnMenuSelect(UINT wID)
  418. {
  419. CPROXY_PARAM_START()
  420. CPROXY_PARAM_ULONG_IN(wID)
  421. CPROXY_PARAM_CALL(9)
  422. }
  423. STDAPI CProxyITfLangBarItemButton::GetIcon(HICON *phIcon)
  424. {
  425. CPROXY_PARAM_START()
  426. CPROXY_PARAM_HICON_OUT(phIcon)
  427. CPROXY_PARAM_CALL(10)
  428. }
  429. STDAPI CProxyITfLangBarItemButton::GetText(BSTR *pbstrText)
  430. {
  431. CPROXY_PARAM_START()
  432. CPROXY_PARAM_BSTR_OUT(pbstrText)
  433. CPROXY_PARAM_CALL(11)
  434. }
  435. //////////////////////////////////////////////////////////////////////////////
  436. //
  437. // CProxyITfLangBarItemBitmapButton
  438. //
  439. //////////////////////////////////////////////////////////////////////////////
  440. CProxyITfLangBarItemBitmapButton::CProxyITfLangBarItemBitmapButton(SYSTHREAD *psfn) : CProxyITfLangBarItem(psfn)
  441. {
  442. Dbg_MemSetThisNameID(TEXT("CProxyITfLangBarItemBitmapButton"));
  443. }
  444. STDAPI CProxyITfLangBarItemBitmapButton::OnClick(TfLBIClick click, POINT pt, const RECT *prcArea)
  445. {
  446. TraceMsg(TF_FUNC, "CProxyITfLangBarItemBitmapButton::OnClick");
  447. CPROXY_PARAM_START()
  448. CPROXY_PARAM_ULONG_IN(click)
  449. CPROXY_PARAM_STRUCT_IN(pt)
  450. CPROXY_PARAM_POINTER_IN(prcArea)
  451. CPROXY_PARAM_CALL(7)
  452. }
  453. STDAPI CProxyITfLangBarItemBitmapButton::InitMenu(ITfMenu *pMenu)
  454. {
  455. CPROXY_PARAM_START()
  456. CPROXY_PARAM_INTERFACE_IN(&pMenu, IID_ITfMenu)
  457. CPROXY_PARAM_CALL(8)
  458. }
  459. STDAPI CProxyITfLangBarItemBitmapButton::OnMenuSelect(UINT wID)
  460. {
  461. CPROXY_PARAM_START()
  462. CPROXY_PARAM_ULONG_IN(wID)
  463. CPROXY_PARAM_CALL(9)
  464. }
  465. STDAPI CProxyITfLangBarItemBitmapButton::GetPreferredSize(const SIZE *pszDefault,SIZE *psz)
  466. {
  467. CPROXY_PARAM_START()
  468. CPROXY_PARAM_POINTER_IN(pszDefault)
  469. CPROXY_PARAM_POINTER_OUT(psz)
  470. CPROXY_PARAM_CALL(10)
  471. }
  472. STDAPI CProxyITfLangBarItemBitmapButton::DrawBitmap(LONG bmWidth, LONG bmHeight, DWORD dwFlags, HBITMAP *phbmp, HBITMAP *phbmpMask)
  473. {
  474. CPROXY_PARAM_START()
  475. CPROXY_PARAM_ULONG_IN(bmWidth)
  476. CPROXY_PARAM_ULONG_IN(bmHeight)
  477. CPROXY_PARAM_ULONG_IN(dwFlags)
  478. CPROXY_PARAM_HBITMAP_OUT(phbmp)
  479. CPROXY_PARAM_HBITMAP_OUT(phbmpMask)
  480. CPROXY_PARAM_CALL(11)
  481. }
  482. STDAPI CProxyITfLangBarItemBitmapButton::GetText(BSTR *pbstrText)
  483. {
  484. CPROXY_PARAM_START()
  485. CPROXY_PARAM_BSTR_OUT(pbstrText)
  486. CPROXY_PARAM_CALL(12)
  487. }
  488. //////////////////////////////////////////////////////////////////////////////
  489. //
  490. // CProxyITfLangBarItemBitmap
  491. //
  492. //////////////////////////////////////////////////////////////////////////////
  493. CProxyITfLangBarItemBitmap::CProxyITfLangBarItemBitmap(SYSTHREAD *psfn) : CProxyITfLangBarItem(psfn)
  494. {
  495. Dbg_MemSetThisNameID(TEXT("CProxyITfLangBarItemBitmap"));
  496. }
  497. STDAPI CProxyITfLangBarItemBitmap::OnClick(TfLBIClick click, POINT pt, const RECT *prcArea)
  498. {
  499. TraceMsg(TF_FUNC, "CProxyITfLangBarItemBitmap::OnClick");
  500. CPROXY_PARAM_START()
  501. CPROXY_PARAM_ULONG_IN(click)
  502. CPROXY_PARAM_STRUCT_IN(pt)
  503. CPROXY_PARAM_POINTER_IN(prcArea)
  504. CPROXY_PARAM_CALL(7)
  505. }
  506. STDAPI CProxyITfLangBarItemBitmap::GetPreferredSize(const SIZE *pszDefault,SIZE *psz)
  507. {
  508. CPROXY_PARAM_START()
  509. CPROXY_PARAM_POINTER_IN(pszDefault)
  510. CPROXY_PARAM_POINTER_OUT(psz)
  511. CPROXY_PARAM_CALL(8)
  512. }
  513. STDAPI CProxyITfLangBarItemBitmap::DrawBitmap(LONG bmWidth, LONG bmHeight, DWORD dwFlags, HBITMAP *phbmp, HBITMAP *phbmpMask)
  514. {
  515. CPROXY_PARAM_START()
  516. CPROXY_PARAM_ULONG_IN(bmWidth)
  517. CPROXY_PARAM_ULONG_IN(bmHeight)
  518. CPROXY_PARAM_ULONG_IN(dwFlags)
  519. CPROXY_PARAM_HBITMAP_OUT(phbmp)
  520. CPROXY_PARAM_HBITMAP_OUT(phbmpMask)
  521. CPROXY_PARAM_CALL(9)
  522. }
  523. //////////////////////////////////////////////////////////////////////////////
  524. //
  525. // CProxyITfLangBarItemBalloon
  526. //
  527. //////////////////////////////////////////////////////////////////////////////
  528. CProxyITfLangBarItemBalloon::CProxyITfLangBarItemBalloon(SYSTHREAD *psfn) : CProxyITfLangBarItem(psfn)
  529. {
  530. Dbg_MemSetThisNameID(TEXT("CProxyITfLangBarItemBalloon"));
  531. }
  532. STDAPI CProxyITfLangBarItemBalloon::OnClick(TfLBIClick click, POINT pt, const RECT *prcArea)
  533. {
  534. TraceMsg(TF_FUNC, "CProxyITfLangBarItemBalloon::OnClick");
  535. CPROXY_PARAM_START()
  536. CPROXY_PARAM_ULONG_IN(click)
  537. CPROXY_PARAM_STRUCT_IN(pt)
  538. CPROXY_PARAM_POINTER_IN(prcArea)
  539. CPROXY_PARAM_CALL(7)
  540. }
  541. STDAPI CProxyITfLangBarItemBalloon::GetPreferredSize(const SIZE *pszDefault,SIZE *psz)
  542. {
  543. CPROXY_PARAM_START()
  544. CPROXY_PARAM_POINTER_IN(pszDefault)
  545. CPROXY_PARAM_POINTER_OUT(psz)
  546. CPROXY_PARAM_CALL(8)
  547. }
  548. STDAPI CProxyITfLangBarItemBalloon::GetBalloonInfo(TF_LBBALLOONINFO *pInfo)
  549. {
  550. CPROXY_PARAM_START()
  551. CPROXY_PARAM_TF_LBBALLOONINFO_OUT(pInfo)
  552. CPROXY_PARAM_CALL(9)
  553. }
  554. //////////////////////////////////////////////////////////////////////////////
  555. //
  556. // CProxyITfMenu
  557. //
  558. //////////////////////////////////////////////////////////////////////////////
  559. CProxyITfMenu::CProxyITfMenu(SYSTHREAD *psfn) : CProxyIUnknown(psfn)
  560. {
  561. Dbg_MemSetThisNameID(TEXT("CProxyITfMenu"));
  562. }
  563. STDAPI CProxyITfMenu::AddMenuItem(UINT uId,
  564. DWORD dwFlags,
  565. HBITMAP hbmp,
  566. HBITMAP hbmpMask,
  567. const WCHAR *pch,
  568. ULONG cch,
  569. ITfMenu **ppMenu)
  570. {
  571. CPROXY_PARAM_START()
  572. CPROXY_PARAM_ULONG_IN(uId)
  573. CPROXY_PARAM_ULONG_IN(dwFlags)
  574. CPROXY_PARAM_HBITMAP_IN(hbmp)
  575. CPROXY_PARAM_HBITMAP_IN(hbmpMask)
  576. CPROXY_PARAM_WCHAR_IN(pch, cch)
  577. CPROXY_PARAM_ULONG_IN(cch)
  578. CPROXY_PARAM_INTERFACE_IN_OUT(ppMenu, IID_ITfMenu)
  579. CPROXY_PARAM_CALL(3)
  580. }
  581. //////////////////////////////////////////////////////////////////////////////
  582. //
  583. // CProxyITfMenu
  584. //
  585. //////////////////////////////////////////////////////////////////////////////
  586. CProxyITfInputProcessorProfiles::CProxyITfInputProcessorProfiles(SYSTHREAD *psfn) : CProxyIUnknown(psfn)
  587. {
  588. Dbg_MemSetThisNameID(TEXT("CProxyITfInputProcessorProfiles"));
  589. }
  590. STDAPI CProxyITfInputProcessorProfiles::Register(REFCLSID rclsid)
  591. {
  592. // 3
  593. Assert(0);
  594. return E_NOTIMPL;
  595. }
  596. STDAPI CProxyITfInputProcessorProfiles::Unregister(REFCLSID rclsid)
  597. {
  598. // 4
  599. Assert(0);
  600. return E_NOTIMPL;
  601. }
  602. STDAPI CProxyITfInputProcessorProfiles::AddLanguageProfile(REFCLSID rclsid,
  603. LANGID langid,
  604. REFGUID guidProfile,
  605. const WCHAR *pchDesc,
  606. ULONG cchDesc,
  607. const WCHAR *pchIconFile,
  608. ULONG cchFile,
  609. ULONG uIconIndex)
  610. {
  611. // 5
  612. Assert(0);
  613. return E_NOTIMPL;
  614. }
  615. STDAPI CProxyITfInputProcessorProfiles::RemoveLanguageProfile(REFCLSID rclsid,
  616. LANGID langid,
  617. REFGUID guidProfile)
  618. {
  619. // 6
  620. Assert(0);
  621. return E_NOTIMPL;
  622. }
  623. STDAPI CProxyITfInputProcessorProfiles::EnumInputProcessorInfo(IEnumGUID **ppEnum)
  624. {
  625. // 7
  626. Assert(0);
  627. return E_NOTIMPL;
  628. }
  629. STDAPI CProxyITfInputProcessorProfiles::GetDefaultLanguageProfile(LANGID langid,
  630. REFGUID catid,
  631. CLSID *pclsid,
  632. GUID *pguidProfile)
  633. {
  634. // 9
  635. Assert(0);
  636. return E_NOTIMPL;
  637. }
  638. STDAPI CProxyITfInputProcessorProfiles::SetDefaultLanguageProfile(LANGID langid,
  639. REFCLSID rclsid,
  640. REFGUID guidProfiles)
  641. {
  642. // 11
  643. Assert(0);
  644. return E_NOTIMPL;
  645. }
  646. STDAPI CProxyITfInputProcessorProfiles::ActivateLanguageProfile(REFCLSID rclsid,
  647. LANGID langid,
  648. REFGUID guidProfiles)
  649. {
  650. // 12
  651. Assert(0);
  652. return E_NOTIMPL;
  653. }
  654. STDAPI CProxyITfInputProcessorProfiles::GetActiveLanguageProfile(REFCLSID rclsid,
  655. LANGID *plangid,
  656. GUID *pguidProfile)
  657. {
  658. // 13
  659. Assert(0);
  660. return E_NOTIMPL;
  661. }
  662. HRESULT CProxyITfInputProcessorProfiles::GetLanguageProfileDescription(REFCLSID rclsid,
  663. LANGID langid,
  664. REFGUID guidProfile,
  665. BSTR *pbstrProfile)
  666. {
  667. // 14
  668. Assert(0);
  669. return E_NOTIMPL;
  670. }
  671. STDAPI CProxyITfInputProcessorProfiles::GetCurrentLanguage(LANGID *plangid)
  672. {
  673. // 15
  674. CPROXY_PARAM_START()
  675. CPROXY_PARAM_POINTER_OUT(plangid)
  676. CPROXY_PARAM_CALL(14)
  677. }
  678. STDAPI CProxyITfInputProcessorProfiles::ChangeCurrentLanguage(LANGID langid)
  679. {
  680. // 16
  681. Assert(0);
  682. return E_NOTIMPL;
  683. }
  684. STDAPI CProxyITfInputProcessorProfiles::GetLanguageList(LANGID **ppLangId,
  685. ULONG *pulCount)
  686. {
  687. // 17
  688. Assert(0);
  689. return E_NOTIMPL;
  690. }
  691. STDAPI CProxyITfInputProcessorProfiles::EnumLanguageProfiles(LANGID langid,
  692. IEnumTfLanguageProfiles **ppEnum)
  693. {
  694. // 18
  695. Assert(0);
  696. return E_NOTIMPL;
  697. }
  698. STDAPI CProxyITfInputProcessorProfiles::EnableLanguageProfile(REFCLSID rclsid,
  699. LANGID langid,
  700. REFGUID guidProfile,
  701. BOOL fEnable)
  702. {
  703. // 19
  704. Assert(0);
  705. return E_NOTIMPL;
  706. }
  707. STDAPI CProxyITfInputProcessorProfiles::IsEnabledLanguageProfile(REFCLSID rclsid,
  708. LANGID langid,
  709. REFGUID guidProfile,
  710. BOOL *pfEnable)
  711. {
  712. // 20
  713. Assert(0);
  714. return E_NOTIMPL;
  715. }
  716. STDAPI CProxyITfInputProcessorProfiles::EnableLanguageProfileByDefault(REFCLSID rclsid,
  717. LANGID langid,
  718. REFGUID guidProfile,
  719. BOOL fEnable)
  720. {
  721. // 21
  722. Assert(0);
  723. return E_NOTIMPL;
  724. }
  725. STDAPI CProxyITfInputProcessorProfiles::SubstituteKeyboardLayout(REFCLSID rclsid,
  726. LANGID langid,
  727. REFGUID guidProfile,
  728. HKL hKL)
  729. {
  730. // 22
  731. Assert(0);
  732. return E_NOTIMPL;
  733. }