X-Git-Url: https://git.ralfj.de/multypo.git/blobdiff_plain/e8b07da1c5251e412f80fdeb94fb327b641fc956..HEAD:/qt/multypo.h diff --git a/qt/multypo.h b/qt/multypo.h index 9220df8..66728a6 100644 --- a/qt/multypo.h +++ b/qt/multypo.h @@ -12,6 +12,12 @@ class MultypoWindow : public QWidget Q_OBJECT public: + enum State { + Naming, + Playing, + Scoring + }; + explicit MultypoWindow(QWidget *parent = 0); ~MultypoWindow(); @@ -20,15 +26,18 @@ public: private: void handleKeyPress(int device, QString string); void nextWord(); - void resetPlayerText(); + 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; - bool gameStarted; QLabel *mainLabel; QFile words; - QMap players; }; #endif // MULTIKBD_H