1
0
mirror of https://github.com/tumic0/GPXSee.git synced 2025-01-18 19:52:09 +01:00

Debug stuff

This commit is contained in:
Martin Tůma 2016-11-05 20:00:14 +01:00
parent 585ded6b1c
commit aac9bf024b
3 changed files with 16 additions and 3 deletions

View File

@ -111,7 +111,8 @@ SOURCES += src/main.cpp \
src/coordinates.cpp \
src/kmlparser.cpp \
src/fitparser.cpp \
src/format.cpp
src/format.cpp \
src/graph.cpp
RESOURCES += gpxsee.qrc
TRANSLATIONS = lang/gpxsee_cs.ts
macx {

9
src/graph.cpp Normal file
View File

@ -0,0 +1,9 @@
#include "graph.h"
QDebug operator<<(QDebug dbg, const GraphPoint &graphpoint)
{
dbg.nospace() << "GraphPoint(" << graphpoint.s() << ", "
<< graphpoint.t() << ", " << graphpoint.y() << ")";
return dbg.maybeSpace();
}

View File

@ -2,6 +2,7 @@
#define GRAPH_H
#include <QVector>
#include <QDebug>
#include <cmath>
enum GraphType {Distance, Time};
@ -27,6 +28,10 @@ private:
qreal _y;
};
Q_DECLARE_TYPEINFO(GraphPoint, Q_PRIMITIVE_TYPE);
QDebug operator<<(QDebug dbg, const GraphPoint &graphpoint);
class Graph : public QVector<GraphPoint>
{
public:
@ -44,6 +49,4 @@ private:
bool _time;
};
Q_DECLARE_TYPEINFO(GraphPoint, Q_PRIMITIVE_TYPE);
#endif // GRAPH_H