equal
deleted
inserted
replaced
17 */ |
17 */ |
18 |
18 |
19 #ifndef _NET_WWWWIDGET_INCLUDED |
19 #ifndef _NET_WWWWIDGET_INCLUDED |
20 #define _NET_WWWWIDGET_INCLUDED |
20 #define _NET_WWWWIDGET_INCLUDED |
21 |
21 |
|
22 #include <QAbstractTableModel> |
|
23 #include <QFile> |
|
24 #include <QDateTime> |
|
25 #include <QVector> |
22 #include "netserverslist.h" |
26 #include "netserverslist.h" |
23 |
27 |
24 class QListWidget; |
28 class QListWidget; |
25 class QHttp; |
29 class QHttp; |
26 |
30 |
39 |
43 |
40 private: |
44 private: |
41 QHttp * http; |
45 QHttp * http; |
42 }; |
46 }; |
43 |
47 |
|
48 class HWNetWwwModel : public QAbstractTableModel |
|
49 { |
|
50 Q_OBJECT |
|
51 |
|
52 public: |
|
53 HWNetWwwModel(QObject *parent = 0); |
|
54 |
|
55 QVariant data(const QModelIndex &index, int role) const; |
|
56 QVariant headerData(int section, Qt::Orientation orientation, int role) const; |
|
57 int rowCount(const QModelIndex & parent) const; |
|
58 int columnCount(const QModelIndex & parent) const; |
|
59 |
|
60 private: |
|
61 QHttp * http; |
|
62 QList<QStringList> games; |
|
63 |
|
64 private slots: |
|
65 void onClientRead(int id, bool error); |
|
66 |
|
67 public slots: |
|
68 void updateList(); |
|
69 }; |
|
70 |
44 #endif // _NET_WWWWIDGET_INCLUDED |
71 #endif // _NET_WWWWIDGET_INCLUDED |