Skip to content

Commit

Permalink
Cosmetic changes
Browse files Browse the repository at this point in the history
  • Loading branch information
pvuorela committed Jun 28, 2017
1 parent 1fc1865 commit 92b1646
Show file tree
Hide file tree
Showing 9 changed files with 23 additions and 30 deletions.
2 changes: 1 addition & 1 deletion libconnman-qt/counter.cpp
Expand Up @@ -47,7 +47,7 @@ Counter::~Counter()
m_manager->unregisterCounter(counterPath);
}

void Counter::serviceUsage(const QString &servicePath, const QVariantMap &counters, bool roaming)
void Counter::serviceUsage(const QString &servicePath, const QVariantMap &counters, bool roaming)
{
Q_EMIT counterChanged(servicePath, counters, roaming);

Expand Down
6 changes: 3 additions & 3 deletions libconnman-qt/counter.h
Expand Up @@ -36,9 +36,9 @@ class Counter : public QObject
Q_PROPERTY(bool running READ running WRITE setRunning NOTIFY runningChanged)

Q_DISABLE_COPY(Counter)
public:
explicit Counter(QObject *parent = 0);

public:
explicit Counter(QObject *parent = 0);
virtual ~Counter();

quint64 bytesReceived() const;
Expand Down Expand Up @@ -74,7 +74,7 @@ private Q_SLOTS:

friend class CounterAdaptor;

void serviceUsage(const QString &servicePath, const QVariantMap &counters, bool roaming);
void serviceUsage(const QString &servicePath, const QVariantMap &counters, bool roaming);
void release();

quint64 bytesInHome;
Expand Down
4 changes: 2 additions & 2 deletions libconnman-qt/networkmanager.h
Expand Up @@ -51,7 +51,7 @@ class NetworkManager : public QObject
Q_PROPERTY(QString GpsTechnology READ gpsTechnologyPath CONSTANT)

public:
NetworkManager(QObject* parent=0);
NetworkManager(QObject *parent = 0);
virtual ~NetworkManager();

bool isAvailable() const;
Expand Down Expand Up @@ -93,7 +93,7 @@ public Q_SLOTS:
void setOfflineMode(const bool &offlineMode);
void registerAgent(const QString &path);
void unregisterAgent(const QString &path);
void registerCounter(const QString &path, quint32 accuracy,quint32 period);
void registerCounter(const QString &path, quint32 accuracy, quint32 period);
void unregisterCounter(const QString &path);
QDBusObjectPath createSession(const QVariantMap &settings, const QString &sessionNotifierPath);
void destroySession(const QString &sessionAgentPath);
Expand Down
10 changes: 5 additions & 5 deletions libconnman-qt/networkservice.cpp
Expand Up @@ -262,10 +262,8 @@ NetworkService::Private::Private(NetworkService* parent) :

void NetworkService::Private::deleteProxy()
{
if (m_proxy) {
delete m_proxy;
m_proxy = NULL;
}
delete m_proxy;
m_proxy = 0;
}

NetworkService::Private::InterfaceProxy*
Expand Down Expand Up @@ -604,7 +602,9 @@ NetworkService::NetworkService(QObject* parent)
{
}

NetworkService::~NetworkService() {}
NetworkService::~NetworkService()
{
}

const QString NetworkService::name() const
{
Expand Down
6 changes: 2 additions & 4 deletions libconnman-qt/networksession.cpp
Expand Up @@ -26,10 +26,8 @@ void NetworkSession::createSession()
{
if (m_path.isEmpty())
return;
if (m_sessionAgent) {
delete m_sessionAgent;
m_sessionAgent = 0;
}

delete m_sessionAgent;
m_sessionAgent = new SessionAgent(m_path ,this);
connect(m_sessionAgent,SIGNAL(settingsUpdated(QVariantMap)),
this,SLOT(sessionSettingsUpdated(QVariantMap)));
Expand Down
6 changes: 2 additions & 4 deletions libconnman-qt/networktechnology.cpp
Expand Up @@ -45,10 +45,8 @@ void NetworkTechnology::init(const QString &path)
if (path != m_path) {
m_path = path;

if (m_technology) {
delete m_technology;
m_technology = 0;
}
delete m_technology;
m_technology = 0;

// Clear the property cache (only) if the path is becoming empty.
if (m_path.isEmpty()) {
Expand Down
12 changes: 6 additions & 6 deletions libconnman-qt/sessionagent.cpp
Expand Up @@ -117,16 +117,16 @@ void SessionAgent::update(const QVariantMap &settings)

void SessionAgent::onConnectFinished(QDBusPendingCallWatcher *call)
{
QDBusPendingReply<> reply = *call;
if (reply.isError())
qDebug() << reply.error().message();
QDBusPendingReply<> reply = *call;
if (reply.isError())
qDebug() << reply.error().message();

call->deleteLater();
call->deleteLater();
}

SessionNotificationAdaptor::SessionNotificationAdaptor(SessionAgent* parent)
: QDBusAbstractAdaptor(parent),
m_sessionAgent(parent)
: QDBusAbstractAdaptor(parent),
m_sessionAgent(parent)
{
}

Expand Down
2 changes: 1 addition & 1 deletion libconnman-qt/sessionagent.h
Expand Up @@ -19,7 +19,7 @@ class SessionAgent : public QObject
Q_OBJECT

public:
explicit SessionAgent(const QString &path,QObject* parent = 0);
explicit SessionAgent(const QString &path, QObject *parent = 0);
virtual ~SessionAgent();

void setAllowedBearers(const QStringList &bearers);
Expand Down
5 changes: 1 addition & 4 deletions plugin/technologymodel.h
Expand Up @@ -68,9 +68,7 @@ class TechnologyModel : public QAbstractListModel

Q_INVOKABLE int indexOf(const QString &dbusObjectPath) const;
Q_INVOKABLE NetworkService *get(int index) const;

public Q_SLOTS:
void requestScan();
Q_INVOKABLE void requestScan();

Q_SIGNALS:
void nameChanged(const QString &name);
Expand All @@ -82,7 +80,6 @@ public Q_SLOTS:
void technologiesChanged();
void countChanged();
void filterChanged();

void scanRequestFinished();

private:
Expand Down

0 comments on commit 92b1646

Please sign in to comment.