CTutorialWindow.h 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. /*
  2. * CTutorialWindow.h, part of VCMI engine
  3. *
  4. * Authors: listed in file AUTHORS in main folder
  5. *
  6. * License: GNU General Public License v2.0 or later
  7. * Full text of license available in license.txt file, in main folder
  8. *
  9. */
  10. #pragma once
  11. #include "../windows/CWindowObject.h"
  12. class CFilledTexture;
  13. class CButton;
  14. class CLabel;
  15. class CMultiLineLabel;
  16. enum TutorialMode
  17. {
  18. TOUCH_ADVENTUREMAP,
  19. TOUCH_BATTLE
  20. };
  21. class CTutorialWindow : public CWindowObject
  22. {
  23. TutorialMode mode;
  24. std::shared_ptr<CFilledTexture> background;
  25. std::shared_ptr<CButton> buttonOk;
  26. std::shared_ptr<CButton> buttonLeft;
  27. std::shared_ptr<CButton> buttonRight;
  28. std::shared_ptr<CLabel> labelTitle;
  29. std::shared_ptr<CMultiLineLabel> labelInformation;
  30. std::string video;
  31. std::vector<std::string> videos;
  32. int page;
  33. void exit();
  34. void next();
  35. void previous();
  36. void setContent();
  37. public:
  38. CTutorialWindow(const TutorialMode & m);
  39. static void openWindowFirstTime(const TutorialMode & m);
  40. void show(Canvas & to) override;
  41. void activate() override;
  42. void deactivate() override;
  43. };