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.

59 lines
1.8 KiB

  1. #ifndef __b59ae174_378f_48e2_bb6d_61eceb410c32__
  2. #define __b59ae174_378f_48e2_bb6d_61eceb410c32__
  3. #include <windows.h>
  4. #include "imgs.h"
  5. #include "simdc.h"
  6. class CImagePainter
  7. {
  8. private:
  9. CBitmapImage *m_pBitmapImage;
  10. DWORD m_dwInitialTickCount;
  11. bool m_bFirstFrame;
  12. bool m_bAlreadyPaintedLastFrame;
  13. bool m_bNeedPainting;
  14. DWORD m_dwLastInput; // on input, show command buttons
  15. protected:
  16. bool m_bToolbarVisible;
  17. RECT m_rcScreen;
  18. RECT m_rcFinal;
  19. DWORD m_dwDuration;
  20. private:
  21. CImagePainter(void);
  22. CImagePainter( const CImagePainter & );
  23. operator=( const CImagePainter & );
  24. void ComputeImageLayout();
  25. public:
  26. void SetToolbarVisible(bool bVisible);
  27. CImagePainter( CBitmapImage *pBitmapImage, CSimpleDC &ClientDC, const RECT &rcScreen, bool bToolbarVisible );
  28. virtual ~CImagePainter(void);
  29. DWORD ElapsedTime(void) const;
  30. CBitmapImage* BitmapImage(void) const;
  31. void Paint( CSimpleDC &PaintDC );
  32. bool TimerTick( CSimpleDC &ClientDC );
  33. void Erase( CSimpleDC &ClientDC, RECT &rc );
  34. virtual void Paint( CSimpleDC &PaintDC, CSimpleDC &MemoryDC );
  35. void NeedPainting(bool bNeedPainting) { m_bNeedPainting = true; };
  36. virtual bool NeedPainting(void);
  37. virtual bool IsValid(void);
  38. virtual void PaintFrame( CSimpleDC &ClientDC, CSimpleDC &MemoryDC ) = 0;
  39. void OnInput();
  40. };
  41. class CSimpleTransitionPainter : public CImagePainter
  42. {
  43. public:
  44. CSimpleTransitionPainter( CBitmapImage *pBitmapImage, CSimpleDC &ClientDC, const RECT &rcScreen, bool bToolbarVisible );
  45. virtual ~CSimpleTransitionPainter(void);
  46. virtual void PaintFrame( CSimpleDC &ClientDC, CSimpleDC &MemoryDC );
  47. };
  48. #endif // __PAINTERS_H_INCLUDED