1
0
mirror of https://github.com/tumic0/GPXSee.git synced 2025-07-17 12:24:24 +02:00

Better (consistent) graph definition

This commit is contained in:
2017-05-22 18:42:23 +02:00
parent e96cee2ea8
commit dba6291f3e
3 changed files with 14 additions and 20 deletions

View File

@ -31,22 +31,6 @@ private:
Q_DECLARE_TYPEINFO(GraphPoint, Q_PRIMITIVE_TYPE);
QDebug operator<<(QDebug dbg, const GraphPoint &point);
class Graph : public QVector<GraphPoint>
{
public:
Graph() : QVector<GraphPoint>() {_time = true;}
void append(const GraphPoint &p)
{
if (std::isnan(p.t()))
_time = false;
QVector<GraphPoint>::append(p);
}
bool hasTime() const {return _time;}
private:
bool _time;
};
typedef QVector<GraphPoint> Graph;
#endif // GRAPH_H