mirror of
https://github.com/tumic0/GPXSee.git
synced 2025-06-27 03:29:16 +02:00
Show the map elevation from the map DEM if available
This commit is contained in:
@ -471,7 +471,6 @@ void GUI::createActions()
|
||||
_drawHillShadingAction = new QAction(tr("Show hillshading"), this);
|
||||
_drawHillShadingAction->setMenuRole(QAction::NoRole);
|
||||
_drawHillShadingAction->setCheckable(true);
|
||||
_drawHillShadingAction->setEnabled(false);
|
||||
connect(_drawHillShadingAction, &QAction::triggered, _mapView,
|
||||
&MapView::drawHillShading);
|
||||
|
||||
@ -2249,8 +2248,7 @@ void GUI::updateDataDEMDownloadAction()
|
||||
void GUI::updateMapDEMDownloadAction()
|
||||
{
|
||||
_downloadMapDEMAction->setEnabled(!_dem->url().isEmpty()
|
||||
&& _map->usesDEM() && !_dem->checkTiles(_map->llBounds()));
|
||||
_drawHillShadingAction->setEnabled(_map->usesDEM());
|
||||
&& !_dem->checkTiles(_map->llBounds()));
|
||||
}
|
||||
|
||||
void GUI::setTimeType(TimeType type)
|
||||
|
@ -7,7 +7,6 @@
|
||||
#include <QClipboard>
|
||||
#include <QOpenGLWidget>
|
||||
#include <QGeoPositionInfoSource>
|
||||
#include "common/dem.h"
|
||||
#include "data/poi.h"
|
||||
#include "data/data.h"
|
||||
#include "map/map.h"
|
||||
@ -1181,9 +1180,7 @@ void MapView::mouseMoveEvent(QMouseEvent *event)
|
||||
{
|
||||
if (_cursorCoordinates->isVisible()) {
|
||||
Coordinates c(_map->xy2ll(mapToScene(event->pos())));
|
||||
DEM::lock();
|
||||
_cursorCoordinates->setCoordinates(c, DEM::elevation(c));
|
||||
DEM::unlock();
|
||||
_cursorCoordinates->setCoordinates(c, _map->elevation(c));
|
||||
}
|
||||
|
||||
QGraphicsView::mouseMoveEvent(event);
|
||||
|
Reference in New Issue
Block a user