#ifndef CHATROOM_H #define CHATROOM_H #include #include "Socket.h" struct thread_args { pthread_mutex_t *mutex; pthread_cond_t *condition; Socket *s; }; namespace Ui { class Chatroom; } class Chatroom : public QMainWindow { Q_OBJECT public: explicit Chatroom(QWidget *parent = 0); ~Chatroom(); private: Ui::Chatroom *ui; void start(); bool connected; }; void *sendThread(void* args); void *recvThread(void* args); void killThread(thread_args *t_arg); #endif // CHATROOM_H