175 mItemDataHelper = &dataHelpper; |
175 mItemDataHelper = &dataHelpper; |
176 |
176 |
177 mUi = new CpSettingFormItemData(HbDataFormModelItem::GroupItem, hbTrId( |
177 mUi = new CpSettingFormItemData(HbDataFormModelItem::GroupItem, hbTrId( |
178 "txt_occ_subhead_security_settings")); |
178 "txt_occ_subhead_security_settings")); |
179 |
179 |
|
180 mUi->setContentWidgetData("objectName", "CpWepUi"); |
|
181 |
180 CpSettingFormItemData *wepKeyInUse = new CpSettingFormItemData( |
182 CpSettingFormItemData *wepKeyInUse = new CpSettingFormItemData( |
181 HbDataFormModelItem::ComboBoxItem, hbTrId( |
183 HbDataFormModelItem::ComboBoxItem, hbTrId( |
182 "txt_occ_setlabel_wep_key_in_use"), mUi); |
184 "txt_occ_setlabel_wep_key_in_use")); |
183 QStringList wepKeys; |
185 QStringList wepKeys; |
184 wepKeys.append(hbTrId("txt_occ_setlabel_wep_key_in_val_1")); |
186 wepKeys.append(hbTrId("txt_occ_setlabel_wep_key_in_val_1")); |
185 wepKeys.append(hbTrId("txt_occ_setlabel_wep_key_in_val_2")); |
187 wepKeys.append(hbTrId("txt_occ_setlabel_wep_key_in_val_2")); |
186 wepKeys.append(hbTrId("txt_occ_setlabel_wep_key_in_val_3")); |
188 wepKeys.append(hbTrId("txt_occ_setlabel_wep_key_in_val_3")); |
187 wepKeys.append(hbTrId("txt_occ_setlabel_wep_key_in_val_4")); |
189 wepKeys.append(hbTrId("txt_occ_setlabel_wep_key_in_val_4")); |
188 |
190 |
189 wepKeyInUse->setContentWidgetData("items", wepKeys); |
191 wepKeyInUse->setContentWidgetData("items", wepKeys); |
190 wepKeyInUse->setContentWidgetData("currentIndex", mNewKeySelected); |
192 wepKeyInUse->setContentWidgetData("currentIndex", mNewKeySelected); |
|
193 wepKeyInUse->setContentWidgetData("objectName", "CpWepUiKeyInUse"); |
|
194 |
191 dataHelpper.addConnection(wepKeyInUse, SIGNAL(currentIndexChanged(int)), |
195 dataHelpper.addConnection(wepKeyInUse, SIGNAL(currentIndexChanged(int)), |
192 this, SLOT(wepKeyInUseChanged(int))); |
196 this, SLOT(wepKeyInUseChanged(int))); |
193 mUi->appendChild(wepKeyInUse); |
197 mUi->appendChild(wepKeyInUse); |
194 |
198 |
195 //Create Ui for all 4 WEP keys |
199 //Create Ui for all 4 WEP keys |
263 textId = hbTrId("txt_occ_setlabel_wep_key_4"); |
267 textId = hbTrId("txt_occ_setlabel_wep_key_4"); |
264 break; |
268 break; |
265 } |
269 } |
266 |
270 |
267 mWepKeyText[index] = new CpSettingFormItemData( |
271 mWepKeyText[index] = new CpSettingFormItemData( |
268 HbDataFormModelItem::TextItem, |
272 HbDataFormModelItem::TextItem, |
269 textId, mUi); |
273 textId); |
|
274 |
270 |
275 |
271 if (mKeyData[index].length() != 0) { |
276 if (mKeyData[index].length() != 0) { |
272 mWepKeyText[index]->setContentWidgetData("text", |
277 mWepKeyText[index]->setContentWidgetData("text", mKeyData[index]); |
273 mKeyData[index]); |
|
274 } |
278 } |
275 mWepKeyText[index]->setContentWidgetData("echoMode",HbLineEdit::PasswordEchoOnEdit); |
279 mWepKeyText[index]->setContentWidgetData("echoMode",HbLineEdit::PasswordEchoOnEdit); |
276 mWepKeyText[index]->setContentWidgetData("smileysEnabled", "false"); |
280 mWepKeyText[index]->setContentWidgetData("smileysEnabled", "false"); |
277 |
281 QString objectName; |
|
282 objectName.setNum(index); |
|
283 objectName.prepend("CpWepUiKeyEditor"); |
|
284 mWepKeyText[index]->setContentWidgetData("objectName", objectName); |
278 |
285 |
279 mUi->appendChild(mWepKeyText[index]); |
286 mUi->appendChild(mWepKeyText[index]); |
280 OstTraceFunctionExit1(CPWEPUI_CREATEWEPKEYGROUP_EXIT,this); |
287 OstTraceFunctionExit1(CPWEPUI_CREATEWEPKEYGROUP_EXIT,this); |
281 } |
288 } |
282 |
289 |
641 { |
648 { |
642 OstTraceFunctionEntry1(CPWEPUI_SHOWMESSAGEBOX_ENTRY,this); |
649 OstTraceFunctionEntry1(CPWEPUI_SHOWMESSAGEBOX_ENTRY,this); |
643 |
650 |
644 // Create a message box |
651 // Create a message box |
645 mMessageBox = QSharedPointer<HbMessageBox> (new HbMessageBox(type)); |
652 mMessageBox = QSharedPointer<HbMessageBox> (new HbMessageBox(type)); |
|
653 mMessageBox->setObjectName("CpWepUiMessageBox"); |
646 mMessageBox->setText(text); |
654 mMessageBox->setText(text); |
647 mMessageBox->open(); |
655 mMessageBox->open(); |
648 |
656 |
649 OstTraceFunctionExit1(CPWEPUI_SHOWMESSAGEBOX_EXIT,this); |
657 OstTraceFunctionExit1(CPWEPUI_SHOWMESSAGEBOX_EXIT,this); |
650 } |
658 } |