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.

43 lines
1.3 KiB

  1. /******************************Module*Header*******************************\
  2. * Module Name: dlgdraw.hxx
  3. *
  4. *
  5. *
  6. * Copyright (c) 1996 Microsoft Corporation
  7. *
  8. \**************************************************************************/
  9. #ifndef __dlgdraw_hxx__
  10. #define __dlgdraw_hxx__
  11. #include "sscommon.h"
  12. #include "sswindow.hxx"
  13. /**************************************************************************\
  14. * SS_TEX_BUTTON
  15. *
  16. * Texture wrapper for a dialog button. The object's current texture is a
  17. * pointer to a TEXTURE, so the caller must manage texture memory.
  18. \**************************************************************************/
  19. class SS_TEX_BUTTON {
  20. public:
  21. SS_TEX_BUTTON( HWND hdlg, HWND hdlgBtn );
  22. ~SS_TEX_BUTTON();
  23. void Draw(); // Use current texture
  24. void Draw( TEXTURE *pTex ); // Use supplied texture
  25. void SetTexture( TEXTURE *pTex ); // Set current texture
  26. void Enable() { bEnabled = TRUE; }; // Set enabled state
  27. void Disable() { bEnabled = FALSE; }; // Set disabled state
  28. private:
  29. TEXTURE *pCurTex; // Current texture for this button
  30. int intensity;
  31. BOOL bEnabled;
  32. PSSW pssw;
  33. IPOINT2D origin;
  34. ISIZE size;
  35. void InitGL(); // Sets texture params, etc.
  36. };
  37. #endif // __dlgdraw_hxx__