Leaked source code of windows server 2003
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.

52 lines
1.4 KiB

  1. #ifndef _W3SUI_H_
  2. #define _W3SUI_H_
  3. class CW3SpoofUI : public IW3SpoofEvents
  4. {
  5. public:
  6. //
  7. // IUnknown and IW3SpoofEvents
  8. //
  9. HRESULT __stdcall QueryInterface(REFIID riid, void** ppv);
  10. ULONG __stdcall AddRef(void);
  11. ULONG __stdcall Release(void);
  12. HRESULT __stdcall OnSessionOpen(LPWSTR clientid);
  13. HRESULT __stdcall OnSessionStateChange(LPWSTR clientid, STATE state);
  14. HRESULT __stdcall OnSessionClose(LPWSTR clientid);
  15. //
  16. // object methods
  17. //
  18. CW3SpoofUI();
  19. ~CW3SpoofUI();
  20. static HRESULT Create(CW3SpoofUI** ppw3sui, HINSTANCE hInst, IW3SpoofClientSupport* pcs);
  21. HRESULT Initialize(HINSTANCE hInst, IW3SpoofClientSupport* pcs);
  22. HRESULT Terminate(void);
  23. HRESULT Run(void);
  24. friend LRESULT CALLBACK WndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam);
  25. protected:
  26. LRESULT _WndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam);
  27. private:
  28. HRESULT _CreateUI(void);
  29. HRESULT _CreateTrayIcon(void);
  30. HRESULT _UpdateTrayIcon(void);
  31. HRESULT _DestroyTrayIcon(void);
  32. void _WriteText(const WCHAR* format, ...);
  33. HINSTANCE m_hInst;
  34. HWND m_hWnd;
  35. HWND m_listbox;
  36. HFONT m_font;
  37. HICON m_hIcon;
  38. IConnectionPoint* m_pCP;
  39. DWORD m_dwCookie;
  40. LONG m_cRefs;
  41. };
  42. #endif /* _W3SUI_H_ */