Source code of Windows XP (NT5)
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.

159 lines
4.8 KiB

  1. //Copyright (c) 1998 - 1999 Microsoft Corporation
  2. /*******************************************************************************
  3. *
  4. * appsvdoc.h
  5. *
  6. * interface of the CWinStationListObjectHint and CAppServerDoc classes
  7. *
  8. * copyright notice: Copyright 1994, Citrix Systems Inc.
  9. *
  10. * $Author: donm $ Butch Davis
  11. *
  12. * $Log: N:\nt\private\utils\citrix\winutils\tscfg\VCS\appsvdoc.h $
  13. *
  14. * Rev 1.20 14 Feb 1998 11:23:22 donm
  15. * fixed memory leak by avoiding CDocManager::OpenDocumentFile
  16. *
  17. * Rev 1.19 10 Dec 1997 15:59:16 donm
  18. * added ability to have extension DLLs
  19. *
  20. * Rev 1.18 25 Mar 1997 08:59:50 butchd
  21. * update
  22. *
  23. * Rev 1.17 10 Mar 1997 16:58:30 butchd
  24. * update
  25. *
  26. * Rev 1.16 24 Sep 1996 16:21:22 butchd
  27. * update
  28. *
  29. *******************************************************************************/
  30. ////////////////////////////////////////////////////////////////////////////////
  31. // CWinStationListObjectHint class
  32. //
  33. class CWinStationListObjectHint : public CObject
  34. {
  35. DECLARE_DYNAMIC(CWinStationListObjectHint)
  36. /*
  37. * Member variables.
  38. */
  39. public:
  40. int m_WSLIndex;
  41. PWSLOBJECT m_pWSLObject;
  42. /*
  43. * Implementation.
  44. */
  45. public:
  46. CWinStationListObjectHint();
  47. }; // end CWinStationListObjectHint class interface
  48. ////////////////////////////////////////////////////////////////////////////////
  49. ////////////////////////////////////////////////////////////////////////////////
  50. // CAppServerDoc class
  51. //
  52. class CAppServerDoc : public CDocument
  53. {
  54. DECLARE_SERIAL(CAppServerDoc)
  55. /*
  56. * Member variables.
  57. */
  58. public:
  59. BOOL m_bAdmin;
  60. protected:
  61. BOOL m_bReadOnly;
  62. CObList m_WinStationList;
  63. PSECURITY_DESCRIPTOR m_pSecurityDescriptor;
  64. /*
  65. * Implementation
  66. */
  67. protected:
  68. CAppServerDoc();
  69. virtual ~CAppServerDoc();
  70. /*
  71. * Overrides of MFC CDocument class
  72. */
  73. protected:
  74. BOOL OnNewDocument();
  75. void SetTitle( LPCTSTR lpszTitle );
  76. /*
  77. * Operations
  78. */
  79. public:
  80. BOOL IsExitAllowed();
  81. BOOL IsAddAllowed(int nIndex);
  82. BOOL IsCopyAllowed(int nIndex);
  83. BOOL IsRenameAllowed(int nIndex);
  84. BOOL IsEditAllowed(int nIndex);
  85. BOOL IsDeleteAllowed(int nIndex);
  86. BOOL IsEnableAllowed( int nIndex, BOOL bEnable );
  87. int GetWSLCount();
  88. PWSLOBJECT GetWSLObject(int nIndex);
  89. int GetWSLIndex(PWINSTATIONNAME pWSName);
  90. PWSLOBJECT GetWSLObjectNetworkMatch( PDNAME PdName,
  91. WDNAME WdName,
  92. ULONG LanAdapter );
  93. BOOL IsAsyncDeviceAvailable( LPCTSTR pDeviceName,
  94. PWINSTATIONNAME pWSName );
  95. BOOL IsOemTdDeviceAvailable( LPCTSTR pDeviceName,
  96. PPDNAME pPdName,
  97. PWINSTATIONNAME pWSName );
  98. BOOL IsWSNameUnique( PWINSTATIONNAME pWinStationName );
  99. int AddWinStation(int WSLIndex);
  100. int CopyWinStation(int WSLIndex);
  101. int RenameWinStation(int WSLIndex);
  102. int EditWinStation(int WSLIndex);
  103. BOOL DeleteWinStation(int WSLIndex);
  104. void EnableWinStation( int WSLIndex, BOOL bEnable );
  105. void SecurityPermissions(int WSLIndex);
  106. protected:
  107. BOOL LoadWSL(LPCTSTR pszAppServer);
  108. BOOL RefreshWSLObjectState( int nIndex, PWSLOBJECT pWSLObject );
  109. void DeleteWSLContents();
  110. int InsertInWSL( PWINSTATIONNAME pWSName,
  111. PWINSTATIONCONFIG2 pWSConfig,
  112. void *pExtObject,
  113. PWSLOBJECT * ppObject );
  114. void RemoveFromWSL(int nIndex);
  115. void UpdateAllViewsWithItem( CView* pSourceView, UINT nItemIndex,
  116. PWSLOBJECT pWSLObject );
  117. void InUseMessage(PWINSTATIONNAME pWSName);
  118. BOOL HasWSConfigChanged( PWINSTATIONCONFIG2 pOriginalWSConfig,
  119. PWINSTATIONCONFIG2 pNewWSConfig,
  120. void *pOldExtObject,
  121. void *pNewExtObject,
  122. PWDNAME pWdName);
  123. BOOL HasPDConfigChanged( PWINSTATIONCONFIG2 pOriginalWSConfig,
  124. PWINSTATIONCONFIG2 pNewWSConfig );
  125. BOOL HasExtensionObjectChanged( PWDNAME pWdName,
  126. void *pOldExtObject,
  127. void *pNewExtObject);
  128. void DeleteExtensionObject( void *, PWDNAME pWdName);
  129. LONG RegistryQuery( PWINSTATIONNAME pWinStationName,
  130. PWINSTATIONCONFIG2 pWsConfig, PWDNAME pWdName,
  131. void **pExtObject);
  132. LONG RegistryCreate(PWINSTATIONNAME pWinStationName, BOOLEAN bCreate,
  133. PWINSTATIONCONFIG2 pWsConfig, PWDNAME pWdName,
  134. void *pExtObject);
  135. LONG RegistryDelete(PWINSTATIONNAME pWinStationName, PWDNAME pWdName,
  136. void *pExtObject);
  137. /*
  138. * Message map / commands.
  139. */
  140. protected:
  141. //{{AFX_MSG(CAppServerDoc)
  142. //}}AFX_MSG
  143. DECLARE_MESSAGE_MAP()
  144. }; // end CAppServerDoc class interface
  145. ////////////////////////////////////////////////////////////////////////////////