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.

106 lines
3.0 KiB

  1. //----------------------------------------------------------------------------
  2. //
  3. // Microsoft Windows
  4. // Copyright (C) Microsoft Corporation, 2001.
  5. //
  6. // File: Nfabpage.h
  7. //
  8. // Contents: Wireless Policy Snapin
  9. //
  10. //
  11. // History: TaroonM
  12. // 10/30/01
  13. //
  14. //----------------------------------------------------------------------------
  15. #ifndef _NFABPAGE_H
  16. #define _NFABPAGE_H
  17. // CWirelessBasePage.h : header file
  18. //
  19. class CWirelessBasePage : public CWiz97BasePage
  20. {
  21. DECLARE_DYNCREATE(CWirelessBasePage)
  22. CWirelessBasePage(UINT nIDTemplate, BOOL bWiz97=FALSE, BOOL bFinishPage=FALSE);
  23. CWirelessBasePage() {ASSERT(0);};
  24. ~CWirelessBasePage();
  25. void CWirelessBasePage::Initialize (PWIRELESS_PS_DATA pWirelessPSData, CComponentDataImpl* pComponentDataImpl);
  26. #ifdef WIZ97WIZARDS
  27. public:
  28. void InitWiz97 (CComObject<CSecPolItem> *pSecPolItem, PWIRELESS_PS_DATA pWirelessPSData, CComponentDataImpl* pComponentDataImpl, DWORD dwFlags, DWORD dwWizButtonFlags = 0, UINT nHeaderTitle = 0, UINT nSubTitle = 0);
  29. #endif
  30. // Overrides
  31. public:
  32. // ClassWizard generate virtual function overrides
  33. //{{AFX_VIRTUAL(CWirelessBasePage)
  34. public:
  35. protected:
  36. virtual BOOL OnSetActive();
  37. //}}AFX_VIRTUAL
  38. // There are paths we can use to get storage, sometimes we have an PS, sometimes we have a ComponentDataImpl
  39. // and sometimes we have both. It used to be that we called one of two functions to dig down to it, but now
  40. // we call one function and it does the digging for us
  41. HANDLE GetPolicyStoreHandle()
  42. {
  43. return(m_pComponentDataImpl->GetPolicyStoreHandle());
  44. }
  45. PWIRELESS_PS_DATA WirelessPS() {return m_pWirelessPSData;};
  46. // Implementation
  47. protected:
  48. //{{AFX_MSG(CWirelessBasePage)
  49. //}}AFX_MSG
  50. DECLARE_MESSAGE_MAP()
  51. PWIRELESS_PS_DATA m_pWirelessPSData;
  52. CComponentDataImpl* m_pComponentDataImpl;
  53. // !NULL if the owning (non-Wiz) propsheet was created to Add a new PS.
  54. // Its a new PS so its not owned by a policy yet. Otherwise this is
  55. // NULL since the PS's backpointer will be used to commit the owning
  56. // policy.
  57. PWIRELESS_POLICY_DATA m_pPolicyNfaOwner;
  58. };
  59. class CPSPropSheetManager : public CPropertySheetManager
  60. {
  61. public:
  62. CPSPropSheetManager() :
  63. CPropertySheetManager(),
  64. m_pWirelessPSData(NULL),
  65. m_bIsNew(FALSE)
  66. {}
  67. void SetData(
  68. CSecPolItem * pResultItem,
  69. PWIRELESS_PS_DATA pWirelessPSData,
  70. BOOL bIsNew
  71. )
  72. {
  73. m_pResultItem = pResultItem;
  74. m_pWirelessPSData = pWirelessPSData;
  75. m_bIsNew = bIsNew;
  76. }
  77. virtual BOOL OnApply();
  78. protected:
  79. CSecPolItem * m_pResultItem;
  80. PWIRELESS_PS_DATA m_pWirelessPSData;
  81. BOOL m_bIsNew;
  82. };
  83. const UINT c_nMaxSSIDLen = 32;
  84. const UINT c_nMaxDescriptionLen = 255;
  85. #endif