Menü.h 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165
  1. #ifndef Menü_H
  2. #define Menü_H
  3. #include <Knopf.h>
  4. #include <Tabelle.h>
  5. #include <Diagramm.h>
  6. #include <AuswahlBox.h>
  7. #include "Map.h"
  8. using namespace Framework;
  9. class MenüVerloren
  10. {
  11. private:
  12. LRahmen *ram;
  13. TextFeld *verloren;
  14. Knopf *neu;
  15. Knopf *beenden;
  16. int ref;
  17. public:
  18. // Kontruktor
  19. MenüVerloren( Schrift *zSchrift );
  20. // Destruktor
  21. ~MenüVerloren();
  22. // nicht constant
  23. int doMausEreignis( MausEreignis &me );
  24. bool tick( double tickVal );
  25. void render( Bild &zRObj );
  26. // Reference Counting
  27. MenüVerloren *getThis();
  28. MenüVerloren *release();
  29. };
  30. class MenüSpiel
  31. {
  32. private:
  33. TextFeld *scoreT;
  34. Knopf *beenden;
  35. Map *map;
  36. MenüVerloren *verloren;
  37. bool beendet;
  38. int ref;
  39. public:
  40. // Konstruktor
  41. MenüSpiel( Schrift *zSchrift, Bildschirm *zScreen );
  42. // Destruktor
  43. ~MenüSpiel();
  44. // nicht constant
  45. void reset();
  46. void doMausEreignis( MausEreignis &me );
  47. void doTastaturEreignis( TastaturEreignis &te );
  48. bool tick( double tickVal );
  49. void render( Bild &zRObj );
  50. // constant
  51. bool istBeendet() const;
  52. // Reference Counting
  53. MenüSpiel *getThis();
  54. MenüSpiel *release();
  55. };
  56. class MenüStatistik
  57. {
  58. private:
  59. TextFeld *ansichtT;
  60. AuswahlBox *ansicht;
  61. KontrollKnopf *optionen;
  62. ObjTabelle *gesammtT;
  63. ObjTabelle *optionenT;
  64. LDiag *gesammtD;
  65. LDiag *optionenD;
  66. Knopf *removen;
  67. Knopf *zurück;
  68. Schrift *schrift;
  69. bool beendet;
  70. int ref = 1;
  71. public:
  72. // Konstruktor
  73. MenüStatistik( Schrift *zSchrift, Bildschirm *zScreen );
  74. // Destruktor
  75. ~MenüStatistik();
  76. // nicht constant
  77. void reset();
  78. void doMausEreignis( MausEreignis &me );
  79. bool tick( double tickVal );
  80. void render( Bild &zRObj );
  81. // constant
  82. bool istBeendet() const;
  83. // Reference Counting
  84. MenüStatistik *getThis();
  85. MenüStatistik *release();
  86. };
  87. class MenüOptionen
  88. {
  89. private:
  90. TextFeld *breiteT;
  91. TextFeld *breite;
  92. TextFeld *höheT;
  93. TextFeld *höhe;
  94. TextFeld *bAnzahlT;
  95. TextFeld *bAnzahl;
  96. TextFeld *tempoT;
  97. TextFeld *tempo;
  98. KontrollKnopf *fortsetzen;
  99. Knopf *abbrechen;
  100. Knopf *ok;
  101. bool beendet;
  102. int ref;
  103. public:
  104. // Konstruktor
  105. MenüOptionen( Schrift *zSchrift, Bildschirm *zScreen );
  106. // Destruktor
  107. ~MenüOptionen();
  108. // nicht constant
  109. void reset();
  110. void doMausEreignis( MausEreignis &me );
  111. void doTastaturEreignis( TastaturEreignis &te );
  112. bool tick( double tickVal );
  113. void render( Bild &zRObj );
  114. // constant
  115. bool istBeendet() const;
  116. // Reference Counting
  117. MenüOptionen *getThis();
  118. MenüOptionen *release();
  119. };
  120. class Menü
  121. {
  122. private:
  123. Knopf *spielen;
  124. MenüSpiel *spielenF;
  125. Knopf *optionen;
  126. MenüOptionen *optionenF;
  127. Knopf *statistik;
  128. MenüStatistik *statistikF;
  129. Knopf *beenden;
  130. Bild *hintergrund;
  131. LRahmen *ram;
  132. bool beendet;
  133. int status;
  134. int ref;
  135. public:
  136. // Konstruktor
  137. Menü( Schrift *zSchrift, Bildschirm *zScreen );
  138. // Destruktor
  139. ~Menü();
  140. // nicht constant
  141. void reset();
  142. void doMausEreignis( MausEreignis &me );
  143. void doTastaturEreignis( TastaturEreignis &te );
  144. bool tick( double z );
  145. void render( Bild &zRObj );
  146. // constant
  147. bool istBeendet() const;
  148. // Reference Counting
  149. Menü *getThis();
  150. Menü *release();
  151. };
  152. #endif