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.

46 lines
1.1 KiB

  1. /*
  2. * RepeatButton
  3. */
  4. #ifndef DUI_CONTROL_REPEATBUTTON_H_INCLUDED
  5. #define DUI_CONTROL_REPEATBUTTON_H_INCLUDED
  6. #pragma once
  7. #include "duibutton.h"
  8. namespace DirectUI
  9. {
  10. ////////////////////////////////////////////////////////
  11. // RepeatButton
  12. // Class definition
  13. class RepeatButton : public Button
  14. {
  15. public:
  16. static HRESULT Create(OUT Element** ppElement) { return Create(AE_MouseAndKeyboard, ppElement); }
  17. static HRESULT Create(UINT nActive, OUT Element** ppElement);
  18. // System events
  19. virtual void OnInput(InputEvent* pie);
  20. // ClassInfo accessors (static and virtual instance-based)
  21. static IClassInfo* Class;
  22. virtual IClassInfo* GetClassInfo() { return Class; }
  23. static HRESULT Register();
  24. RepeatButton() { }
  25. HRESULT Initialize(UINT nActive);
  26. virtual ~RepeatButton() { }
  27. private:
  28. static void CALLBACK _RepeatButtonActionCallback(GMA_ACTIONINFO* pmai);
  29. HACTION _hAction;
  30. BOOL _fActionDelay;
  31. };
  32. } // namespace DirectUI
  33. #endif // DUI_CONTROL_REPEATBUTTON_H_INCLUDED