banner.h 741 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. #ifndef NULLSOFT_ML_BANNER_HEADER
  2. #define NULLSOFT_ML_BANNER_HEADER
  3. #include <windows.h>
  4. class MLBanner
  5. {
  6. public:
  7. MLBanner(void);
  8. ~MLBanner(void);
  9. public:
  10. void SetColors(int color1, int color2);
  11. void SetImages(HINSTANCE hInstance, int bgndResId, int logoResId);
  12. void Init(HWND hwnd);
  13. void ReloadImages(void);
  14. protected:
  15. void DestroyImages(void);
  16. void UpdateBunnerBmp(void);
  17. static INT_PTR CALLBACK newWndProc(HWND hwndDlg, UINT uMsg, WPARAM wParam,LPARAM lParam);
  18. private:
  19. HWND m_hwnd;
  20. HBITMAP bmpBck;
  21. HBITMAP bmpLogo;
  22. HBITMAP bmpLogoMask;
  23. HBITMAP bmpBanner;
  24. WNDPROC oldWndProc;
  25. HINSTANCE hInstance;
  26. int logoResId;
  27. int bgndResId;
  28. int color1;
  29. int color2;
  30. RECT rcBanner;
  31. };
  32. #endif // NULLSOFT_ML_BANNER_HEADER