Rev 1 | Rev 31 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
1 | muzer | 1 | #ifndef MAINWINDOW_H |
2 | #define MAINWINDOW_H |
||
3 | |||
4 | #include <QMainWindow> |
||
5 | #include <QPaintEvent> |
||
6 | #include <QTcpServer> |
||
7 | #include <QList> |
||
8 | #include <QTimer> |
||
3 | tom | 9 | #include <QGLWidget> |
1 | muzer | 10 | |
11 | #include "bike.h" |
||
12 | |||
3 | tom | 13 | class MainWindow : public QGLWidget |
1 | muzer | 14 | { |
15 | Q_OBJECT |
||
16 | |||
17 | public: |
||
18 | MainWindow(QWidget *parent = 0); |
||
19 | ~MainWindow(); |
||
20 | void reset(); |
||
21 | |||
22 | protected: |
||
23 | void paintEvent(QPaintEvent *e); |
||
24 | |||
25 | private: |
||
26 | QTcpServer *server; |
||
27 | QList<Bike *> bikes; |
||
28 | QTimer *timer; |
||
29 | int id; |
||
30 | |||
31 | private slots: |
||
32 | void newConnection(); |
||
33 | void checkClients(); |
||
34 | }; |
||
35 | |||
36 | #endif // MAINWINDOW_H |