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.

165 lines
3.9 KiB

  1. #ifndef PP_H
  2. #define PP_H
  3. #define SERIAL_ADVANCED_SETTINGS
  4. #include "msports.h"
  5. #ifdef USE_P_TRACE_ERR
  6. #define P_TRACE_ERR(_x) MessageBox( GetFocus(), TEXT(_x), TEXT("ports traceerr"), MB_OK | MB_ICONINFORMATION );
  7. #define W_TRACE_ERR(_x) MessageBox( GetFocus(), _x, TEXT("ports traceerr"), MB_OK | MB_ICONINFORMATION );
  8. #else
  9. #define P_TRACE_ERR(_x)
  10. #define W_TRACE_ERR(_x)
  11. #endif
  12. #define DO_COM_PORT_RENAMES
  13. #define RX_MIN 1
  14. #define RX_MAX 14
  15. #define TX_MIN 1
  16. #define TX_MAX 16
  17. TCHAR m_szDevMgrHelp[];
  18. #if defined(_X86_)
  19. //
  20. // For NEC PC98. Following definition comes from user\inc\kbd.h.
  21. // The value must be the same as value in kbd.h.
  22. //
  23. #define NLSKBD_OEM_NEC 0x0D
  24. #endif // FE_SB && _X86_
  25. //
  26. // Structures
  27. //
  28. typedef struct _ADVANCED_DATA
  29. {
  30. //BOOL PPPAware;
  31. BOOL WriteComplete;
  32. BOOL HidePolling;
  33. BOOL UseFifoBuffersControl;
  34. BOOL UseFifoBuffers;
  35. BOOL UseRxFIFOControl;
  36. BOOL UseTxFIFOControl;
  37. DWORD FifoRxMax;
  38. DWORD FifoTxMax;
  39. DWORD RxFIFO;
  40. DWORD TxFIFO;
  41. DWORD PollingPeriod;
  42. TCHAR szComName[20];
  43. TCHAR szNewComName[20];
  44. HKEY hDeviceKey; // (like ROOT\LEGACY_BEEP\0000)
  45. HCOMDB hComDB;
  46. HDEVINFO DeviceInfoSet;
  47. PSP_DEVINFO_DATA DeviceInfoData;
  48. } ADVANCED_DATA, *PADVANCED_DATA;
  49. ///////////////////////////////////////////////////////////////////////////////////
  50. // Advanced Dialog Prototypes
  51. ///////////////////////////////////////////////////////////////////////////////////
  52. ULONG
  53. FillPortNameCb(
  54. HWND ParentHwnd,
  55. PADVANCED_DATA Params
  56. );
  57. INT_PTR APIENTRY
  58. AdvancedPortsDlgProc(
  59. IN HWND hDlg,
  60. IN UINT uMessage,
  61. IN WPARAM wParam,
  62. IN LPARAM lParam
  63. );
  64. ULONG
  65. FillAdvancedDlg(
  66. IN HWND DialogHwnd,
  67. IN PADVANCED_DATA AdvancedData
  68. );
  69. BOOL
  70. DisplayAdvancedDialog(
  71. IN HWND DialogHwnd,
  72. IN OUT PADVANCED_DATA AdvancedData
  73. );
  74. void
  75. InitializeControls(
  76. IN HWND DialogHwnd,
  77. IN PADVANCED_DATA AdvancedData
  78. );
  79. void
  80. RestoreAdvancedDefaultState(
  81. IN HWND DialogHwnd,
  82. IN PADVANCED_DATA AdvancedData
  83. );
  84. ULONG
  85. SaveAdvancedSettings(
  86. IN HWND DialogHwnd,
  87. IN PADVANCED_DATA AdvancedData
  88. );
  89. void
  90. SetTrackbarTicks(
  91. IN HWND TrackbarHwnd,
  92. IN DWORD MinVal,
  93. IN DWORD MaxVal
  94. );
  95. void
  96. SetLabelText(
  97. IN HWND LabelHwnd,
  98. IN DWORD ResId,
  99. IN ULONG Value
  100. );
  101. void
  102. HandleTrackbarChange(
  103. IN HWND DialogHwnd,
  104. IN HWND TrackbarHwnd
  105. );
  106. void
  107. EnableFifoControls(
  108. HWND DialogHwnd,
  109. BOOL Enabled
  110. );
  111. // Context help header file and arrays for devmgr ports tab
  112. // Created 2/21/98 by WGruber NTUA and DoronH NTDEV
  113. //
  114. // "Cyclades-Z Port Advanced Settings" Dialog Box
  115. //
  116. #define IDH_NOHELP ((DWORD)-1)
  117. #define IDH_DEVMGR_PORTSET_ADVANCED 15840 // "&Advanced" (Button)
  118. #define IDH_DEVMGR_PORTSET_BPS 15841 // "" (ComboBox)
  119. #define IDH_DEVMGR_PORTSET_DATABITS 15842 // "" (ComboBox)
  120. #define IDH_DEVMGR_PORTSET_PARITY 15843 // "" (ComboBox)
  121. #define IDH_DEVMGR_PORTSET_STOPBITS 15844 // "" (ComboBox)
  122. #define IDH_DEVMGR_PORTSET_FLOW 15845 // "" (ComboBox)
  123. #define IDH_DEVMGR_PORTSET_DEFAULTS 15892 // "&Restore Defaults" (Button)
  124. //
  125. // "Advanced Communications Port Properties" Dialog Box
  126. //
  127. #define IDH_DEVMGR_PORTSET_ADV_USEFIFO 16885 // "&Use FIFO buffers (requires 16550 compatible UART)" (Button)
  128. #define IDH_DEVMGR_PORTSET_ADV_TRANS 16842 // "" (msctls_trackbar32)
  129. #define IDH_DEVMGR_PORTSET_ADV_DEVICES 161027 // "" (ComboBox)
  130. #define IDH_DEVMGR_PORTSET_ADV_RECV 16821 // "" (msctls_trackbar32)
  131. #define IDH_DEVMGR_PORTSET_ADV_NUMBER 16846 // "" (ComboBox)
  132. #define IDH_DEVMGR_PORTSET_ADV_DEFAULTS 16844
  133. #endif // PP_H