#ifndef PatchServer_H #define PatchServer_H #include "..\..\Basic\Abschnitt.h" #include "..\..\..\Netzwerk\Main\MSKlient.h" #include "..\..\..\Netzwerk\Patch\PSKlient.h" #include "..\..\..\Ressourcen\Ressourcen.h" #include #include #include #include #include class AdminAccount; // Login.h class PatchServer; // PatchServer.h class PSUpdate : public Thread { private: PatchServer* zPSA; AdminAccount* account; PSKlient* psc; int gruppeAnzahl; int* gruppeId; int id; public: // Kontruktor PSUpdate(PatchServer* zPSA, AdminAccount* account); // Destruktor ~PSUpdate(); // nicht constant void setServer(const char* ip, unsigned short port); void setUpdateListe(int gAnzahl, Array< int >* gId); virtual void thread(); }; class PSDetails : public Thread { private: PatchServer* zPSA; MSKlient* mk; int id; public: // Konstruktor PSDetails(PatchServer* zPSA, MSKlient* mk); // Destruktor ~PSDetails(); // nicht constant void setServerId(int id); virtual void thread(); }; class PSSuche : public Thread { private: PatchServer* zPSA; MSKlient* mk; public: // Konstruktor PSSuche(PatchServer* zPSA, MSKlient* mk); // Destruktor ~PSSuche(); // nicht constant virtual void thread(); }; class PatchServer : public Abschnitt { private: Fenster* fenster; Fenster* liste; Fenster* details; Fenster* updateF; MSKlient* msk; InitDatei* iD; Fenster* f; AdminAccount* account; Knopf* aktualisieren; Knopf* weiter; Knopf* zurück; ObjTabelle* tabelle; ObjTabelle* updateT; PSSuche* suchen; PSDetails* getDetails; PSUpdate* updateTh; Schrift* schrift; PSKlient* psc; TextFeld* serverId; TextFeld* serverName; TextFeld* serverIp; TextFeld* serverPort; TextFeld* serverAPort; TextFeld* serverClients; TextFeld* serverMaxClients; TextFeld* maxClients; TextFeld* serverStatus; TextFeld* serverFehler; Knopf* updateStarten; Knopf* update; Knopf* pausieren; Knopf* stoppen; Knopf* beenden; Knopf* terminieren; Knopf* setMaxClients; Zeichnung* obj; public: // Konstruktor PatchServer(Schrift* s, InitDatei* d, MSKlient* msk, RessourceBild* rb, AdminAccount* acc, Bildschirm* b); // Destruktor ~PatchServer(); // nicht constant virtual void setFenster(Fenster* f); virtual void setSichtbar(bool s); void addServer(int id, const char* name, const char* ip, int port, int adminPort, const char* status); void sucheAbgeschlossen(); void setServerDetails(int id, const char* name, const char* ip, int port, int adminPort, int clients, int maxClients, int status, Text* error); void setUpdateProzent(int prozent, int gruppe); void setUpdateFertig(bool error, int gruppe); bool aktualisierenMausEreignis(void* o, MausEreignis me); bool auswahlKnopfMausEreignis(void* o, MausEreignis me); bool weiterMausEreignis(void* o, MausEreignis me); bool zurückMausEreignis(void* o, MausEreignis me); bool updateMausEreignis(void* o, MausEreignis me); bool pausierenMausEreignis(void* o, MausEreignis me); bool stoppenMausEreignis(void* o, MausEreignis me); bool beendenMausEreignis(void* o, MausEreignis me); bool terminierenMausEreignis(void* o, MausEreignis me); bool setMaxClientsMausEreignis(void* o, MausEreignis me); bool updateStartenMausEreignis(void* o, MausEreignis me); bool maxClientsTastaturEreignis(void* o, TastaturEreignis te); void updateAll(); }; // Ereignisse bool patchServerAktualisierenMausEreignis(void* p, void* o, MausEreignis me); bool patchServerAuswahlKnopfMausEreignis(void* p, void* o, MausEreignis me); bool patchServerWeiterMausEreignis(void* p, void* o, MausEreignis me); bool patchServerZurückMausEreignis(void* p, void* o, MausEreignis me); bool patchServerUpdateMausEreignis(void* p, void* o, MausEreignis me); bool patchServerPausierenMausEreignis(void* p, void* o, MausEreignis me); bool patchServerStoppenMausEreignis(void* p, void* o, MausEreignis me); bool patchServerBeendenMausEreignis(void* p, void* o, MausEreignis me); bool patchServerTerminierenMausEreignis(void* p, void* o, MausEreignis me); bool patchServerSetMaxClientsMausEreignis(void* p, void* o, MausEreignis me); bool patchServerUpdateStartenMausEreignis(void* p, void* o, MausEreignis me); bool patchServerMaxClientsTastaturEreignis(void* p, void* o, TastaturEreignis te); #endif