82 connect(ui.pageOptions->BtnBack, SIGNAL(clicked()), this, SLOT(GoBack())); |
82 connect(ui.pageOptions->BtnBack, SIGNAL(clicked()), this, SLOT(GoBack())); |
83 connect(ui.pageOptions->BtnNewTeam, SIGNAL(clicked()), this, SLOT(NewTeam())); |
83 connect(ui.pageOptions->BtnNewTeam, SIGNAL(clicked()), this, SLOT(NewTeam())); |
84 connect(ui.pageOptions->BtnEditTeam, SIGNAL(clicked()), this, SLOT(EditTeam())); |
84 connect(ui.pageOptions->BtnEditTeam, SIGNAL(clicked()), this, SLOT(EditTeam())); |
85 connect(ui.pageOptions->BtnSaveOptions, SIGNAL(clicked()), config, SLOT(SaveOptions())); |
85 connect(ui.pageOptions->BtnSaveOptions, SIGNAL(clicked()), config, SLOT(SaveOptions())); |
86 connect(ui.pageOptions->BtnSaveOptions, SIGNAL(clicked()), this, SLOT(GoBack())); |
86 connect(ui.pageOptions->BtnSaveOptions, SIGNAL(clicked()), this, SLOT(GoBack())); |
87 connect(ui.pageOptions->WeaponsButt, SIGNAL(clicked()), this, SLOT(GoToSelectWeapon())); |
87 connect(ui.pageOptions->WeaponEdit, SIGNAL(clicked()), this, SLOT(GoToSelectWeapon())); |
|
88 connect(ui.pageOptions->WeaponsButt, SIGNAL(clicked()), this, SLOT(GoToSelectNewWeapon())); |
88 |
89 |
89 connect(ui.pageNet->BtnBack, SIGNAL(clicked()), this, SLOT(GoBack())); |
90 connect(ui.pageNet->BtnBack, SIGNAL(clicked()), this, SLOT(GoBack())); |
90 connect(ui.pageNet->BtnSpecifyServer, SIGNAL(clicked()), this, SLOT(NetConnect())); |
91 connect(ui.pageNet->BtnSpecifyServer, SIGNAL(clicked()), this, SLOT(NetConnect())); |
91 connect(ui.pageNet->BtnNetSvrStart, SIGNAL(clicked()), this, SLOT(GoToNetServer())); |
92 connect(ui.pageNet->BtnNetSvrStart, SIGNAL(clicked()), this, SLOT(GoToNetServer())); |
92 connect(ui.pageNet, SIGNAL(connectClicked(const QString &, quint16)), this, SLOT(NetConnectServer(const QString &, quint16))); |
93 connect(ui.pageNet, SIGNAL(connectClicked(const QString &, quint16)), this, SLOT(NetConnectServer(const QString &, quint16))); |
133 teamslist.push_back("DefaultTeam"); |
134 teamslist.push_back("DefaultTeam"); |
134 } |
135 } |
135 |
136 |
136 ui.pageOptions->CBTeamName->clear(); |
137 ui.pageOptions->CBTeamName->clear(); |
137 ui.pageOptions->CBTeamName->addItems(teamslist); |
138 ui.pageOptions->CBTeamName->addItems(teamslist); |
|
139 |
|
140 // now updates weapons also |
|
141 ui.pageOptions->WeaponsName->clear(); |
|
142 ui.pageOptions->WeaponsName->addItems(ui.pageSelectWeapon->pWeapons->getWeaponNames()); |
138 } |
143 } |
139 |
144 |
140 void HWForm::GoToMain() |
145 void HWForm::GoToMain() |
141 { |
146 { |
142 GoToPage(ID_PAGE_MAIN); |
147 GoToPage(ID_PAGE_MAIN); |
160 void HWForm::GoToSetup() |
165 void HWForm::GoToSetup() |
161 { |
166 { |
162 GoToPage(ID_PAGE_SETUP); |
167 GoToPage(ID_PAGE_SETUP); |
163 } |
168 } |
164 |
169 |
|
170 void HWForm::GoToSelectNewWeapon() |
|
171 { |
|
172 ui.pageSelectWeapon->pWeapons->setWeaponsName(""); |
|
173 GoToPage(ID_PAGE_SELECTWEAPON); |
|
174 } |
|
175 |
165 void HWForm::GoToSelectWeapon() |
176 void HWForm::GoToSelectWeapon() |
166 { |
177 { |
|
178 ui.pageSelectWeapon->pWeapons->setWeaponsName(ui.pageOptions->WeaponsName->currentText()); |
167 GoToPage(ID_PAGE_SELECTWEAPON); |
179 GoToPage(ID_PAGE_SELECTWEAPON); |
168 } |
180 } |
169 |
181 |
170 void HWForm::GoToInfo() |
182 void HWForm::GoToInfo() |
171 { |
183 { |