Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

43 lines
1.6 KiB

  1. // WiaEventCallback.h: interface for the CWiaEventCallback class.
  2. //
  3. //////////////////////////////////////////////////////////////////////
  4. #if !defined(AFX_WIAEVENTCALLBACK_H__5125F8A0_29CF_4E4D_9D39_53DF7C29BD88__INCLUDED_)
  5. #define AFX_WIAEVENTCALLBACK_H__5125F8A0_29CF_4E4D_9D39_53DF7C29BD88__INCLUDED_
  6. #if _MSC_VER > 1000
  7. #pragma once
  8. #endif // _MSC_VER > 1000
  9. #define MAX_REGISTERED_EVENTS 50
  10. class CWiaEventCallback : public IWiaEventCallback
  11. {
  12. public:
  13. CWiaEventCallback();
  14. virtual ~CWiaEventCallback();
  15. // IUnknown members that delegate to m_pUnkRef.
  16. HRESULT _stdcall QueryInterface(const IID&,void**);
  17. ULONG _stdcall AddRef();
  18. ULONG _stdcall Release();
  19. HRESULT _stdcall ImageEventCallback(
  20. const GUID *pEventGUID,
  21. BSTR bstrEventDescription,
  22. BSTR bstrDeviceID,
  23. BSTR bstrDeviceDescription,
  24. DWORD dwDeviceType,
  25. BSTR bstrFullItemName,
  26. ULONG *plEventType,
  27. ULONG ulReserved);
  28. IUnknown* m_pIUnkRelease[MAX_REGISTERED_EVENTS];
  29. void SetViewWindowHandle(HWND hWnd);
  30. void SetNumberOfEventsRegistered(LONG lEventsRegistered);
  31. private:
  32. ULONG m_cRef; // Object reference count.
  33. HWND m_hViewWindow;
  34. LONG m_lNumEventsRegistered;
  35. TCHAR m_szWindowText[MAX_PATH];
  36. };
  37. #endif // !defined(AFX_WIAEVENTCALLBACK_H__5125F8A0_29CF_4E4D_9D39_53DF7C29BD88__INCLUDED_)