equal
deleted
inserted
replaced
1 // Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies). |
1 // Copyright (c) 2006-2010 Nokia Corporation and/or its subsidiary(-ies). |
2 // All rights reserved. |
2 // All rights reserved. |
3 // This component and the accompanying materials are made available |
3 // This component and the accompanying materials are made available |
4 // under the terms of "Eclipse Public License v1.0" |
4 // under the terms of "Eclipse Public License v1.0" |
5 // which accompanies this distribution, and is available |
5 // which accompanies this distribution, and is available |
6 // at the URL "http://www.eclipse.org/legal/epl-v10.html". |
6 // at the URL "http://www.eclipse.org/legal/epl-v10.html". |
237 { |
237 { |
238 // export event as a listing entry |
238 // export event as a listing entry |
239 TInt handle = aEventIndex + 1; // call history handles start from 1 |
239 TInt handle = aEventIndex + 1; // call history handles start from 1 |
240 |
240 |
241 TContactItemId contactId = aEvent.Contact(); |
241 TContactItemId contactId = aEvent.Contact(); |
|
242 |
|
243 if (contactId == KNullContactId && aEvent.RemoteParty() != KNullDesC) |
|
244 { |
|
245 // The S60 phonebook uses the remote party for the name, so if there isn't a name |
|
246 // there won't be a contact, so we only look up the contact if there is a Remote Party |
|
247 contactId = iClient.ExporterUtil().FindContactIdFromNumberL(aEvent.Number()); |
|
248 } |
|
249 |
242 if (contactId != KNullContactId) |
250 if (contactId != KNullContactId) |
243 { |
251 { |
244 // a contact is associated with the log event so read its name from the database |
252 // a contact is associated with the log event so read its name from the database |
245 RBuf name; |
253 RBuf name; |
246 TRAPD(error , name.Assign(iClient.ContactDbViews().GetContactNameFromIdL(contactId))); |
254 TRAPD(error , name.Assign(iClient.ContactDbViews().GetContactNameFromIdL(contactId))); |