Mobile: use value semantics for DiveObjectHelper in qmlmanager.cpp

Instead of creating a pointer-to-DiveObjectHelper in commitChanges,
use a normal object. Thus, we don't have to think about ownership
issues with respect to this object.

Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
Berthold Stoeger 2019-08-13 09:35:18 +02:00 committed by bstoeger
parent 0026aa3955
commit feb11f6f5f
2 changed files with 30 additions and 30 deletions

View file

@ -228,10 +228,10 @@ private:
qreal m_lastDevicePixelRatio;
QElapsedTimer timer;
bool alreadySaving;
bool checkDate(DiveObjectHelper *myDive, struct dive * d, QString date);
bool checkLocation(DiveObjectHelper *myDive, struct dive *d, QString location, QString gps);
bool checkDuration(DiveObjectHelper *myDive, struct dive *d, QString duration);
bool checkDepth(DiveObjectHelper *myDive, struct dive *d, QString depth);
bool checkDate(const DiveObjectHelper &myDive, struct dive *d, QString date);
bool checkLocation(const DiveObjectHelper &myDive, struct dive *d, QString location, QString gps);
bool checkDuration(const DiveObjectHelper &myDive, struct dive *d, QString duration);
bool checkDepth(const DiveObjectHelper &myDive, struct dive *d, QString depth);
bool currentGitLocalOnly;
Q_INVOKABLE DCDeviceData *m_device_data;
QString m_progressMessage;