-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathRaceViewer.hpp
More file actions
47 lines (32 loc) · 926 Bytes
/
RaceViewer.hpp
File metadata and controls
47 lines (32 loc) · 926 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
#ifndef __RACEVIEWER_HPP__
#define __RACEVIEWER_HPP__
#include "ExtensibleEllipseItem.hpp"
#include "DBModule/GeoCoordinate.hpp"
#include "Map/MapView.hpp"
#include <QtGui>
class ResizableView : public QGraphicsView
{
public:
explicit ResizableView(QWidget *parent);
protected:
virtual void wheelEvent(QWheelEvent *event);
};
class RaceViewer : public QDialog
{
Q_OBJECT
public:
explicit RaceViewer(const QList<GeoCoordinate>& racePoints,
QWidget *parent = 0);
// Getter
QList< QPair<QTime, QTime> > laps(void) const;
public slots:
virtual void accept(void);
private:
void cutLaps(void);
QList<GeoCoordinate> mPoints;
QList< QPair<QTime, QTime> > mLaps;
QGraphicsScene* scene;
ResizableView* view;
QGraphicsEllipseItem* marker;
};
#endif /* __RACEVIEWER_HPP__ */