equal
deleted
inserted
replaced
298 void CntCollectionView::newGroup() |
298 void CntCollectionView::newGroup() |
299 { |
299 { |
300 HbInputDialog *popup = new HbInputDialog(); |
300 HbInputDialog *popup = new HbInputDialog(); |
301 popup->setAttribute(Qt::WA_DeleteOnClose, true); |
301 popup->setAttribute(Qt::WA_DeleteOnClose, true); |
302 |
302 |
|
303 HbLineEdit *lineEdit = popup->lineEdit(); |
|
304 lineEdit->setInputMethodHints(Qt::ImhNoPredictiveText); |
|
305 |
303 popup->setPromptText(hbTrId("txt_phob_title_new_group_name")); |
306 popup->setPromptText(hbTrId("txt_phob_title_new_group_name")); |
304 popup->clearActions(); |
307 popup->clearActions(); |
305 HbAction* primaryAction = new HbAction(hbTrId("txt_phob_button_create")); |
308 HbAction* primaryAction = new HbAction(hbTrId("txt_phob_button_create")); |
306 popup->addAction(primaryAction); |
309 popup->addAction(primaryAction); |
307 |
310 |
334 QList<QContactLocalId> contactsList = getContactManager()->contactIds(filter); |
337 QList<QContactLocalId> contactsList = getContactManager()->contactIds(filter); |
335 QSet<QContactLocalId> contactsSet = contactsList.toSet(); |
338 QSet<QContactLocalId> contactsSet = contactsList.toSet(); |
336 |
339 |
337 // Select some contact(s) to add to the group |
340 // Select some contact(s) to add to the group |
338 QString groupNameCreated(mHandledContact->displayLabel()); |
341 QString groupNameCreated(mHandledContact->displayLabel()); |
339 mFetchView->setDetails(HbParameterLengthLimiter(hbTrId("txt_phob_subtitle_1_group")).arg(groupNameCreated), |
342 mFetchView->setDetails(HbParameterLengthLimiter(hbTrId("txt_phob_title_members_of_1_group")).arg(groupNameCreated), |
340 hbTrId("txt_common_button_save")); |
343 hbTrId("txt_common_button_save")); |
341 mFetchView->displayContacts(CntFetchContacts::popup, |
344 mFetchView->displayContacts(CntFetchContacts::popup, |
342 HbAbstractItemView::MultiSelection, |
345 HbAbstractItemView::MultiSelection, |
343 contactsSet); |
346 contactsSet); |
344 } |
347 } |
386 HbLabel *headingLabel = new HbLabel(); |
389 HbLabel *headingLabel = new HbLabel(); |
387 headingLabel->setPlainText(HbParameterLengthLimiter(hbTrId("txt_phob_dialog_delete_1_group")).arg(name)); |
390 headingLabel->setPlainText(HbParameterLengthLimiter(hbTrId("txt_phob_dialog_delete_1_group")).arg(name)); |
388 |
391 |
389 HbMessageBox::question(hbTrId("txt_phob_dialog_only_group_will_be_removed_contac") |
392 HbMessageBox::question(hbTrId("txt_phob_dialog_only_group_will_be_removed_contac") |
390 , this, SLOT(handleDeleteGroup(HbAction*)), |
393 , this, SLOT(handleDeleteGroup(HbAction*)), |
391 hbTrId("txt_phob_button_delete"), hbTrId("txt_common_button_cancel"), headingLabel); |
394 hbTrId("txt_common_button_delete"), hbTrId("txt_common_button_cancel"), headingLabel); |
392 } |
395 } |
393 |
396 |
394 void CntCollectionView::handleDeleteGroup(HbAction* action) |
397 void CntCollectionView::handleDeleteGroup(HbAction* action) |
395 { |
398 { |
396 HbMessageBox *note = static_cast<HbMessageBox*>(sender()); |
399 HbMessageBox *note = static_cast<HbMessageBox*>(sender()); |