[PSDK]
[reactos.git] / reactos / dll / win32 / shell32 / CMenuBand.h
1
2 class CMenuBand :
3 public CComCoClass<CMenuBand, &CLSID_MenuBand>,
4 public CComObjectRootEx<CComMultiThreadModelNoCS>,
5 public IDeskBand,
6 public IObjectWithSite,
7 public IInputObject,
8 public IPersistStream,
9 public IOleCommandTarget,
10 public IServiceProvider,
11 public IMenuPopup,
12 public IMenuBand,
13 public IShellMenu2,
14 public IWinEventHandler,
15 public IShellMenuAcc
16 {
17 public :
18
19 // *** IDeskBand methods ***
20 virtual HRESULT STDMETHODCALLTYPE GetBandInfo(DWORD dwBandID, DWORD dwViewMode, DESKBANDINFO *pdbi);
21
22 // *** IDockingWindow methods ***
23 virtual HRESULT STDMETHODCALLTYPE ShowDW(BOOL fShow);
24 virtual HRESULT STDMETHODCALLTYPE CloseDW(DWORD dwReserved);
25 virtual HRESULT STDMETHODCALLTYPE ResizeBorderDW(LPCRECT prcBorder, IUnknown *punkToolbarSite, BOOL fReserved);
26
27 // *** IOleWindow methods ***
28 virtual HRESULT STDMETHODCALLTYPE GetWindow(HWND *phwnd);
29 virtual HRESULT STDMETHODCALLTYPE ContextSensitiveHelp(BOOL fEnterMode);
30
31 // *** IObjectWithSite methods ***
32 virtual HRESULT STDMETHODCALLTYPE SetSite(IUnknown *pUnkSite);
33 virtual HRESULT STDMETHODCALLTYPE GetSite(REFIID riid, PVOID *ppvSite);
34
35 // *** IInputObject methods ***
36 virtual HRESULT STDMETHODCALLTYPE UIActivateIO(BOOL fActivate, LPMSG lpMsg);
37 virtual HRESULT STDMETHODCALLTYPE HasFocusIO();
38 virtual HRESULT STDMETHODCALLTYPE TranslateAcceleratorIO(LPMSG lpMsg);
39
40 // *** IPersistStream methods ***
41 virtual HRESULT STDMETHODCALLTYPE IsDirty();
42 virtual HRESULT STDMETHODCALLTYPE Load(IStream *pStm);
43 virtual HRESULT STDMETHODCALLTYPE Save(IStream *pStm, BOOL fClearDirty);
44 virtual HRESULT STDMETHODCALLTYPE GetSizeMax(ULARGE_INTEGER *pcbSize);
45
46 // *** IPersist methods ***
47 virtual HRESULT STDMETHODCALLTYPE GetClassID(CLSID *pClassID);
48
49 // *** IOleCommandTarget methods ***
50 virtual HRESULT STDMETHODCALLTYPE QueryStatus(const GUID *pguidCmdGroup, ULONG cCmds, OLECMD prgCmds[ ], OLECMDTEXT *pCmdText);
51 virtual HRESULT STDMETHODCALLTYPE Exec(const GUID *pguidCmdGroup, DWORD nCmdID, DWORD nCmdexecopt, VARIANT *pvaIn, VARIANT *pvaOut);
52
53 // *** IServiceProvider methods ***
54 virtual HRESULT STDMETHODCALLTYPE QueryService(REFGUID guidService, REFIID riid, void **ppvObject);
55
56 // *** IMenuPopup methods ***
57 virtual HRESULT STDMETHODCALLTYPE Popup(POINTL *ppt, RECTL *prcExclude, MP_POPUPFLAGS dwFlags);
58 virtual HRESULT STDMETHODCALLTYPE OnSelect(DWORD dwSelectType);
59 virtual HRESULT STDMETHODCALLTYPE SetSubMenu(IMenuPopup *pmp, BOOL fSet);
60
61 // *** IDeskBar methods ***
62 virtual HRESULT STDMETHODCALLTYPE SetClient(IUnknown *punkClient);
63 virtual HRESULT STDMETHODCALLTYPE GetClient(IUnknown **ppunkClient);
64 virtual HRESULT STDMETHODCALLTYPE OnPosRectChangeDB(RECT *prc);
65
66 // *** IMenuBand methods ***
67 virtual HRESULT STDMETHODCALLTYPE IsMenuMessage(MSG *pmsg);
68 virtual HRESULT STDMETHODCALLTYPE TranslateMenuMessage(MSG *pmsg, LRESULT *plRet);
69
70 // *** IShellMenu methods ***
71 virtual HRESULT STDMETHODCALLTYPE Initialize(IShellMenuCallback *psmc, UINT uId, UINT uIdAncestor,DWORD dwFlags);
72 virtual HRESULT STDMETHODCALLTYPE GetMenuInfo(IShellMenuCallback **ppsmc, UINT *puId, UINT *puIdAncestor, DWORD *pdwFlags);
73 virtual HRESULT STDMETHODCALLTYPE SetShellFolder(IShellFolder *psf, LPCITEMIDLIST pidlFolder, HKEY hKey, DWORD dwFlags);
74 virtual HRESULT STDMETHODCALLTYPE GetShellFolder(DWORD *pdwFlags, LPITEMIDLIST *ppidl, REFIID riid, void **ppv);
75 virtual HRESULT STDMETHODCALLTYPE SetMenu(HMENU hmenu, HWND hwnd, DWORD dwFlags);
76 virtual HRESULT STDMETHODCALLTYPE GetMenu(HMENU *phmenu, HWND *phwnd, DWORD *pdwFlags);
77 virtual HRESULT STDMETHODCALLTYPE InvalidateItem(LPSMDATA psmd, DWORD dwFlags);
78 virtual HRESULT STDMETHODCALLTYPE GetState(LPSMDATA psmd);
79 virtual HRESULT STDMETHODCALLTYPE SetMenuToolbar(IUnknown *punk, DWORD dwFlags);
80
81 // *** IWinEventHandler methods ***
82 virtual HRESULT STDMETHODCALLTYPE OnWinEvent(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam, LRESULT *theResult);
83 virtual HRESULT STDMETHODCALLTYPE IsWindowOwner(HWND hWnd);
84
85 // *** IShellMenu2 methods ***
86 virtual HRESULT STDMETHODCALLTYPE GetSubMenu(THIS);
87 virtual HRESULT STDMETHODCALLTYPE SetToolbar(THIS);
88 virtual HRESULT STDMETHODCALLTYPE SetMinWidth(THIS);
89 virtual HRESULT STDMETHODCALLTYPE SetNoBorder(THIS);
90 virtual HRESULT STDMETHODCALLTYPE SetTheme(THIS);
91
92 // *** IShellMenuAcc methods ***
93 virtual HRESULT STDMETHODCALLTYPE GetTop(THIS);
94 virtual HRESULT STDMETHODCALLTYPE GetBottom(THIS);
95 virtual HRESULT STDMETHODCALLTYPE GetTracked(THIS);
96 virtual HRESULT STDMETHODCALLTYPE GetParentSite(THIS);
97 virtual HRESULT STDMETHODCALLTYPE GetState(THIS);
98 virtual HRESULT STDMETHODCALLTYPE DoDefaultAction(THIS);
99 virtual HRESULT STDMETHODCALLTYPE IsEmpty(THIS);
100
101 DECLARE_REGISTRY_RESOURCEID(IDR_MENUBAND)
102 DECLARE_NOT_AGGREGATABLE(CMenuBand)
103 DECLARE_PROTECT_FINAL_CONSTRUCT()
104
105 BEGIN_COM_MAP(CMenuBand)
106 COM_INTERFACE_ENTRY_IID(IID_IMenuPopup, IMenuPopup)
107 COM_INTERFACE_ENTRY_IID(IID_IMenuBand, IMenuBand)
108 COM_INTERFACE_ENTRY_IID(IID_IShellMenu, IShellMenu)
109 COM_INTERFACE_ENTRY_IID(IID_IOleCommandTarget, IOleCommandTarget)
110 COM_INTERFACE_ENTRY_IID(IID_IOleWindow, IDeskBand)
111 COM_INTERFACE_ENTRY_IID(IID_IDockingWindow, IDockingWindow)
112 COM_INTERFACE_ENTRY_IID(IID_IDeskBar, IDeskBar)
113 COM_INTERFACE_ENTRY_IID(IID_IDeskBand, IDeskBand)
114 COM_INTERFACE_ENTRY_IID(IID_IObjectWithSite, IObjectWithSite)
115 COM_INTERFACE_ENTRY_IID(IID_IInputObject, IInputObject)
116 COM_INTERFACE_ENTRY_IID(IID_IPersistStream, IPersistStream)
117 COM_INTERFACE_ENTRY_IID(IID_IPersist, IPersist)
118 COM_INTERFACE_ENTRY_IID(IID_IServiceProvider, IServiceProvider)
119 COM_INTERFACE_ENTRY_IID(IID_IMenuBand, IMenuBand)
120 COM_INTERFACE_ENTRY_IID(IID_IShellMenu2, IShellMenu2)
121 COM_INTERFACE_ENTRY_IID(IID_IWinEventHandler, IWinEventHandler)
122 COM_INTERFACE_ENTRY_IID(IID_IShellMenuAcc, IShellMenuAcc)
123 END_COM_MAP()
124
125 };