[maemo-developers] QtMobility Contacts

From: Felipe Crochik felipe at crochik.com
Date: Fri May 28 17:08:41 EEST 2010
Hi Antonio, 

 

I am missing some step. Would you be so kind to check the code bellow? I
can't figure out how to find the QContactPresence detail. By the
documentation I assumed linkedDetailUris would give me some hint on how to
get but it didn't .

 

.

    details = m_contact.details(QContactOnlineAccount::DefinitionName);
    foreach ( QContactOnlineAccount account, details ) {
        qDebug() << "Online Acount: " << account.serviceProvider() << ": "
<< account.accountUri();
        foreach ( QString str, account.contexts() ) qDebug() << ">> Context:
" << str;
        foreach ( QString str, account.capabilities() ) qDebug() << ">>
Capability: " << str;
        foreach ( QString str, account.linkedDetailUris()) qDebug() << ">>
LinkedDetailUri: " << str;
        foreach ( QString str, account.subTypes()) qDebug() << ">> SubType:
" << str;
        
        // how do I get the QContactPresence detail?
        // .
        QContactPresence presence;
        qDebug() << "Presence: " << presence.presenceState();
    }
 

 

The linkDetailUris, capabilities, contexts and subtypes seem to always be
empty for my contacts. Is there a way to check to check for the contact
manager if the field is supported? Just to make sure to not expect for it. 

 

Thanks again

Felipe

 

  _____  

From: Antonio Aloisio [mailto:antonio.aloisio at gmail.com] 
Sent: Friday, May 28, 2010 9:46 AM
To: Felipe Crochik
Cc: maemo-developers at maemo.org
Subject: Re: QtMobility Contacts

 

Hi Felipe,

 

1. I am using the QContactDetailFilter to get a list of contacts on the n900
and it takes "very" long compared to the standard address book and uses up
all the cpu. I don't have too many contacts on my address book (about 300).
It does not seem to matter the match criteria and/or the number of records
that actually get filtered (it takes about the same time to get all records
or just one). Any similar experiences? Any way to improve on it?

It's slow and it takes very long time because it convert every OSSO ABook
contact to

QContact then it applies the filters.

Native filtering is not complete so it's turned off.

 

2. Is it possible to get the contact presence status using QtMobility? By
what I found you need to get the QContactOnlineAccountand then supposedly
you would find the QContactPresence using linkedDetailUris on
QContactOnlineAccount but linkedDetailUris does not return any strings. The
contact manager does not seem to support the QContactGlobalPresence detail.
Am I doing anything wrong? How can I find out if the user is online on skype
for example?

 If the contact has not been added manually from the user, the
QContactPresence::FieldPresenceState field should contains the presence
status.

 The QContactGlobalPresence is not yet supported.

 

Regards,

Antonio

_______________________________________________
maemo-developers mailing list
maemo-developers at maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.maemo.org/pipermail/maemo-developers/attachments/20100528/4e0364c9/attachment.htm>
More information about the maemo-developers mailing list