mirror of
https://github.com/tumic0/GPXSee.git
synced 2025-06-07 18:53:02 +02:00
Compare commits
No commits in common. "cee68671c2f0b4d62ea624f664ba7c0df4e180cc" and "92b9f4958fbce52df6dc1330c94ce457328d33d4" have entirely different histories.
cee68671c2
...
92b9f4958f
@ -28,9 +28,6 @@ public:
|
||||
|
||||
ToolTip info(bool extended) const;
|
||||
|
||||
const QColor color() const {return _pen.color();}
|
||||
const QString &name() const {return _area.name();}
|
||||
|
||||
protected:
|
||||
void hoverEnterEvent(QGraphicsSceneHoverEvent *event);
|
||||
void hoverLeaveEvent(QGraphicsSceneHoverEvent *event);
|
||||
|
@ -1,4 +1,3 @@
|
||||
#include <cmath>
|
||||
#include <QFontMetrics>
|
||||
#include <QPainter>
|
||||
#include "font.h"
|
||||
|
@ -1,4 +1,3 @@
|
||||
#include <cmath>
|
||||
#include <QPainter>
|
||||
#include "font.h"
|
||||
#include "legenditem.h"
|
||||
|
@ -29,9 +29,6 @@ public:
|
||||
|
||||
ToolTip info(bool extended) const;
|
||||
|
||||
const QColor color() const {return _pen.color();}
|
||||
const QString &name() const {return _name;}
|
||||
|
||||
signals:
|
||||
void triggered();
|
||||
|
||||
|
@ -159,10 +159,6 @@ void MapView::updateLegend()
|
||||
for (int i = 0; i < _routes.size(); i++)
|
||||
addLegendEntry(_routes.at(i));
|
||||
}
|
||||
if (_showAreas) {
|
||||
for (int i = 0; i < _areas.size(); i++)
|
||||
addLegendEntry(_areas.at(i));
|
||||
}
|
||||
}
|
||||
|
||||
void MapView::addLegendEntry(const PathItem *ti)
|
||||
@ -171,12 +167,6 @@ void MapView::addLegendEntry(const PathItem *ti)
|
||||
? QFileInfo(ti->file()).fileName() : ti->name());
|
||||
}
|
||||
|
||||
void MapView::addLegendEntry(const PlaneItem *plane)
|
||||
{
|
||||
if (!plane->name().isEmpty())
|
||||
_legend->addItem(plane->color(), plane->name());
|
||||
}
|
||||
|
||||
PathItem *MapView::addTrack(const Track &track)
|
||||
{
|
||||
if (!track.isValid()) {
|
||||
@ -264,10 +254,8 @@ void MapView::addArea(const Area &area)
|
||||
_ar |= ai->bounds();
|
||||
_areas.append(ai);
|
||||
|
||||
if (_showAreas) {
|
||||
if (_showAreas)
|
||||
addPOI(_poi->points(ai->bounds()));
|
||||
addLegendEntry(ai);
|
||||
}
|
||||
}
|
||||
|
||||
void MapView::addWaypoints(const QVector<Waypoint> &waypoints)
|
||||
@ -307,10 +295,8 @@ MapItem *MapView::addMap(MapAction *map)
|
||||
_ar |= mi->bounds();
|
||||
_areas.append(mi);
|
||||
|
||||
if (_showAreas) {
|
||||
if (_showAreas)
|
||||
addPOI(_poi->points(mi->bounds()));
|
||||
addLegendEntry(mi);
|
||||
}
|
||||
|
||||
return mi;
|
||||
}
|
||||
@ -1344,8 +1330,6 @@ void MapView::useStyles(bool use)
|
||||
_areas.at(i)->updateStyle();
|
||||
for (int i = 0; i < _waypoints.size(); i++)
|
||||
_waypoints.at(i)->updateStyle();
|
||||
|
||||
updateLegend();
|
||||
}
|
||||
|
||||
void MapView::setMarkerColor(const QColor &color)
|
||||
|
@ -169,7 +169,6 @@ private:
|
||||
void skipColor() {_palette.nextColor();}
|
||||
void setHidpi(bool hidpi);
|
||||
void addLegendEntry(const PathItem *path);
|
||||
void addLegendEntry(const PlaneItem *plane);
|
||||
void updateLegend();
|
||||
|
||||
void mouseMoveEvent(QMouseEvent *event);
|
||||
|
@ -20,9 +20,6 @@ public:
|
||||
virtual void setPenStyle(Qt::PenStyle style) = 0;
|
||||
virtual void setDigitalZoom(int zoom) = 0;
|
||||
virtual void updateStyle() {}
|
||||
|
||||
virtual const QColor color() const = 0;
|
||||
virtual const QString &name() const = 0;
|
||||
};
|
||||
|
||||
#endif // PLANEITEM_H
|
||||
|
Loading…
x
Reference in New Issue
Block a user