Bug 109494 - Adding address book link and using name from address book causes name to be blank
Summary: Adding address book link and using name from address book causes name to be b...
Status: RESOLVED FIXED
Alias: None
Product: kopete
Classification: Applications
Component: libkopete (show other bugs)
Version: unspecified
Platform: Compiled Sources Linux
: NOR normal
Target Milestone: ---
Assignee: Kopete Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-07-22 23:32 UTC by Sean Lynch
Modified: 2005-08-25 21:25 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Sean Lynch 2005-07-22 23:32:16 UTC
Version:            (using KDE Devel)
Installed from:    Compiled sources

If I right click on one of my contacts and go to properties, then set an them with an Address Book Link and select Use addressbook name under the Display Name Source, the name will be blank when you hit OK.

If you go back to properties, change to From Contact, hit OK, go back again and set to Use addressbook name, it will work.

Also, if you set the address book link, click ok, then go back and set the name from address book, it will work.

Seems to be something with doing both at the same time.  I did not test to see if the picture settings were the same.
Comment 1 Sean Lynch 2005-08-06 18:56:28 UTC
Would also maybe be a good idea to add an Apply button to this widget, especially until the bug is resolved.. that way you wouldn't have to reopen the dialog twice to use the workaround.

I looked around and I guess all that has to do be done is change the OK|Cancel to OK|Apply|Cancel in both locations in kopetelviprops.cpp and connect the signal applyClicked() to the slotOkClicked slot ... but I have never coded on KDE and just started reading a QT book.
Comment 2 Olivier Goffart 2005-08-25 21:25:30 UTC
SVN commit 453283 by ogoffart:

fix Bug 109494: Adding address book link and using name from address book causes name to be blank 
BUG: 109494
CCMAIL: mattr@kde.org


 M  +4 -2      kopetelviprops.cpp  


--- branches/KDE/3.5/kdenetwork/kopete/kopete/contactlist/kopetelviprops.cpp #453282:453283
@@ -414,6 +414,10 @@
 
 void KopeteMetaLVIProps::slotOkClicked()
 {
+	// update meta contact's UID
+	item->metaContact()->setMetaContactId( mAddressBookUid );	
+	//this has to be done first, in the case something is synced with KABC   (see bug 109494)
+	
 	// set custom display name
 	if( mainWidget->edtDisplayName->text() != item->metaContact()->customDisplayName() )
 		item->metaContact()->setDisplayName( mainWidget->edtDisplayName->text() );
@@ -450,8 +454,6 @@
 		item->metaContact()->setIcon( mainWidget->icnbUnknown->icon(),
 			Kopete::ContactListElement::Unknown );
 	}
-	// update meta contact's UID
-	item->metaContact()->setMetaContactId( mAddressBookUid );	
 
 	mNotificationProps->storeCurrentCustoms();
 }