mirror of
https://github.com/tumic0/GPXSee.git
synced 2025-01-18 11:52:08 +01:00
Fixed zoom speed issue on touchpads
This commit is contained in:
parent
bfcc577f64
commit
e6547d92f0
@ -373,6 +373,12 @@ void PathView::zoom(const QPoint &pos, const Coordinates &c)
|
|||||||
void PathView::wheelEvent(QWheelEvent *event)
|
void PathView::wheelEvent(QWheelEvent *event)
|
||||||
{
|
{
|
||||||
qreal os, ns;
|
qreal os, ns;
|
||||||
|
static int deg = 0;
|
||||||
|
|
||||||
|
deg += event->delta() / 8;
|
||||||
|
if (qAbs(deg) < 15)
|
||||||
|
return;
|
||||||
|
deg = 0;
|
||||||
|
|
||||||
os = _map->zoom();
|
os = _map->zoom();
|
||||||
Coordinates c = _map->xy2ll(mapToScene(event->pos()));
|
Coordinates c = _map->xy2ll(mapToScene(event->pos()));
|
||||||
|
Loading…
x
Reference in New Issue
Block a user