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.

65 lines
2.2 KiB

  1. //
  2. // Microsoft Corporation 1998
  3. //
  4. // SNAPIN.H - SnapIn class
  5. //
  6. class CSnapIn:
  7. public IComponent,
  8. public IExtendPropertySheet
  9. {
  10. protected:
  11. ULONG m_cRef;
  12. LPCONSOLE m_pConsole; // Console's IFrame interface
  13. CComponentData *m_pcd;
  14. LPRESULTDATA m_pResult; // Result pane's interface
  15. LPHEADERCTRL m_pHeader; // Result pane's header control interface
  16. LPIMAGELIST m_pImageResult; // Result pane's image list interface
  17. LPCONSOLEVERB m_pConsoleVerb; // pointer the console verb
  18. WCHAR m_column1[20]; // Text for column 1
  19. INT m_nColumnSize; // Size of column 1
  20. LONG m_lViewMode; // View mode
  21. static unsigned int m_cfNodeType;
  22. static TCHAR m_szDefaultIcon[];
  23. public:
  24. CSnapIn(CComponentData *pComponent);
  25. ~CSnapIn();
  26. //
  27. // IUnknown methods
  28. //
  29. STDMETHODIMP QueryInterface(REFIID, LPVOID FAR *);
  30. STDMETHODIMP_(ULONG) AddRef();
  31. STDMETHODIMP_(ULONG) Release();
  32. //
  33. // Implemented IComponent methods
  34. //
  35. STDMETHODIMP Initialize(LPCONSOLE);
  36. STDMETHODIMP Destroy(MMC_COOKIE);
  37. STDMETHODIMP Notify(LPDATAOBJECT, MMC_NOTIFY_TYPE, LPARAM, LPARAM);
  38. STDMETHODIMP QueryDataObject(MMC_COOKIE, DATA_OBJECT_TYPES, LPDATAOBJECT *);
  39. STDMETHODIMP GetDisplayInfo(LPRESULTDATAITEM);
  40. STDMETHODIMP GetResultViewType(MMC_COOKIE, LPOLESTR*, LONG*);
  41. STDMETHODIMP CompareObjects(LPDATAOBJECT, LPDATAOBJECT);
  42. //
  43. // Implemented IExtendPropertySheet methods
  44. //
  45. STDMETHODIMP CreatePropertyPages(LPPROPERTYSHEETCALLBACK lpProvider,
  46. LONG_PTR handle, LPDATAOBJECT lpDataObject);
  47. STDMETHODIMP QueryPagesFor(LPDATAOBJECT lpDataObject);
  48. private:
  49. static INT_PTR CALLBACK ChoiceDlgProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam);
  50. static INT_PTR CALLBACK ReadmeDlgProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam);
  51. INT_PTR CALLBACK _CreateDirectoryIfNeeded( LPOLESTR pszPath );
  52. };