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.

203 lines
6.2 KiB

  1. #include "rpcproxy.h"
  2. #include "docobj.h"
  3. #include "servprov.h"
  4. #include "dispex.h"
  5. #include "comcat.h"
  6. #include "activscp.h"
  7. /* [local] */ HRESULT __stdcall IEnumOleDocumentViews_Next_Proxy(
  8. IEnumOleDocumentViews __RPC_FAR * This,
  9. /* [in] */ ULONG cViews,
  10. /* [out] */ IOleDocumentView __RPC_FAR *__RPC_FAR *rgpViews,
  11. /* [out] */ ULONG __RPC_FAR *pcFetched)
  12. {
  13. HRESULT hr;
  14. ULONG cFetched = 0;
  15. hr = IEnumOleDocumentViews_RemoteNext_Proxy(This, cViews, rgpViews, &cFetched);
  16. if(pcFetched != 0)
  17. *pcFetched = cFetched;
  18. return hr;
  19. }
  20. /* [call_as] */ HRESULT __stdcall IEnumOleDocumentViews_Next_Stub(
  21. IEnumOleDocumentViews __RPC_FAR * This,
  22. /* [in] */ ULONG cViews,
  23. /* [length_is][size_is][out] */ IOleDocumentView __RPC_FAR *__RPC_FAR *rgpView,
  24. /* [out] */ ULONG __RPC_FAR *pcFetched)
  25. {
  26. HRESULT hr;
  27. *pcFetched = 0;
  28. hr = This->lpVtbl->Next(This, cViews, rgpView, pcFetched);
  29. return hr;
  30. }
  31. /* [local] */ HRESULT __stdcall IPrint_Print_Proxy(
  32. IPrint __RPC_FAR * This,
  33. /* [in] */ DWORD grfFlags,
  34. /* [out][in] */ DVTARGETDEVICE __RPC_FAR *__RPC_FAR *pptd,
  35. /* [out][in] */ PAGESET __RPC_FAR *__RPC_FAR *ppPageSet,
  36. /* [unique][out][in] */ STGMEDIUM __RPC_FAR *pstgmOptions,
  37. /* [in] */ IContinueCallback __RPC_FAR *pcallback,
  38. /* [in] */ LONG nFirstPage,
  39. /* [out] */ LONG __RPC_FAR *pcPagesPrinted,
  40. /* [out] */ LONG __RPC_FAR *pnLastPage)
  41. {
  42. return IPrint_RemotePrint_Proxy(This, grfFlags, pptd, ppPageSet,
  43. (RemSTGMEDIUM __RPC_FAR *) pstgmOptions, pcallback,
  44. nFirstPage, pcPagesPrinted, pnLastPage);
  45. }
  46. /* [call_as] */ HRESULT __stdcall IPrint_Print_Stub(
  47. IPrint __RPC_FAR * This,
  48. /* [in] */ DWORD grfFlags,
  49. /* [out][in] */ DVTARGETDEVICE __RPC_FAR *__RPC_FAR *pptd,
  50. /* [out][in] */ PAGESET __RPC_FAR *__RPC_FAR *ppPageSet,
  51. /* [unique][out][in] */ RemSTGMEDIUM __RPC_FAR *pstgmOptions,
  52. /* [in] */ IContinueCallback __RPC_FAR *pcallback,
  53. /* [in] */ LONG nFirstPage,
  54. /* [out] */ LONG __RPC_FAR *pcPagesPrinted,
  55. /* [out] */ LONG __RPC_FAR *pnLastPage)
  56. {
  57. return This->lpVtbl->Print(This, grfFlags, pptd, ppPageSet,
  58. (STGMEDIUM __RPC_FAR *) pstgmOptions, pcallback,
  59. nFirstPage, pcPagesPrinted, pnLastPage);
  60. }
  61. /* [local] */ HRESULT __stdcall IServiceProvider_QueryService_Proxy(
  62. IServiceProvider __RPC_FAR * This,
  63. /* [in] */ REFGUID guidService,
  64. /* [in] */ REFIID riid,
  65. /* [out] */ void __RPC_FAR *__RPC_FAR *ppvObject)
  66. {
  67. *ppvObject = NULL;
  68. return IServiceProvider_RemoteQueryService_Proxy(This, guidService, riid,
  69. (IUnknown**)ppvObject);
  70. }
  71. /* [call_as] */ HRESULT __stdcall IServiceProvider_QueryService_Stub(
  72. IServiceProvider __RPC_FAR * This,
  73. /* [in] */ REFGUID guidService,
  74. /* [in] */ REFIID riid,
  75. /* [iid_is][out] */ IUnknown __RPC_FAR *__RPC_FAR *ppvObject)
  76. {
  77. *ppvObject = NULL;
  78. return This->lpVtbl->QueryService(This, guidService, riid, ppvObject);
  79. }
  80. /* [local] */ HRESULT STDMETHODCALLTYPE ICatInformation_EnumClassesOfCategories_Proxy(
  81. ICatInformation __RPC_FAR * This,
  82. /* [in] */ ULONG cImplemented,
  83. /* [size_is][in] */ CATID __RPC_FAR rgcatidImpl[ ],
  84. /* [in] */ ULONG cRequired,
  85. /* [size_is][in] */ CATID __RPC_FAR rgcatidReq[ ],
  86. /* [out] */ IEnumGUID __RPC_FAR *__RPC_FAR *ppenumClsid)
  87. {
  88. BOOL fcImpl,fcReq;
  89. if (cImplemented == (ULONG)-1)
  90. {
  91. rgcatidImpl = NULL;
  92. }
  93. if (cRequired == (ULONG)-1)
  94. {
  95. rgcatidReq = NULL;
  96. }
  97. return ICatInformation_RemoteEnumClassesOfCategories_Proxy(This,cImplemented,rgcatidImpl,
  98. cRequired,rgcatidReq,ppenumClsid);
  99. }
  100. /* [call_as] */ HRESULT STDMETHODCALLTYPE ICatInformation_EnumClassesOfCategories_Stub(
  101. ICatInformation __RPC_FAR * This,
  102. /* [in] */ ULONG cImplemented,
  103. /* [size_is][in] */ CATID __RPC_FAR rgcatidImpl[ ],
  104. /* [in] */ ULONG cRequired,
  105. /* [size_is][in] */ CATID __RPC_FAR rgcatidReq[ ],
  106. /* [out] */ IEnumGUID __RPC_FAR *__RPC_FAR *ppenumClsid)
  107. {
  108. return This->lpVtbl->EnumClassesOfCategories(This,cImplemented,rgcatidImpl,
  109. cRequired,rgcatidReq,ppenumClsid);
  110. }
  111. /* [local] */ HRESULT STDMETHODCALLTYPE ICatInformation_IsClassOfCategories_Proxy(
  112. ICatInformation __RPC_FAR * This,
  113. /* [in] */ REFCLSID rclsid,
  114. /* [in] */ ULONG cImplemented,
  115. /* [size_is][in] */ CATID __RPC_FAR rgcatidImpl[ ],
  116. /* [in] */ ULONG cRequired,
  117. /* [size_is][in] */ CATID __RPC_FAR rgcatidReq[ ])
  118. {
  119. BOOL fcImpl,fcReq;
  120. if (cImplemented == (ULONG)-1)
  121. {
  122. rgcatidImpl = NULL;
  123. }
  124. else
  125. fcImpl = FALSE;
  126. if (cRequired == (ULONG)-1 )
  127. {
  128. rgcatidReq = NULL;
  129. }
  130. else
  131. fcReq = FALSE;
  132. return ICatInformation_RemoteIsClassOfCategories_Proxy(This,rclsid,cImplemented,rgcatidImpl,
  133. cRequired,rgcatidReq);
  134. }
  135. /* [call_as] */ HRESULT STDMETHODCALLTYPE ICatInformation_IsClassOfCategories_Stub(
  136. ICatInformation __RPC_FAR * This,
  137. /* [in] */ REFCLSID rclsid,
  138. /* [in] */ ULONG cImplemented,
  139. /* [size_is][in] */ CATID __RPC_FAR rgcatidImpl[ ],
  140. /* [in] */ ULONG cRequired,
  141. /* [size_is][in] */ CATID __RPC_FAR rgcatidReq[ ])
  142. {
  143. return This->lpVtbl->IsClassOfCategories(This,rclsid,cImplemented,rgcatidImpl,
  144. cRequired,rgcatidReq);
  145. }
  146. // IActiveScriptError
  147. /* [local] */ HRESULT __stdcall IActiveScriptError_GetExceptionInfo_Proxy(
  148. IActiveScriptError __RPC_FAR * This,
  149. /* [out] */ EXCEPINFO *pexcepinfo)
  150. {
  151. return IActiveScriptError_RemoteGetExceptionInfo_Proxy(This, pexcepinfo);
  152. }
  153. /* [call_as] */ HRESULT __stdcall IActiveScriptError_GetExceptionInfo_Stub(
  154. IActiveScriptError __RPC_FAR * This,
  155. /* [out] */ EXCEPINFO *pexcepinfo)
  156. {
  157. HRESULT hr;
  158. hr = This->lpVtbl->GetExceptionInfo(This, pexcepinfo);
  159. if (SUCCEEDED (hr) && pexcepinfo->pfnDeferredFillIn != NULL)
  160. {
  161. if (FAILED(pexcepinfo->pfnDeferredFillIn(pexcepinfo)))
  162. hr = ResultFromScode(pexcepinfo->scode);
  163. }
  164. return hr;
  165. }