ReactOS 0.4.15-dev-7942-gd23573b
PIDList Struct Reference

list of PIDLs More...

#include <shellclasses.h>

Collaboration diagram for PIDList:

Public Member Functions

 PIDList ()
 
 ~PIDList ()
 
HRESULT GetData (IDataObject *selection)
 
 operator LPIDA ()
 

Protected Attributes

STGMEDIUM _stgm
 
LPIDA _pIDList
 

Detailed Description

list of PIDLs

Definition at line 1057 of file shellclasses.h.

Constructor & Destructor Documentation

◆ PIDList()

PIDList::PIDList ( )
inline

Definition at line 1059 of file shellclasses.h.

1060 {
1061 memset(&_stgm, 0, sizeof(STGMEDIUM));
1062 }
#define memset(x, y, z)
Definition: compat.h:39
STGMEDIUM _stgm

◆ ~PIDList()

PIDList::~PIDList ( )
inline

Definition at line 1064 of file shellclasses.h.

1065 {
1066 if (_stgm.hGlobal) {
1067 GlobalUnlock(_stgm.hGlobal);
1069 }
1070 }
void WINAPI ReleaseStgMedium(STGMEDIUM *pmedium)
Definition: ole2.c:2033
BOOL NTAPI GlobalUnlock(HGLOBAL hMem)
Definition: heapmem.c:1190

Member Function Documentation

◆ GetData()

HRESULT PIDList::GetData ( IDataObject selection)
inline

Definition at line 1072 of file shellclasses.h.

1073 {
1075
1076 FORMATETC fetc;
1077 fetc.cfFormat = CF_IDLIST;
1078 fetc.ptd = NULL;
1079 fetc.dwAspect = DVASPECT_CONTENT;
1080 fetc.lindex = -1;
1081 fetc.tymed = TYMED_HGLOBAL;
1082
1083 HRESULT hr = selection->QueryGetData(&fetc);
1084 if (FAILED(hr))
1085 return hr;
1086
1087 hr = selection->GetData(&fetc, &_stgm);
1088 if (FAILED(hr))
1089 return hr;
1090
1091 _pIDList = (LPIDA)GlobalLock(_stgm.hGlobal);
1092
1093 return hr;
1094 }
int selection
Definition: ctm.c:92
#define NULL
Definition: types.h:112
LPVOID NTAPI GlobalLock(HGLOBAL hMem)
Definition: heapmem.c:755
#define FAILED(hr)
Definition: intsafe.h:51
unsigned int UINT
Definition: ndis.h:50
HRESULT hr
Definition: shlfolder.c:183
#define CFSTR_SHELLIDLIST
Definition: shlobj.h:543
struct CIDA * LPIDA
LPIDA _pIDList
#define RegisterClipboardFormat
Definition: winuser.h:5838

Referenced by DesktopShellView::DoContextMenu(), and IShellBrowserImpl::OnDefaultCommand().

◆ operator LPIDA()

PIDList::operator LPIDA ( )
inline

Definition at line 1096 of file shellclasses.h.

1096{return _pIDList;}

Member Data Documentation

◆ _pIDList

LPIDA PIDList::_pIDList
protected

Definition at line 1100 of file shellclasses.h.

Referenced by GetData(), and operator LPIDA().

◆ _stgm

STGMEDIUM PIDList::_stgm
protected

Definition at line 1099 of file shellclasses.h.

Referenced by GetData(), PIDList(), and ~PIDList().


The documentation for this struct was generated from the following file: