[Pkg-running-devel] [openambit] 38/131: Moved initialization of data members to constructor (Do not rely on c++11 support in compiler...)
Christian Perrier
bubulle at moszumanska.debian.org
Thu Jul 17 20:19:09 UTC 2014
This is an automated email from the git hooks/post-receive script.
bubulle pushed a commit to branch master
in repository openambit.
commit 6d3e7b54e6d64d80cdad193d394d1b70477e1c6c
Author: Emil Ljungdahl <emil at kratern.se>
Date: Sat Jan 11 14:09:49 2014 +0100
Moved initialization of data members to constructor
(Do not rely on c++11 support in compiler...)
---
src/openambit/logentry.cpp | 5 ++++-
src/openambit/logentry.h | 6 +++---
src/openambit/mainwindow.cpp | 4 +++-
src/openambit/mainwindow.h | 4 ++--
src/openambit/movescount.cpp | 3 ++-
src/openambit/movescount.h | 2 +-
6 files changed, 15 insertions(+), 9 deletions(-)
diff --git a/src/openambit/logentry.cpp b/src/openambit/logentry.cpp
index b4c8654..6ff627d 100644
--- a/src/openambit/logentry.cpp
+++ b/src/openambit/logentry.cpp
@@ -21,7 +21,10 @@
*/
#include "logentry.h"
-LogEntry::LogEntry()
+LogEntry::LogEntry() :
+ deviceInfo(NULL),
+ personalSettings(NULL),
+ logEntry(NULL)
{
}
diff --git a/src/openambit/logentry.h b/src/openambit/logentry.h
index 23dc3e9..3267b68 100644
--- a/src/openambit/logentry.h
+++ b/src/openambit/logentry.h
@@ -36,9 +36,9 @@ public:
QString device;
QDateTime time;
- ambit_device_info_t *deviceInfo = NULL;
- ambit_personal_settings_t *personalSettings = NULL;
- ambit_log_entry_t *logEntry = NULL;
+ ambit_device_info_t *deviceInfo;
+ ambit_personal_settings_t *personalSettings;
+ ambit_log_entry_t *logEntry;
signals:
public slots:
diff --git a/src/openambit/mainwindow.cpp b/src/openambit/mainwindow.cpp
index a341ef4..e7f5c24 100644
--- a/src/openambit/mainwindow.cpp
+++ b/src/openambit/mainwindow.cpp
@@ -29,7 +29,9 @@
MainWindow::MainWindow(QWidget *parent) :
QMainWindow(parent),
- ui(new Ui::MainWindow)
+ ui(new Ui::MainWindow),
+ movesCount(NULL),
+ currentLogMessageRow(NULL)
{
ui->setupUi(this);
diff --git a/src/openambit/mainwindow.h b/src/openambit/mainwindow.h
index 3984c1e..2a54470 100644
--- a/src/openambit/mainwindow.h
+++ b/src/openambit/mainwindow.h
@@ -82,7 +82,7 @@ private:
DeviceManager *deviceManager;
LogStore logStore;
MovesCountXML movesCountXML;
- MovesCount *movesCount = NULL;
+ MovesCount *movesCount;
QThread deviceWorkerThread;
class LogMessageRow : public QHBoxLayout
@@ -104,7 +104,7 @@ private:
QLabel *textLabel;
};
- LogMessageRow *currentLogMessageRow = NULL;
+ LogMessageRow *currentLogMessageRow;
};
#endif // MAINWINDOW_H
diff --git a/src/openambit/movescount.cpp b/src/openambit/movescount.cpp
index 5a1b311..7d82434 100644
--- a/src/openambit/movescount.cpp
+++ b/src/openambit/movescount.cpp
@@ -197,7 +197,8 @@ void MovesCount::recheckAuthorization()
getDeviceSettings();
}
-MovesCount::MovesCount()
+MovesCount::MovesCount() :
+ firmwareCheckReply(NULL)
{
this->manager = new QNetworkAccessManager(this);
}
diff --git a/src/openambit/movescount.h b/src/openambit/movescount.h
index ebc410c..fd29340 100644
--- a/src/openambit/movescount.h
+++ b/src/openambit/movescount.h
@@ -85,7 +85,7 @@ private:
ambit_device_info_t device_info;
QNetworkAccessManager *manager;
- QNetworkReply *firmwareCheckReply = NULL;
+ QNetworkReply *firmwareCheckReply;
MovesCountJSON jsonParser;
};
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-running/openambit.git
More information about the Pkg-running-devel
mailing list