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.

81 lines
2.4 KiB

  1. //==============================================================;
  2. //
  3. // This source code is only intended as a supplement to
  4. // existing Microsoft documentation.
  5. //
  6. //
  7. //
  8. //
  9. // THIS CODE AND INFORMATION IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY
  10. // KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
  11. // IMPLIED WARRANTIES OF MERCHANTABILITY AND/OR FITNESS FOR A PARTICULAR
  12. // PURPOSE.
  13. //
  14. // Copyright (C) 1999 Microsoft Corporation. All Rights Reserved.
  15. //
  16. //
  17. //
  18. //==============================================================;
  19. #ifndef _SKY_H
  20. #define _SKY_H
  21. #include "DeleBase.h"
  22. class CPlane : public CDelegationBase {
  23. public:
  24. CPlane(_TCHAR *szName, int id, LONG lWeight, LONG lHeight, LONG lPayload);
  25. virtual ~CPlane();
  26. virtual const _TCHAR *GetDisplayName(int nCol = 0);
  27. virtual const GUID & getNodeType() { return thisGuid; }
  28. virtual const int GetBitmapIndex() { return INDEX_SKYICON; }
  29. public:
  30. // virtual functions go here (for MMCN_*)
  31. virtual HRESULT OnAddMenuItems(IContextMenuCallback *pContextMenuCallback, long *pInsertionsAllowed);
  32. virtual HRESULT OnMenuCommand(IConsole *pConsole, long lCommandID);
  33. private:
  34. // {2AF5EBCF-6ADC-11d3-9155-00C04F65B3F9}
  35. static const GUID thisGuid;
  36. _TCHAR *szName;
  37. LONG lWeight;
  38. LONG lHeight;
  39. LONG lPayload;
  40. int nId;
  41. enum {RUNNING, PAUSED, STOPPED} iStatus;
  42. enum { IDM_START_SKY = 100, IDM_PAUSE_SKY, IDM_STOP_SKY };
  43. };
  44. class CSkyVehicle : public CDelegationBase {
  45. public:
  46. CSkyVehicle(int i);
  47. virtual ~CSkyVehicle() {}
  48. // virtual functions go here (for MMCN_*)
  49. virtual HRESULT OnShow(IConsole *pConsole, BOOL bShow, HSCOPEITEM scopeitem);
  50. virtual HRESULT OnAddMenuItems(IContextMenuCallback *pContextMenuCallback, long *pInsertionsAllowed);
  51. virtual HRESULT OnMenuCommand(IConsole *pConsole, long lCommandID);
  52. virtual const _TCHAR *GetDisplayName(int nCol = 0);
  53. virtual const GUID & getNodeType() { return thisGuid; }
  54. virtual const int GetBitmapIndex() { return INDEX_SKYICON; }
  55. private:
  56. enum { IDM_NEW_SKY = 2 };
  57. // {BD518283-6A2E-11d3-9154-00C04F65B3F9}
  58. static const GUID thisGuid;
  59. enum { NUMBER_OF_CHILDREN = 4 };
  60. CPlane *children[NUMBER_OF_CHILDREN];
  61. int id;
  62. };
  63. #endif // _SKY_H