ReactOS 0.4.15-dev-8428-g6910fa6
shfldr_netconnect.h
Go to the documentation of this file.
1
2
3typedef struct {
6 int fmt;
7 int cxChar;
9
11 public CComCoClass<CNetworkConnections, &CLSID_ConnectionFolder>,
12 public CComObjectRootEx<CComMultiThreadModelNoCS>,
13 public IPersistFolder2,
14 public IShellExtInit,
15 public IShellFolder2,
16 public IOleCommandTarget,
17 public IShellFolderViewCB,
19{
20 public:
23
24 // IPersistFolder2
25 STDMETHOD(GetClassID)(CLSID *lpClassId) override;
28
29 // IShellFolder
30 STDMETHOD(ParseDisplayName)(HWND hwndOwner, LPBC pbc, LPOLESTR lpszDisplayName, DWORD *pchEaten, PIDLIST_RELATIVE *ppidl, DWORD *pdwAttributes) override;
31 STDMETHOD(EnumObjects)(HWND hwndOwner, DWORD dwFlags, LPENUMIDLIST *ppEnumIDList) override;
32 STDMETHOD(BindToObject)(PCUIDLIST_RELATIVE pidl, LPBC pbcReserved, REFIID riid, LPVOID *ppvOut) override;
33 STDMETHOD(BindToStorage)(PCUIDLIST_RELATIVE pidl, LPBC pbcReserved, REFIID riid, LPVOID *ppvOut) override;
35 STDMETHOD(CreateViewObject)(HWND hwndOwner, REFIID riid, LPVOID *ppvOut) override;
36 STDMETHOD(GetAttributesOf)(UINT cidl, PCUITEMID_CHILD_ARRAY apidl, DWORD *rgfInOut) override;
37 STDMETHOD(GetUIObjectOf)(HWND hwndOwner, UINT cidl, PCUITEMID_CHILD_ARRAY apidl, REFIID riid, UINT * prgfInOut, LPVOID * ppvOut) override;
39 STDMETHOD(SetNameOf)(HWND hwndOwner, PCUITEMID_CHILD pidl, LPCOLESTR lpName, DWORD dwFlags, PITEMID_CHILD *pPidlOut) override;
40
41 // IShellFolder2
42 STDMETHOD(GetDefaultSearchGUID)(GUID *pguid) override;
43 STDMETHOD(EnumSearches)(IEnumExtraSearch **ppenum) override;
44 STDMETHOD(GetDefaultColumn)(DWORD dwRes, ULONG *pSort, ULONG *pDisplay) override;
45 STDMETHOD(GetDefaultColumnState)(UINT iColumn, DWORD *pcsFlags) override;
46 STDMETHOD(GetDetailsEx)(PCUITEMID_CHILD pidl, const SHCOLUMNID *pscid, VARIANT *pv) override;
47 STDMETHOD(GetDetailsOf)(PCUITEMID_CHILD pidl, UINT iColumn, SHELLDETAILS *psd) override;
49
50 // IShellExtInit
51 STDMETHOD(Initialize)(PCIDLIST_ABSOLUTE pidlFolder, IDataObject *pdtobj, HKEY hkeyProgID) override;
52
53 // IOleCommandTarget
54 STDMETHOD(Exec)(const GUID *pguidCmdGroup, DWORD nCmdID, DWORD nCmdexecopt, VARIANT *pvaIn, VARIANT *pvaOut) override;
55 STDMETHOD(QueryStatus)(const GUID *pguidCmdGroup, ULONG cCmds, OLECMD prgCmds[], OLECMDTEXT *pCmdText) override;
56
57 // IShellFolderViewCB
59
60 // IShellExecuteHookW
62
63 private:
64
65 /* both paths are parsible from the desktop */
67 CComPtr<IOleCommandTarget> m_lpOleCmd;
68
69 public:
70
73 COM_INTERFACE_ENTRY_IID(IID_IPersistFolder, IPersistFolder2)
74 COM_INTERFACE_ENTRY_IID(IID_IPersistFolder2, IPersistFolder2)
75 COM_INTERFACE_ENTRY_IID(IID_IShellFolder, IShellFolder2)
76 COM_INTERFACE_ENTRY_IID(IID_IShellFolder2, IShellFolder2)
77 COM_INTERFACE_ENTRY_IID(IID_IShellExtInit, IShellExtInit)
78 COM_INTERFACE_ENTRY_IID(IID_IOleCommandTarget, IOleCommandTarget)
79 COM_INTERFACE_ENTRY_IID(IID_IShellFolderViewCB, IShellFolderViewCB)
80 COM_INTERFACE_ENTRY_IID(IID_IShellExecuteHookW, IShellExecuteHookW)
82
86};
87
89 public CComObjectRootEx<CComMultiThreadModelNoCS>,
90 public IContextMenu3,
91 public IObjectWithSite,
92 public IQueryInfo,
93 public IExtractIconW
94{
95 private:
97 CComPtr<IUnknown> m_pUnknown;
98 CComPtr<IOleCommandTarget> m_lpOleCmd;
99
100 public:
104
105 // IContextMenu3
106 STDMETHOD(QueryContextMenu)(HMENU hmenu, UINT indexMenu, UINT idCmdFirst, UINT idCmdLast, UINT uFlags) override;
107 STDMETHOD(InvokeCommand)(LPCMINVOKECOMMANDINFO lpici) override;
108 STDMETHOD(GetCommandString)(UINT_PTR idCmd, UINT uType, UINT *pwReserved, LPSTR pszName, UINT cchMax) override;
109 STDMETHOD(HandleMenuMsg)( UINT uMsg, WPARAM wParam, LPARAM lParam) override;
110 STDMETHOD(HandleMenuMsg2)(UINT uMsg, WPARAM wParam, LPARAM lParam, LRESULT *plResult) override;
111
112 // IObjectWithSite
113 STDMETHOD(SetSite)(IUnknown *punk) override;
114 STDMETHOD(GetSite)(REFIID iid, void **ppvSite) override;
115
116 // IQueryInfo
117 STDMETHOD(GetInfoFlags)(DWORD *pdwFlags) override;
118 STDMETHOD(GetInfoTip)(DWORD dwFlags, WCHAR **ppwszTip) override;
119
120 // IExtractIconW
121 STDMETHOD(GetIconLocation)(UINT uFlags, LPWSTR szIconFile, UINT cchMax, int *piIndex, UINT *pwFlags) override;
122 STDMETHOD(Extract)(LPCWSTR pszFile, UINT nIconIndex, HICON *phiconLarge, HICON *phiconSmall, UINT nIconSize) override;
123
125 COM_INTERFACE_ENTRY_IID(IID_IContextMenu, IContextMenu3)
126 COM_INTERFACE_ENTRY_IID(IID_IContextMenu2, IContextMenu3)
127 COM_INTERFACE_ENTRY_IID(IID_IContextMenu3, IContextMenu3)
129 COM_INTERFACE_ENTRY_IID(IID_IQueryInfo, IQueryInfo)
130 COM_INTERFACE_ENTRY_IID(IID_IExtractIconW, IExtractIconW)
132
135};
136
UINT cchMax
const WCHAR * class
Definition: main.c:68
#define STDMETHOD(m)
Definition: basetyps.h:62
HRESULT WINAPI GetInfoTip(IUnknown *param8, long paramC, LPTSTR *param10, long cchMax)
HRESULT WINAPI Extract(SESSION *dest, LPCSTR szCabName)
Definition: cabinet_main.c:328
PCUITEMID_CHILD m_pidl
CComPtr< IOleCommandTarget > m_lpOleCmd
CComPtr< IUnknown > m_pUnknown
STDMETHOD() BindToStorage(PCUIDLIST_RELATIVE pidl, LPBC pbcReserved, REFIID riid, LPVOID *ppvOut) override
STDMETHOD() Exec(const GUID *pguidCmdGroup, DWORD nCmdID, DWORD nCmdexecopt, VARIANT *pvaIn, VARIANT *pvaOut) override
STDMETHOD() CreateViewObject(HWND hwndOwner, REFIID riid, LPVOID *ppvOut) override
STDMETHOD() GetAttributesOf(UINT cidl, PCUITEMID_CHILD_ARRAY apidl, DWORD *rgfInOut) override
STDMETHOD() GetDetailsEx(PCUITEMID_CHILD pidl, const SHCOLUMNID *pscid, VARIANT *pv) override
STDMETHOD() QueryStatus(const GUID *pguidCmdGroup, ULONG cCmds, OLECMD prgCmds[], OLECMDTEXT *pCmdText) override
STDMETHOD() GetDefaultColumn(DWORD dwRes, ULONG *pSort, ULONG *pDisplay) override
STDMETHOD() GetCurFolder(PIDLIST_ABSOLUTE *pidl) override
STDMETHOD() GetDefaultSearchGUID(GUID *pguid) override
STDMETHOD() GetClassID(CLSID *lpClassId) override
STDMETHOD() GetDisplayNameOf(PCUITEMID_CHILD pidl, DWORD dwFlags, LPSTRRET strRet) override
PIDLIST_ABSOLUTE m_pidlRoot
STDMETHOD() CompareIDs(LPARAM lParam, PCUIDLIST_RELATIVE pidl1, PCUIDLIST_RELATIVE pidl2) override
CComPtr< IOleCommandTarget > m_lpOleCmd
STDMETHOD() GetDetailsOf(PCUITEMID_CHILD pidl, UINT iColumn, SHELLDETAILS *psd) override
STDMETHOD() SetNameOf(HWND hwndOwner, PCUITEMID_CHILD pidl, LPCOLESTR lpName, DWORD dwFlags, PITEMID_CHILD *pPidlOut) override
STDMETHOD() BindToObject(PCUIDLIST_RELATIVE pidl, LPBC pbcReserved, REFIID riid, LPVOID *ppvOut) override
STDMETHOD() EnumObjects(HWND hwndOwner, DWORD dwFlags, LPENUMIDLIST *ppEnumIDList) override
STDMETHOD() GetDefaultColumnState(UINT iColumn, DWORD *pcsFlags) override
STDMETHOD() Execute(LPSHELLEXECUTEINFOW pei) override
STDMETHOD() MessageSFVCB(UINT uMsg, WPARAM wParam, LPARAM lParam) override
STDMETHOD() MapColumnToSCID(UINT column, SHCOLUMNID *pscid) override
STDMETHOD() EnumSearches(IEnumExtraSearch **ppenum) override
STDMETHOD() GetUIObjectOf(HWND hwndOwner, UINT cidl, PCUITEMID_CHILD_ARRAY apidl, REFIID riid, UINT *prgfInOut, LPVOID *ppvOut) override
WPARAM wParam
Definition: combotst.c:138
LPARAM lParam
Definition: combotst.c:139
UINT uFlags
Definition: api.c:59
unsigned long DWORD
Definition: ntddk_ex.h:95
REFIID riid
Definition: atlbase.h:39
#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
#define DECLARE_NO_REGISTRY()
Definition: atlcom.h:639
static HICON
Definition: imagelist.c:84
const IID IID_IObjectWithSite
static IParseDisplayName ParseDisplayName
Definition: moniker.c:816
static LPOLESTR
Definition: stg_prop.c:27
static const CLSID *static CLSID *static const GUID VARIANT VARIANT *static IServiceProvider DWORD *static HMENU
Definition: ordinal.c:63
unsigned __int3264 UINT_PTR
Definition: mstsclib_h.h:274
unsigned int UINT
Definition: ndis.h:50
interface IBindCtx * LPBC
Definition: objfwd.h:18
const GUID IID_IPersist
Definition: proxy.cpp:14
#define REFIID
Definition: guiddef.h:118
HRESULT ShowNetConnectionProperties(INetConnection *pNetConnect, HWND hwnd)
static HRESULT GetCommandString(IContextMenu &CM, UINT Id, UINT Type, LPWSTR buf, UINT cchMax)
Definition: shlextdbg.cpp:175
const PCUITEMID_CHILD * PCUITEMID_CHILD_ARRAY
Definition: shtypes.idl:71
const ITEMID_CHILD UNALIGNED * PCUITEMID_CHILD
Definition: shtypes.idl:70
const ITEMIDLIST_RELATIVE UNALIGNED * PCUIDLIST_RELATIVE
Definition: shtypes.idl:57
uint32_t ULONG
Definition: typedefs.h:59
static HMENU hmenu
Definition: win.c:66
_In_ LPCSTR lpName
Definition: winbase.h:2789
_In_ PCCERT_CONTEXT _In_ DWORD dwFlags
Definition: wincrypt.h:1176
_In_ LONG _In_ HWND hwnd
Definition: winddi.h:4023
LONG_PTR LPARAM
Definition: windef.h:208
LONG_PTR LRESULT
Definition: windef.h:209
UINT_PTR WPARAM
Definition: windef.h:207
#define WINAPI
Definition: msvc.h:6
static void Initialize()
Definition: xlate.c:212
char * LPSTR
Definition: xmlstorage.h:182
__wchar_t WCHAR
Definition: xmlstorage.h:180
WCHAR * LPWSTR
Definition: xmlstorage.h:184
const WCHAR * LPCWSTR
Definition: xmlstorage.h:185