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.

72 lines
1.9 KiB

  1. //*******************************************************************************************
  2. //
  3. // Filename : Menu.h
  4. //
  5. // CCabItemMenu
  6. //
  7. // Copyright (c) 1994 - 1996 Microsoft Corporation. All rights reserved
  8. //
  9. //*******************************************************************************************
  10. #ifndef _MENU_H_
  11. #define _MENU_H_
  12. #include "folder.h"
  13. //*****************************************************************************
  14. //
  15. // CCabItemMenu
  16. //
  17. // Purpose:
  18. //
  19. // IContextMenu for the Shellfolder
  20. //
  21. //*****************************************************************************
  22. class CCabItemMenu : public IContextMenu
  23. {
  24. public:
  25. CCabItemMenu(HWND hwndOwner, CCabFolder*pcf, LPCABITEM *apit, UINT cpit);
  26. ~CCabItemMenu();
  27. // *** IUnknown methods ***
  28. STDMETHODIMP QueryInterface(REFIID riid, LPVOID * ppvObj);
  29. STDMETHODIMP_(ULONG) AddRef();
  30. STDMETHODIMP_(ULONG) Release();
  31. // *** IContextMenu methods ***
  32. STDMETHODIMP QueryContextMenu(
  33. HMENU hmenu,
  34. UINT indexMenu,
  35. UINT idCmdFirst,
  36. UINT idCmdLast,
  37. UINT uFlags);
  38. STDMETHODIMP InvokeCommand(
  39. LPCMINVOKECOMMANDINFO lpici);
  40. STDMETHODIMP GetCommandString(
  41. UINT_PTR idCmd,
  42. UINT uType,
  43. UINT * pwReserved,
  44. LPSTR pszName,
  45. UINT cchMax);
  46. private:
  47. static HMENU LoadPopupMenu(UINT id, UINT uSubMenu);
  48. static HGLOBAL * CALLBACK CCabItemMenu::ShouldExtract(LPCTSTR pszFile, DWORD dwSize,
  49. UINT date, UINT time, UINT attribs, LPARAM lParam);
  50. private:
  51. CRefCount m_cRef;
  52. CRefDll m_cRefDll;
  53. HWND m_hwndOwner;
  54. CCabFolder *m_pcfHere;
  55. CCabItemList m_lSel;
  56. } ;
  57. #endif // _MENU_H_