~unity-team/unity8/slim-greeter

« back to all changes in this revision

Viewing changes to tests/mocks/Unity/Indicators/fakeindicatorsmodel.cpp

  • Committer: Michael Terry
  • Date: 2015-02-12 15:45:21 UTC
  • mfrom: (1432.1.178 unity8)
  • Revision ID: michael.terry@canonical.com-20150212154521-1qpg3t501ljj88lj
MergeĀ fromĀ trunk

Show diffs side-by-side

added added

removed removed

Lines of Context:
21
21
#include "indicators.h"
22
22
 
23
23
FakeIndicatorsModel::FakeIndicatorsModel(QObject *parent)
24
 
    : QAbstractListModel(parent)
 
24
    : QAbstractListModel(parent),
 
25
      m_profile("phone")
25
26
{
26
27
    QObject::connect(this, SIGNAL(rowsInserted(const QModelIndex &, int, int)), this, SIGNAL(countChanged()));
27
28
    QObject::connect(this, SIGNAL(rowsRemoved(const QModelIndex &, int, int)), this, SIGNAL(countChanged()));
38
39
    return rowCount();
39
40
}
40
41
 
 
42
QString FakeIndicatorsModel::profile() const
 
43
{
 
44
    return m_profile;
 
45
}
 
46
 
 
47
void FakeIndicatorsModel::setProfile(const QString& profile)
 
48
{
 
49
    m_profile = profile;
 
50
    Q_EMIT profileChanged();
 
51
}
 
52
 
41
53
void FakeIndicatorsModel::load(const QString&)
42
54
{
43
55
}