MCPcopy Create free account
hub / github.com/LegacyUpdate/LegacyUpdate / IOleObjectImpl

Class IOleObjectImpl

include/com/IOleObjectImpl.h:9–142  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

7
8template<typename TImpl>
9class IOleObjectImpl : public ComClass<TImpl, IOleObject> {
10public:
11 IOleObjectImpl(TImpl *pParent) : ComClass<TImpl, IOleObject>(pParent) {}
12
13 // IOleObject
14 STDMETHODIMP SetClientSite(IOleClientSite *pClientSite) {
15 if (this->m_pParent->m_clientSite) {
16 this->m_pParent->m_clientSite->Release();
17 }
18 this->m_pParent->m_clientSite = pClientSite;
19 if (this->m_pParent->m_clientSite) {
20 this->m_pParent->m_clientSite->AddRef();
21 }
22 return S_OK;
23 }
24
25 STDMETHODIMP GetClientSite(IOleClientSite **ppClientSite) {
26 if (ppClientSite == NULL) {
27 return E_POINTER;
28 }
29
30 if (this->m_pParent->m_clientSite == NULL) {
31 *ppClientSite = NULL;
32 return E_FAIL;
33 }
34
35 this->m_pParent->m_clientSite->AddRef();
36 *ppClientSite = this->m_pParent->m_clientSite;
37 return S_OK;
38 }
39
40 STDMETHODIMP SetHostNames(LPCOLESTR szContainerApp, LPCOLESTR szContainerObj) {
41 return S_OK;
42 }
43
44 STDMETHODIMP Close(DWORD dwSaveOption) {
45 if (this->m_pParent->m_clientSite) {
46 this->m_pParent->m_clientSite->Release();
47 this->m_pParent->m_clientSite = NULL;
48 }
49 return S_OK;
50 }
51
52 STDMETHODIMP SetMoniker(DWORD dwWhichMoniker, IMoniker *pmk) {
53 return E_NOTIMPL;
54 }
55
56 STDMETHODIMP GetMoniker(DWORD dwAssign, DWORD dwWhichMoniker, IMoniker **ppmk) {
57 return E_NOTIMPL;
58 }
59
60 STDMETHODIMP InitFromData(IDataObject *pDataObject, BOOL fCreation, DWORD dwReserved) {
61 return E_NOTIMPL;
62 }
63
64 STDMETHODIMP GetClipboardData(DWORD dwReserved, IDataObject **ppDataObject) {
65 return E_NOTIMPL;
66 }

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected