MCPcopy Create free account
hub / github.com/cinience/RedisStudio / RegisterEventHandler

Method RegisterEventHandler

DuiLib/Control/UIFlash.cpp:240–265  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

238 }
239
240 HRESULT CFlashUI::RegisterEventHandler( BOOL inAdvise )
241 {
242 if (m_pFlash==NULL)
243 return S_FALSE;
244
245 HRESULT hr=S_FALSE;
246 CComPtr<IConnectionPointContainer> pCPC;
247 CComPtr<IConnectionPoint> pCP;
248
249 hr=m_pFlash->QueryInterface(IID_IConnectionPointContainer,(void **)&pCPC);
250 if (FAILED(hr))
251 return hr;
252 hr=pCPC->FindConnectionPoint(__uuidof(_IShockwaveFlashEvents),&pCP);
253 if (FAILED(hr))
254 return hr;
255
256 if (inAdvise)
257 {
258 hr = pCP->Advise((IDispatch*)this, &m_dwCookie);
259 }
260 else
261 {
262 hr = pCP->Unadvise(m_dwCookie);
263 }
264 return hr;
265 }
266
267 void CFlashUI::SetAttribute( LPCTSTR pstrName, LPCTSTR pstrValue )
268 {

Callers

nothing calls this directly

Calls 1

QueryInterfaceMethod · 0.45

Tested by

no test coverage detected