UISlider.h 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. #ifndef __UISLIDER_H__
  2. #define __UISLIDER_H__
  3. #pragma once
  4. namespace DuiLib
  5. {
  6. class DUILIB_API CSliderUI : public CProgressUI
  7. {
  8. public:
  9. CSliderUI();
  10. LPCTSTR GetClass() const;
  11. UINT GetControlFlags() const;
  12. LPVOID GetInterface(LPCTSTR pstrName);
  13. void SetEnabled(bool bEnable = true);
  14. int GetChangeStep();
  15. void SetChangeStep(int step);
  16. void SetThumbSize(SIZE szXY);
  17. RECT GetThumbRect() const;
  18. bool IsImmMode() const;
  19. void SetImmMode(bool bImmMode);
  20. LPCTSTR GetThumbImage() const;
  21. void SetThumbImage(LPCTSTR pStrImage);
  22. LPCTSTR GetThumbHotImage() const;
  23. void SetThumbHotImage(LPCTSTR pStrImage);
  24. LPCTSTR GetThumbPushedImage() const;
  25. void SetThumbPushedImage(LPCTSTR pStrImage);
  26. void DoEvent(TEventUI& event);
  27. void SetAttribute(LPCTSTR pstrName, LPCTSTR pstrValue);
  28. void PaintStatusImage(HDC hDC);
  29. protected:
  30. SIZE m_szThumb;
  31. UINT m_uButtonState;
  32. int m_nStep;
  33. bool m_bImmMode;
  34. TDrawInfo m_diThumb;
  35. TDrawInfo m_diThumbHot;
  36. TDrawInfo m_diThumbPushed;
  37. };
  38. }
  39. #endif // __UISLIDER_H__