X-Git-Url: https://git.ralfj.de/multypo.git/blobdiff_plain/b02f9fdbd25d756d6ca73156d0b21a703e17d1de..a04d2f422e82b6c760b06daee47c0fcca1dc8064:/qt/multypo.h?ds=inline diff --git a/qt/multypo.h b/qt/multypo.h index b9dbf3f..66728a6 100644 --- a/qt/multypo.h +++ b/qt/multypo.h @@ -2,14 +2,22 @@ #define MULTIKBD_H #include +#include +#include -class QLabel; +#include "player.h" class MultypoWindow : public QWidget { Q_OBJECT public: + enum State { + Naming, + Playing, + Scoring + }; + explicit MultypoWindow(QWidget *parent = 0); ~MultypoWindow(); @@ -17,11 +25,19 @@ public: private: void handleKeyPress(int device, QString string); + void nextWord(); + bool allPlayersWaiting(); + int typingPlayers(); + void setLabel(QString text, QString color); -private: + State state; // naming iff (no players or any player is naming) + QString currentWord; // defined iff state == Playing + QMap players; + bool xiInited; int xiOpcode; QLabel *mainLabel; + QFile words; }; #endif // MULTIKBD_H