equal
deleted
inserted
replaced
18 |
18 |
19 #ifndef _SELECT_WEAPON_INCLUDED |
19 #ifndef _SELECT_WEAPON_INCLUDED |
20 #define _SELECT_WEAPON_INCLUDED |
20 #define _SELECT_WEAPON_INCLUDED |
21 |
21 |
22 #include <QFrame> |
22 #include <QFrame> |
23 #include <map> |
23 #include <QMap> |
|
24 #include <QList> |
24 |
25 |
25 class QGridLayout; |
26 class QGridLayout; |
26 class WeaponItem; |
27 class WeaponItem; |
27 class QLineEdit; |
28 class QLineEdit; |
28 class QSettings; |
29 class QSettings; |
30 class SelWeaponItem : public QWidget |
31 class SelWeaponItem : public QWidget |
31 { |
32 { |
32 Q_OBJECT |
33 Q_OBJECT |
33 |
34 |
34 public: |
35 public: |
35 SelWeaponItem(int iconNum, int wNum, QWidget* parent=0); |
36 SelWeaponItem(bool allowInfinite, int iconNum, int wNum, QWidget* parent=0); |
36 |
37 |
37 unsigned char getItemsNum() const; |
38 unsigned char getItemsNum() const; |
38 void setItemsNum(const unsigned char num); |
39 void setItemsNum(const unsigned char num); |
39 |
40 |
40 private: |
41 private: |
68 |
69 |
69 QSettings* wconf; |
70 QSettings* wconf; |
70 |
71 |
71 const int m_numItems; |
72 const int m_numItems; |
72 int operator [] (unsigned int weaponIndex) const; |
73 int operator [] (unsigned int weaponIndex) const; |
73 |
74 |
74 typedef std::map<int, SelWeaponItem*> twi; |
75 typedef QList<SelWeaponItem*> ItemsList; |
|
76 typedef QMap<int, ItemsList> twi; |
75 twi weaponItems; |
77 twi weaponItems; |
76 QGridLayout* pLayout; |
78 QGridLayout* p1Layout; |
|
79 QGridLayout* p2Layout; |
77 }; |
80 }; |
78 |
81 |
79 #endif // _SELECT_WEAPON_INCLUDED |
82 #endif // _SELECT_WEAPON_INCLUDED |