CStackQueue.h 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. #pragma once
  2. #include "../UIFramework/CIntObject.h"
  3. struct SDL_Surface;
  4. class CStack;
  5. class CBattleInterface;
  6. /*
  7. * CStackQueue.h, part of VCMI engine
  8. *
  9. * Authors: listed in file AUTHORS in main folder
  10. *
  11. * License: GNU General Public License v2.0 or later
  12. * Full text of license available in license.txt file, in main folder
  13. *
  14. */
  15. /// Shows the stack queue
  16. class CStackQueue : public CIntObject
  17. {
  18. class StackBox : public CIntObject
  19. {
  20. public:
  21. const CStack *my;
  22. SDL_Surface *bg;
  23. void hover (bool on);
  24. void showAll(SDL_Surface *to);
  25. void setStack(const CStack *nStack);
  26. StackBox(SDL_Surface *BG);
  27. ~StackBox();
  28. };
  29. public:
  30. static const int QUEUE_SIZE = 10;
  31. const bool embedded;
  32. std::vector<const CStack *> stacksSorted;
  33. std::vector<StackBox *> stackBoxes;
  34. SDL_Surface *box;
  35. SDL_Surface *bg;
  36. CBattleInterface * owner;
  37. void showAll(SDL_Surface *to);
  38. CStackQueue(bool Embedded, CBattleInterface * _owner);
  39. ~CStackQueue();
  40. void update();
  41. void blitBg( SDL_Surface * to );
  42. //void showAll(SDL_Surface *to);
  43. };