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.

145 lines
4.7 KiB

  1. /////////////////////////////////////////////////////////////////////////////
  2. // FILE : InboundRoutingMethod.h //
  3. // //
  4. // DESCRIPTION : Header file for the InboundRoutingMethod node class. //
  5. // //
  6. // AUTHOR : yossg //
  7. // //
  8. // HISTORY : //
  9. // Dec 01 1999 yossg Create //
  10. // Dec 14 1999 yossg add basic functionality, menu, changable icon //
  11. // //
  12. // Copyright (C) 1999 Microsoft Corporation All Rights Reserved //
  13. /////////////////////////////////////////////////////////////////////////////
  14. #ifndef H_FAXINBOUNDROUTINGMETHOD_H
  15. #define H_FAXINBOUNDROUTINGMETHOD_H
  16. #include "snapin.h"
  17. #include "snpnode.h"
  18. #include "Icons.h"
  19. #include "ppFaxInboundRoutingMethodGeneral.h"
  20. class CppFaxInboundRoutingMethod;
  21. class CFaxInboundRoutingMethodsNode;
  22. class CFaxInboundRoutingMethodNode : public CSnapinNode <CFaxInboundRoutingMethodNode, FALSE>
  23. {
  24. public:
  25. BEGIN_SNAPINCOMMAND_MAP(CFaxInboundRoutingMethodNode, FALSE)
  26. SNAPINCOMMAND_ENTRY(IDM_FAX_INMETHOD_ENABLE, OnMethodEnabled)
  27. SNAPINCOMMAND_ENTRY(IDM_FAX_INMETHOD_DISABLE, OnMethodEnabled)
  28. END_SNAPINCOMMAND_MAP()
  29. BEGIN_SNAPINTOOLBARID_MAP(CFaxInboundRoutingMethodNode)
  30. END_SNAPINTOOLBARID_MAP()
  31. SNAPINMENUID(IDR_INMETHOD_MENU)
  32. //
  33. // Constructor
  34. //
  35. CFaxInboundRoutingMethodNode (CSnapInItem * pParentNode, CSnapin * pComponentData, PFAX_ROUTING_METHOD pMethodConfig) :
  36. CSnapinNode<CFaxInboundRoutingMethodNode, FALSE>(pParentNode, pComponentData )
  37. {
  38. }
  39. //
  40. // Destructor
  41. //
  42. ~CFaxInboundRoutingMethodNode()
  43. {
  44. }
  45. LPOLESTR GetResultPaneColInfo(int nCol);
  46. void InitParentNode(CFaxInboundRoutingMethodsNode *pParentNode)
  47. {
  48. m_pParentNode = pParentNode;
  49. }
  50. STDMETHOD(CreatePropertyPages)(LPPROPERTYSHEETCALLBACK lpProvider,
  51. LONG_PTR handle,
  52. IUnknown* pUnk,
  53. DATA_OBJECT_TYPES type);
  54. STDMETHOD(QueryPagesFor)(DATA_OBJECT_TYPES type)
  55. {
  56. if (type == CCT_SCOPE || type == CCT_RESULT)
  57. return S_OK;
  58. return S_FALSE;
  59. }
  60. virtual HRESULT SetVerbs(IConsoleVerb *pConsoleVerb);
  61. CComBSTR GetName() { return m_bstrFriendlyName; }
  62. BOOL GetStatus() { return m_fEnabled; }
  63. CComBSTR GetExtensionName() { return m_bstrExtensionFriendlyName; }
  64. HRESULT Init(PFAX_ROUTING_METHOD pMethodConfig);
  65. void UpdateMenuState (UINT id, LPTSTR pBuf, UINT *flags);
  66. //
  67. // FillData
  68. //
  69. STDMETHOD (FillData)(CLIPFORMAT cf, LPSTREAM pStream);
  70. //
  71. // Clipboard Formats
  72. //
  73. static CLIPFORMAT m_CFExtensionName;
  74. static CLIPFORMAT m_CFMethodGuid;
  75. static CLIPFORMAT m_CFServerName;
  76. static CLIPFORMAT m_CFDeviceId;
  77. HRESULT OnShowContextHelp(
  78. IDisplayHelp* pDisplayHelp, LPOLESTR helpFile);
  79. private:
  80. //
  81. // Parent Node
  82. //
  83. CFaxInboundRoutingMethodsNode * m_pParentNode;
  84. //
  85. // Property Pages
  86. //
  87. CppFaxInboundRoutingMethod * m_pInboundRoutingMethodGeneral;
  88. //
  89. // members
  90. //
  91. CComBSTR m_bstrFriendlyName; //pointer to method's user-friendly name
  92. CComBSTR m_bstrExtensionFriendlyName; //pointer to DLL's user-friendly name
  93. DWORD m_dwDeviceID; //line identifier of the device
  94. BOOL m_fEnabled; //fax routing method enable/disable flag
  95. CComBSTR m_bstrMethodGUID; //GUID that uniquely identifies
  96. CComBSTR m_bstrExtensionImageName; //pointer to DLL that implements method
  97. // currently not in use
  98. //CComBSTR m_bstrDeviceName; //pointer to device name
  99. //CComBSTR m_bstrFunctionName; //pointer to method's function name
  100. //DWORD m_dwSizeOfStruct; //structure size, in bytes
  101. CComBSTR m_buf;
  102. //
  103. // Menu item handlers
  104. //
  105. HRESULT OnMethodEnabled (bool &bHandled, CSnapInObjectRootBase *pRoot);
  106. HRESULT ChangeEnable (BOOL fState);
  107. //
  108. // Init
  109. //
  110. HRESULT InitMembers (PFAX_ROUTING_METHOD pMethodConfig);
  111. };
  112. //typedef CSnapinNode<CFaxInboundRoutingMethodNode, FALSE> CBaseFaxInboundRoutingMethodNode;
  113. #endif //H_FAXINBOUNDROUTINGMETHOD_H