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.

133 lines
2.8 KiB

  1. /*++
  2. Microsoft Confidential
  3. Copyright (c) 1992-1997 Microsoft Corporation
  4. All rights reserved
  5. Module Name:
  6. sysdm.h
  7. Abstract:
  8. Applet-wide declaraions and definitions for the
  9. System Control Panel Applet.
  10. Author:
  11. Eric Flo (ericflo) 19-Jun-1995
  12. Revision History:
  13. 15-Oct-1997 scotthal
  14. Complete overhaul
  15. --*/
  16. #ifndef _SYSDM_H_
  17. #define _SYSDM_H_
  18. #include <nt.h>
  19. #include <ntrtl.h>
  20. #include <nturtl.h>
  21. #include <ntexapi.h>
  22. #include <windows.h>
  23. #include <commctrl.h>
  24. #include <comctrlp.h>
  25. #include <shellapi.h>
  26. #include <shlobj.h>
  27. #include <shlobjp.h>
  28. #include <shlwapi.h>
  29. #include <shlwapip.h>
  30. #include <cpl.h>
  31. #define STRSAFE_NO_DEPRECATE
  32. #include <strsafe.h>
  33. #ifdef __cplusplus
  34. extern "C" {
  35. #endif // __cplusplus
  36. #include "resource.h"
  37. #include "helpid.h"
  38. #include "util.h"
  39. #include "sid.h"
  40. #include "general.h"
  41. #include "netid.h"
  42. #include "hardware.h"
  43. #include "hwprof.h"
  44. #include "profile.h"
  45. #include "advanced.h"
  46. #include "perf.h"
  47. #include "virtual.h"
  48. #include "startup.h"
  49. #include "envvar.h"
  50. #include "edtenvar.h"
  51. #include "syspart.h"
  52. #include "pfrscpl.h"
  53. #include "srcfg.h"
  54. #include "visualfx.h"
  55. //
  56. // Global variables
  57. //
  58. extern TCHAR g_szErrMem[ 200 ]; // Low memory message
  59. extern TCHAR g_szSystemApplet[ 100 ]; // "System Control Panel Applet" title
  60. extern HINSTANCE hInstance;
  61. extern TCHAR g_szNull[];
  62. extern BOOL g_fRebootRequired;
  63. //
  64. // Macros
  65. //
  66. #define ARRAYSIZE(a) (sizeof(a)/sizeof(a[0]))
  67. #define SetLBWidth( hwndLB, szStr, cxCurWidth ) SetLBWidthEx( hwndLB, szStr, cxCurWidth, 0)
  68. #define IsPathSep(ch) ((ch) == TEXT('\\') || (ch) == TEXT('/'))
  69. #define IsWhiteSpace(ch) ((ch) == TEXT(' ') || (ch) == TEXT('\t') || (ch) == TEXT('\n') || (ch) == TEXT('\r'))
  70. #define IsDigit(ch) ((ch) >= TEXT('0') && (ch) <= TEXT('9'))
  71. #define DigitVal(ch) ((ch) - TEXT('0'))
  72. #define MAX_PAGES 16 // Arbitrary Maximum number of pages in the System Control Panel.
  73. typedef HPROPSHEETPAGE (*PSPCALLBACK)(int idd, DLGPROC pfnDlgProc);
  74. typedef struct
  75. {
  76. PSPCALLBACK pfnCreatePage;
  77. int idd;
  78. DLGPROC pfnDlgProc;
  79. }
  80. PSPINFO;
  81. HPROPSHEETPAGE CreatePage(int idd, DLGPROC pfnDlgProc);
  82. //
  83. // Debugging macros
  84. //
  85. #if DBG
  86. # define DBG_CODE 1
  87. void DbgPrintf( LPTSTR szFmt, ... );
  88. void DbgStopX(LPSTR mszFile, int iLine, LPTSTR szText );
  89. # define DBGSTOP( t ) DbgStopX( __FILE__, __LINE__, TEXT(t) )
  90. # define DBGSTOPX( f, l, t ) DbgStopX( f, l, TEXT(t) )
  91. # define DBGPRINTF(p) DbgPrintf p
  92. # define DBGOUT(t) DbgPrintf( TEXT("SYSDM.CPL: %s\n"), TEXT(t) )
  93. #else
  94. # define DBGSTOP( t )
  95. # define DBGSTOPX( f, l, t )
  96. # define DBGPRINTF(p)
  97. # define DBGOUT(t)
  98. #endif
  99. #ifdef __cplusplus
  100. } // extern "C"
  101. #endif // __cplusplus
  102. #endif // _SYSDM_H_