ReactOS 0.4.15-dev-8241-g63935f8
CFolder.h
Go to the documentation of this file.
1/*
2 * PROJECT: shell32
3 * LICENSE: LGPL-2.1+ (https://spdx.org/licenses/LGPL-2.1+)
4 * PURPOSE: Folder implementation
5 * COPYRIGHT: Copyright 2015-2018 Mark Jansen (mark.jansen@reactos.org)
6 */
7
8#ifndef _FOLDER_H_
9#define _FOLDER_H_
10
11
12class CFolder:
13 public CComCoClass<CFolder>,
14 public CComObjectRootEx<CComMultiThreadModelNoCS>,
15 public IDispatchImpl<Folder2, &IID_Folder2>
16{
17private:
18 HRESULT GetShellFolder(CComPtr<IShellFolder>& psfCurrent);
19
20 CComHeapPtr<ITEMIDLIST> m_idlist;
21 CComPtr<IShellDispatch> m_Application;
22
23public:
24 CFolder();
25 ~CFolder();
26
28
29 // *** Folder methods ***
30 STDMETHOD(get_Title)(BSTR *pbs) override;
31 STDMETHOD(get_Application)(IDispatch **ppid) override;
32 STDMETHOD(get_Parent)(IDispatch **ppid) override;
33 STDMETHOD(get_ParentFolder)(Folder **ppsf) override;
34 STDMETHOD(Items)(FolderItems **ppid) override;
35 STDMETHOD(ParseName)(BSTR bName, FolderItem **ppid) override;
36 STDMETHOD(NewFolder)(BSTR bName, VARIANT vOptions) override;
37 STDMETHOD(MoveHere)(VARIANT vItem, VARIANT vOptions) override;
38 STDMETHOD(CopyHere)(VARIANT vItem, VARIANT vOptions) override;
39 STDMETHOD(GetDetailsOf)(VARIANT vItem, int iColumn, BSTR *pbs) override;
40
41 // *** Folder2 methods ***
42 STDMETHOD(get_Self)(FolderItem **ppfi) override;
43 STDMETHOD(get_OfflineStatus)(LONG *pul) override;
44 STDMETHOD(Synchronize)() override;
45 STDMETHOD(get_HaveToShowWebViewBarricade)(VARIANT_BOOL *pbHaveToShowWebViewBarricade) override;
47
50
52 COM_INTERFACE_ENTRY_IID(IID_Folder2, Folder2)
53 COM_INTERFACE_ENTRY_IID(IID_Folder, Folder)
56
57};
58
59
60#endif
#define STDMETHOD(m)
Definition: basetyps.h:62
~CFolder()
Definition: CFolder.cpp:17
CComHeapPtr< ITEMIDLIST > m_idlist
Definition: CFolder.h:20
STDMETHOD() MoveHere(VARIANT vItem, VARIANT vOptions) override
Definition: CFolder.cpp:120
STDMETHOD() Items(FolderItems **ppid) override
Definition: CFolder.cpp:85
STDMETHOD() CopyHere(VARIANT vItem, VARIANT vOptions) override
Definition: CFolder.cpp:126
STDMETHOD() ParseName(BSTR bName, FolderItem **ppid) override
Definition: CFolder.cpp:91
STDMETHOD() get_ParentFolder(Folder **ppsf) override
Definition: CFolder.cpp:76
STDMETHOD() NewFolder(BSTR bName, VARIANT vOptions) override
Definition: CFolder.cpp:114
CFolder()
Definition: CFolder.cpp:13
STDMETHOD() get_HaveToShowWebViewBarricade(VARIANT_BOOL *pbHaveToShowWebViewBarricade) override
Definition: CFolder.cpp:161
STDMETHOD() GetDetailsOf(VARIANT vItem, int iColumn, BSTR *pbs) override
Definition: CFolder.cpp:132
HRESULT GetShellFolder(CComPtr< IShellFolder > &psfCurrent)
Definition: CFolder.cpp:27
STDMETHOD() get_Parent(IDispatch **ppid) override
Definition: CFolder.cpp:66
STDMETHOD() get_Application(IDispatch **ppid) override
Definition: CFolder.cpp:53
CComPtr< IShellDispatch > m_Application
Definition: CFolder.h:21
STDMETHOD() get_OfflineStatus(LONG *pul) override
Definition: CFolder.cpp:149
STDMETHOD() Synchronize() override
Definition: CFolder.cpp:155
STDMETHOD() DismissedWebViewBarricade() override
Definition: CFolder.cpp:167
STDMETHOD() get_Self(FolderItem **ppfi) override
Definition: CFolder.cpp:140
STDMETHOD() get_Title(BSTR *pbs) override
Definition: CFolder.cpp:39
OLECHAR * BSTR
Definition: compat.h:2293
short VARIANT_BOOL
Definition: compat.h:2290
#define BEGIN_COM_MAP(x)
Definition: atlcom.h:581
#define COM_INTERFACE_ENTRY_IID(iid, x)
Definition: atlcom.h:601
#define DECLARE_PROTECT_FINAL_CONSTRUCT()
Definition: atlcom.h:679
#define DECLARE_NOT_AGGREGATABLE(x)
Definition: atlcom.h:651
#define END_COM_MAP()
Definition: atlcom.h:592
const GUID IID_IDispatch
long LONG
Definition: pedump.c:60
ITEMIDLIST UNALIGNED * LPITEMIDLIST
Definition: shtypes.idl:41
static void Initialize()
Definition: xlate.c:212