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.

319 lines
7.7 KiB

  1. /*++
  2. Copyright (c) Microsoft Corporation. All rights reserved.
  3. Module Name:
  4. rasdlg.h
  5. Abstract:
  6. Remote Access Common Dialog APIs
  7. These APIs live in RASDLG.DLL.
  8. The APIs in this header are added in Windows NT SUR and are not available
  9. in prior Windows NT or Windows 95 releases.
  10. --*/
  11. #ifndef _RASDLG_H_
  12. #define _RASDLG_H_
  13. #if _MSC_VER > 1000
  14. #pragma once
  15. #endif
  16. #include <pshpack4.h>
  17. #ifdef __cplusplus
  18. extern "C" {
  19. #endif
  20. #include <ras.h>
  21. /* RasPhonebookDlg API callback.
  22. */
  23. typedef VOID (WINAPI* RASPBDLGFUNCW)( ULONG_PTR, DWORD, LPWSTR, LPVOID );
  24. typedef VOID (WINAPI* RASPBDLGFUNCA)( ULONG_PTR, DWORD, LPSTR, LPVOID );
  25. #define RASPBDEVENT_AddEntry 1
  26. #define RASPBDEVENT_EditEntry 2
  27. #define RASPBDEVENT_RemoveEntry 3
  28. #define RASPBDEVENT_DialEntry 4
  29. #define RASPBDEVENT_EditGlobals 5
  30. #define RASPBDEVENT_NoUser 6
  31. #define RASPBDEVENT_NoUserEdit 7
  32. #define RASNOUSER_SmartCard 0x00000001
  33. /* Defines the information passed in the 4th argument of RASPBDLGFUNC on
  34. ** "NoUser" and "NoUserEdit" events. Usage shown is for "NoUser". For
  35. ** "NoUserEdit", the timeout is ignored and the three strings are INs.
  36. */
  37. #define RASNOUSERW struct tagRASNOUSERW
  38. RASNOUSERW
  39. {
  40. IN DWORD dwSize;
  41. IN DWORD dwFlags;
  42. OUT DWORD dwTimeoutMs;
  43. OUT WCHAR szUserName[ UNLEN + 1 ];
  44. OUT WCHAR szPassword[ PWLEN + 1 ];
  45. OUT WCHAR szDomain[ DNLEN + 1 ];
  46. };
  47. #define RASNOUSERA struct tagRASNOUSERA
  48. RASNOUSERA
  49. {
  50. IN DWORD dwSize;
  51. IN DWORD dwFlags;
  52. OUT DWORD dwTimeoutMs;
  53. OUT CHAR szUserName[ UNLEN + 1 ];
  54. OUT CHAR szPassword[ PWLEN + 1 ];
  55. OUT CHAR szDomain[ DNLEN + 1 ];
  56. };
  57. #ifdef UNICODE
  58. #define RASNOUSER RASNOUSERW
  59. #else
  60. #define RASNOUSER RASNOUSERA
  61. #endif
  62. #define LPRASNOUSERW RASNOUSERW*
  63. #define LPRASNOUSERA RASNOUSERA*
  64. #define LPRASNOUSER RASNOUSER*
  65. /* RasPhonebookDlg API parameters.
  66. */
  67. #define RASPBDFLAG_PositionDlg 0x00000001
  68. #define RASPBDFLAG_ForceCloseOnDial 0x00000002
  69. #define RASPBDFLAG_NoUser 0x00000010
  70. #define RASPBDFLAG_UpdateDefaults 0x80000000
  71. #define RASPBDLGW struct tagRASPBDLGW
  72. RASPBDLGW
  73. {
  74. IN DWORD dwSize;
  75. IN HWND hwndOwner;
  76. IN DWORD dwFlags;
  77. IN LONG xDlg;
  78. IN LONG yDlg;
  79. IN ULONG_PTR dwCallbackId;
  80. IN RASPBDLGFUNCW pCallback;
  81. OUT DWORD dwError;
  82. IN ULONG_PTR reserved;
  83. IN ULONG_PTR reserved2;
  84. };
  85. #define RASPBDLGA struct tagRASPBDLGA
  86. RASPBDLGA
  87. {
  88. IN DWORD dwSize;
  89. IN HWND hwndOwner;
  90. IN DWORD dwFlags;
  91. IN LONG xDlg;
  92. IN LONG yDlg;
  93. IN ULONG_PTR dwCallbackId;
  94. IN RASPBDLGFUNCA pCallback;
  95. OUT DWORD dwError;
  96. IN ULONG_PTR reserved;
  97. IN ULONG_PTR reserved2;
  98. };
  99. #ifdef UNICODE
  100. #define RASPBDLG RASPBDLGW
  101. #define RASPBDLGFUNC RASPBDLGFUNCW
  102. #else
  103. #define RASPBDLG RASPBDLGA
  104. #define RASPBDLGFUNC RASPBDLGFUNCA
  105. #endif
  106. #define LPRASPBDLGW RASPBDLGW*
  107. #define LPRASPBDLGA RASPBDLGA*
  108. #define LPRASPBDLG RASPBDLG*
  109. /* RasEntryDlg API parameters.
  110. */
  111. #define RASEDFLAG_PositionDlg 0x00000001
  112. #define RASEDFLAG_NewEntry 0x00000002
  113. #define RASEDFLAG_CloneEntry 0x00000004
  114. #define RASEDFLAG_NoRename 0x00000008
  115. #define RASEDFLAG_ShellOwned 0x40000000
  116. #define RASEDFLAG_NewPhoneEntry 0x00000010
  117. #define RASEDFLAG_NewTunnelEntry 0x00000020
  118. #define RASEDFLAG_NewDirectEntry 0x00000040
  119. #define RASEDFLAG_NewBroadbandEntry 0x00000080
  120. #define RASEDFLAG_InternetEntry 0x00000100
  121. #define RASEDFLAG_NAT 0x00000200
  122. #define RASENTRYDLGW struct tagRASENTRYDLGW
  123. RASENTRYDLGW
  124. {
  125. IN DWORD dwSize;
  126. IN HWND hwndOwner;
  127. IN DWORD dwFlags;
  128. IN LONG xDlg;
  129. IN LONG yDlg;
  130. OUT WCHAR szEntry[ RAS_MaxEntryName + 1 ];
  131. OUT DWORD dwError;
  132. IN ULONG_PTR reserved;
  133. IN ULONG_PTR reserved2;
  134. };
  135. #define RASENTRYDLGA struct tagRASENTRYDLGA
  136. RASENTRYDLGA
  137. {
  138. IN DWORD dwSize;
  139. IN HWND hwndOwner;
  140. IN DWORD dwFlags;
  141. IN LONG xDlg;
  142. IN LONG yDlg;
  143. OUT CHAR szEntry[ RAS_MaxEntryName + 1 ];
  144. OUT DWORD dwError;
  145. IN ULONG_PTR reserved;
  146. IN ULONG_PTR reserved2;
  147. };
  148. #ifdef UNICODE
  149. #define RASENTRYDLG RASENTRYDLGW
  150. #else
  151. #define RASENTRYDLG RASENTRYDLGA
  152. #endif
  153. #define LPRASENTRYDLGW RASENTRYDLGW*
  154. #define LPRASENTRYDLGA RASENTRYDLGA*
  155. #define LPRASENTRYDLG RASENTRYDLG*
  156. /* RasDialDlg API parameters.
  157. */
  158. #define RASDDFLAG_PositionDlg 0x00000001
  159. #define RASDDFLAG_NoPrompt 0x00000002
  160. #define RASDDFLAG_LinkFailure 0x80000000
  161. #define RASDIALDLG struct tagRASDIALDLG
  162. RASDIALDLG
  163. {
  164. IN DWORD dwSize;
  165. IN HWND hwndOwner;
  166. IN DWORD dwFlags;
  167. IN LONG xDlg;
  168. IN LONG yDlg;
  169. IN DWORD dwSubEntry;
  170. OUT DWORD dwError;
  171. IN ULONG_PTR reserved;
  172. IN ULONG_PTR reserved2;
  173. };
  174. #define LPRASDIALDLG RASDIALDLG*
  175. /* RasMonitorDlg API parameters.
  176. */
  177. #if (WINVER <= 0x500)
  178. #define RASMDPAGE_Status 0
  179. #define RASMDPAGE_Summary 1
  180. #define RASMDPAGE_Preferences 2
  181. #define RASMDFLAG_PositionDlg 0x00000001
  182. #define RASMDFLAG_UpdateDefaults 0x80000000
  183. #define RASMONITORDLG struct tagRASMONITORDLG
  184. RASMONITORDLG
  185. {
  186. IN DWORD dwSize;
  187. IN HWND hwndOwner;
  188. IN DWORD dwFlags;
  189. IN DWORD dwStartPage;
  190. IN LONG xDlg;
  191. IN LONG yDlg;
  192. OUT DWORD dwError;
  193. IN ULONG_PTR reserved;
  194. IN ULONG_PTR reserved2;
  195. };
  196. #define LPRASMONITORDLG RASMONITORDLG*
  197. #endif
  198. #if (WINVER >= 0x500)
  199. typedef BOOL (WINAPI *RasCustomDialDlgFn) (
  200. HINSTANCE hInstDll,
  201. DWORD dwFlags,
  202. LPWSTR lpszPhonebook,
  203. LPWSTR lpszEntry,
  204. LPWSTR lpszPhoneNumber,
  205. LPRASDIALDLG lpInfo,
  206. PVOID pvInfo
  207. );
  208. typedef BOOL (WINAPI *RasCustomEntryDlgFn) (
  209. HINSTANCE hInstDll,
  210. LPWSTR lpszPhonebook,
  211. LPWSTR lpszEntry,
  212. LPRASENTRYDLG lpInfo,
  213. DWORD dwFlags
  214. );
  215. #endif
  216. /* RAS common dialog API prototypes.
  217. */
  218. BOOL APIENTRY RasPhonebookDlgA(
  219. LPSTR lpszPhonebook, LPSTR lpszEntry, LPRASPBDLGA lpInfo );
  220. BOOL APIENTRY RasPhonebookDlgW(
  221. LPWSTR lpszPhonebook, LPWSTR lpszEntry, LPRASPBDLGW lpInfo );
  222. BOOL APIENTRY RasEntryDlgA(
  223. LPSTR lpszPhonebook, LPSTR lpszEntry, LPRASENTRYDLGA lpInfo );
  224. BOOL APIENTRY RasEntryDlgW(
  225. LPWSTR lpszPhonebook, LPWSTR lpszEntry, LPRASENTRYDLGW lpInfo );
  226. BOOL APIENTRY RasDialDlgA(
  227. LPSTR lpszPhonebook, LPSTR lpszEntry, LPSTR lpszPhoneNumber,
  228. LPRASDIALDLG lpInfo );
  229. BOOL APIENTRY RasDialDlgW(
  230. LPWSTR lpszPhonebook, LPWSTR lpszEntry, LPWSTR lpszPhoneNumber,
  231. LPRASDIALDLG lpInfo );
  232. #if (WINVER <= 0x500)
  233. BOOL APIENTRY RasMonitorDlgA(
  234. LPSTR lpszDeviceName, LPRASMONITORDLG lpInfo );
  235. BOOL APIENTRY RasMonitorDlgW(
  236. LPWSTR lpszDeviceName, LPRASMONITORDLG lpInfo );
  237. #endif
  238. #ifdef UNICODE
  239. #define RasPhonebookDlg RasPhonebookDlgW
  240. #define RasEntryDlg RasEntryDlgW
  241. #define RasDialDlg RasDialDlgW
  242. #if (WINVER <= 0x500)
  243. #define RasMonitorDlg RasMonitorDlgW
  244. #endif
  245. #else
  246. #define RasPhonebookDlg RasPhonebookDlgA
  247. #define RasEntryDlg RasEntryDlgA
  248. #define RasDialDlg RasDialDlgA
  249. #if (WINVER <= 0x500)
  250. #define RasMonitorDlg RasMonitorDlgA
  251. #endif
  252. #endif
  253. #ifdef __cplusplus
  254. }
  255. #endif
  256. #include <poppack.h>
  257. #endif // _RASDLG_H_