~ci-train-bot/online-accounts-api/online-accounts-api-ubuntu-zesty-2222

« back to all changes in this revision

Viewing changes to src/lib/OnlineAccounts/dbus_interface.cpp

  • Committer: Bileto Bot
  • Author(s): Alberto Mardegan
  • Date: 2016-11-10 09:13:15 UTC
  • mfrom: (26.4.27 providers-1627001)
  • Revision ID: ci-train-bot@canonical.com-20161110091315-imfazs4gg2mn3mea
Add provider information to public API

Allow clients to retrieve the list of available service providers, consisting of translated display name and icon URL.
Also, add a service() method to the Account class, to get the data associated with each account. (LP: #1627001, #1638769)

Approved by: Alexandre Abreu

Show diffs side-by-side

added added

removed removed

Lines of Context:
22
22
 
23
23
#include <QDBusMetaType>
24
24
#include <QDebug>
 
25
#include <QVariantMap>
25
26
#include <climits>
26
27
 
27
28
using namespace OnlineAccounts;
37
38
 
38
39
    qDBusRegisterMetaType<AccountInfo>();
39
40
    qDBusRegisterMetaType<QList<AccountInfo>>();
 
41
    qDBusRegisterMetaType<QList<QVariantMap>>();
40
42
 
41
43
    bool ok = connect("AccountChanged", "s(ua{sv})",
42
44
                      this, SLOT(onAccountChanged(const QString&,const OnlineAccounts::AccountInfo&)));