summaryrefslogtreecommitdiff
path: root/core/pim/addressbook
Unidiff
Diffstat (limited to 'core/pim/addressbook') (more/less context) (ignore whitespace changes)
-rw-r--r--core/pim/addressbook/addressbook.cpp12
1 files changed, 12 insertions, 0 deletions
diff --git a/core/pim/addressbook/addressbook.cpp b/core/pim/addressbook/addressbook.cpp
index 7c52ef2..75e539a 100644
--- a/core/pim/addressbook/addressbook.cpp
+++ b/core/pim/addressbook/addressbook.cpp
@@ -349,24 +349,36 @@ void AddressbookWindow::slotItemEdit()
349 editPersonal(); 349 editPersonal();
350 } else { 350 } else {
351 editEntry( EditEntry ); 351 editEntry( EditEntry );
352 } 352 }
353 } else { 353 } else {
354 QMessageBox::warning( this, tr("Contacts"), 354 QMessageBox::warning( this, tr("Contacts"),
355 tr("Can not edit data, currently syncing") ); 355 tr("Can not edit data, currently syncing") );
356 } 356 }
357} 357}
358 358
359void AddressbookWindow::slotItemDuplicate() 359void AddressbookWindow::slotItemDuplicate()
360{ 360{
361 if(!syncing)
362 {
363 Opie::OPimContact entry = m_abView->currentEntry();
364 entry.assignUid();
365 m_abView->addEntry( entry );
366 m_abView->setCurrentUid( entry.uid() );
367 }
368 else
369 {
370 QMessageBox::warning( this, tr("Contacts"),
371 tr("Can not edit data, currently syncing") );
372 }
361} 373}
362 374
363void AddressbookWindow::slotItemDelete() 375void AddressbookWindow::slotItemDelete()
364{ 376{
365 if(!syncing) { 377 if(!syncing) {
366 Opie::OPimContact tmpEntry = m_abView ->currentEntry(); 378 Opie::OPimContact tmpEntry = m_abView ->currentEntry();
367 379
368 // get a name, do the best we can... 380 // get a name, do the best we can...
369 QString strName = tmpEntry.fullName(); 381 QString strName = tmpEntry.fullName();
370 if ( strName.isEmpty() ) { 382 if ( strName.isEmpty() ) {
371 strName = tmpEntry.company(); 383 strName = tmpEntry.company();
372 if ( strName.isEmpty() ) 384 if ( strName.isEmpty() )