317 // ----------------------------------------------------------------------------- |
319 // ----------------------------------------------------------------------------- |
318 // |
320 // |
319 void CIAUpdateSettingDialog::initializeView() |
321 void CIAUpdateSettingDialog::initializeView() |
320 { |
322 { |
321 |
323 |
322 setTitle("Software update"); // txt_software_title_software_update |
324 setTitle("Software update"); |
323 mSettingsForm->setHeading("Settings"); // txt_software_subhead_settings |
325 //setTitle(hbTrId("txt_software_title_software_update")); |
324 |
326 |
325 //create a model class |
327 mSettingsForm->setHeading("Settings"); |
326 HbDataFormModel *mModel = new HbDataFormModel(); |
328 //mSettingsForm->setHeading(hbTrId("txt_software_subhead_settings")); |
327 |
329 |
328 // add Destination item |
330 //create a model class |
329 mDestinationItem = mModel->appendDataFormItem( |
331 HbDataFormModel *mModel = new HbDataFormModel(); |
330 HbDataFormModelItem::ToggleValueItem, QString("Network connection")); // txt_software_formlabel_access_point |
332 |
331 |
333 // add Destination item |
332 // add auto update item |
334 mDestinationItem = mModel->appendDataFormItem( |
333 mAutoUpdateItem = mModel->appendDataFormItem( |
335 HbDataFormModelItem::ToggleValueItem, QString("Network connection")); |
334 HbDataFormModelItem::ComboBoxItem, QString("Auto-check for updates")); // txt_software_setlabel_autocheck_for_updates |
336 //HbDataFormModelItem::ToggleValueItem, hbTrId("txt_software_formlabel_network_connection")); |
335 |
337 |
336 // auto update selection values |
338 // add auto update item |
337 QStringList list; |
339 mAutoUpdateItem = mModel->appendDataFormItem( |
338 list.insert(0, QString("On")); // txt_software_setlabel_val_on |
340 HbDataFormModelItem::ComboBoxItem, QString("Auto-check for updates")); |
339 list.append(QString("Off")); // txt_software_setlabel_val_off |
341 //HbDataFormModelItem::ComboBoxItem, hbTrId("txt_software_setlabel_autocheck_for_updates")); |
340 list.append(QString("On in home network")); // txt_software_setlabel_val_on_in_home_network |
342 |
341 mAutoUpdateItem->setContentWidgetData("items", list); |
343 // auto update selection values |
|
344 QStringList list; |
|
345 list.insert(0, QString("On")); |
|
346 //list.insert(0, hbTrId("txt_software_setlabel_val_on")); |
|
347 list.append(QString("Off")); |
|
348 //list.append(hbTrId("txt_software_setlabel_val_off")); |
|
349 list.append(QString("On in home network")); |
|
350 //list.append(hbTrId("txt_software_setlabel_val_on_in_home_network")); |
|
351 |
|
352 mAutoUpdateItem->setContentWidgetData("items", list); |
342 |
353 |
343 // connect data changes for launching the access point selection dialog |
354 // connect data changes for launching the access point selection dialog |
344 connect(mModel, SIGNAL(dataChanged(QModelIndex, QModelIndex)), |
355 connect(mModel, SIGNAL(dataChanged(QModelIndex, QModelIndex)), |
345 this, SLOT(toggleChange(QModelIndex, QModelIndex))); |
356 this, SLOT(toggleChange(QModelIndex, QModelIndex))); |
346 |
357 |
347 // connect to function called when data items are displayed |
358 // connect to function called when data items are displayed |
348 connect(mSettingsForm, SIGNAL(activated(QModelIndex)), |
359 connect(mSettingsForm, SIGNAL(activated(QModelIndex)), |
349 this, SLOT(activated(QModelIndex))); |
360 this, SLOT(activated(QModelIndex))); |
350 |
361 |
351 mSettingsForm->setModel(mModel); |
362 mSettingsForm->setModel(mModel); |
352 |
363 |
353 // set values for items |
364 // set values for items |
354 TRAPD(err, initializeFieldsL()); |
365 TRAPD(err, initializeFieldsL()); |
355 qt_symbian_throwIfError(err); |
366 qt_symbian_throwIfError(err); |
356 } |
367 } |
357 |
368 |
358 // ----------------------------------------------------------------------------- |
369 // ----------------------------------------------------------------------------- |
359 // ActionView::getInternetSnapIdL |
370 // ActionView::getInternetSnapIdL |
360 // ----------------------------------------------------------------------------- |
371 // ----------------------------------------------------------------------------- |