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.

118 lines
2.9 KiB

  1. //Copyright (c) 1998 - 1999 Microsoft Corporation
  2. #ifndef _SNODES_H
  3. #define _SNODES_H
  4. #include "dataobj.h"
  5. #include "resource.h"
  6. //
  7. // WARNING -
  8. // Following enum, VALIDOBJECTONSERVER, VALIDOBJECTONADS, and RGRESID
  9. // has one to one correspondence, if you add/remove/change order of item,
  10. // you must also update the other arrays.
  11. //
  12. //
  13. // Object ID for the item display on the right panel (under server settings)
  14. //
  15. #define CUSTOM_EXTENSION 6
  16. enum { DELETED_DIRS_ONEXIT, // delete temp. folder on exit
  17. PERSESSION_TEMPDIR, // use temporary folder per session
  18. LICENSING, // licensing mode
  19. ACTIVE_DESK, // active desktop
  20. USERSECURITY, // FULL or relax security
  21. SINGLE_SESSION}; // single session per user.
  22. //
  23. // Valid item to be display on right panel
  24. // when running in server.
  25. //
  26. const BOOL VALIDOBJECTONSERVER[] = {
  27. TRUE,
  28. TRUE,
  29. FALSE, // licensing
  30. TRUE,
  31. FALSE,
  32. FALSE };
  33. //
  34. // Valid item to be display on right panel
  35. // when running in advance server.
  36. //
  37. const BOOL VALIDOBJECTONADS[] = {
  38. TRUE,
  39. TRUE,
  40. TRUE,
  41. TRUE,
  42. TRUE,
  43. TRUE };
  44. //
  45. // Resource ID for the item
  46. //
  47. const INT RGRESID [] = {
  48. IDS_DELTEMPONEXIT,
  49. IDS_USETEMPDIR,
  50. IDS_LICENSING,
  51. IDS_ADS_ATTR,
  52. IDS_USERPERM,
  53. IDS_SINGLE_SESSION };
  54. class CSettingNode : public CBaseNode
  55. {
  56. LPTSTR m_szAttributeName;
  57. LPTSTR m_szAttributeValue;
  58. INT m_nGenericValue;
  59. INT m_objectid;
  60. HRESULT m_hrStatus;
  61. public:
  62. CSettingNode( );
  63. virtual ~CSettingNode( );
  64. HRESULT SetAttributeValue( DWORD , PDWORD );
  65. BOOL SetAttributeName( LPTSTR );
  66. LPTSTR GetAttributeName( ){ return m_szAttributeName; }
  67. LPTSTR GetAttributeValue( );
  68. LPTSTR GetCachedValue( ){ return m_szAttributeValue; }
  69. DWORD GetImageIdx( );
  70. void SetObjectId( INT );
  71. INT GetObjectId( ) { return m_objectid; }
  72. BOOL AddMenuItems( LPCONTEXTMENUCALLBACK , PLONG );
  73. BOOL SetInterface( LPUNKNOWN );
  74. BOOL xx_SetValue( INT );
  75. INT xx_GetValue( ){ return m_nGenericValue; }
  76. HRESULT GetNodeStatus( ) const { return m_hrStatus; }
  77. LPUNKNOWN GetInterface( ) { return m_pSettings; }
  78. private:
  79. LPUNKNOWN m_pSettings;
  80. };
  81. #endif //_SNODES_H