aboutsummaryrefslogtreecommitdiffstats
path: root/ui/qt/tcp_stream_dialog.cpp
diff options
context:
space:
mode:
authorGerald Combs <gerald@wireshark.org>2013-09-06 00:48:21 +0000
committerGerald Combs <gerald@wireshark.org>2013-09-06 00:48:21 +0000
commit29e03fe9d687b4bda065272fee7148645acd0cce (patch)
tree700b97db2801adb50550dfcc77ae17add1a549f2 /ui/qt/tcp_stream_dialog.cpp
parent6003d3b2f677d9e15f24169762d1747df0d7e1fe (diff)
Make graph movement pixel-based to match the GTK+ version.
svn path=/trunk/; revision=51796
Diffstat (limited to 'ui/qt/tcp_stream_dialog.cpp')
-rw-r--r--ui/qt/tcp_stream_dialog.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/ui/qt/tcp_stream_dialog.cpp b/ui/qt/tcp_stream_dialog.cpp
index ca488f0631..03d6a2a1f4 100644
--- a/ui/qt/tcp_stream_dialog.cpp
+++ b/ui/qt/tcp_stream_dialog.cpp
@@ -152,19 +152,19 @@ void TCPStreamDialog::keyPressEvent(QKeyEvent *event)
// XXX Use pixel sizes instead
case Qt::Key_Right:
case Qt::Key_L:
- h_pan = sp->xAxis->range().size() * 0.1;
+ h_pan = sp->xAxis->range().size() * 10.0 / sp->xAxis->axisRect()->width();
break;
case Qt::Key_Left:
case Qt::Key_H:
- h_pan = sp->xAxis->range().size() * -0.1;
+ h_pan = sp->xAxis->range().size() * -10.0 / sp->xAxis->axisRect()->width();
break;
case Qt::Key_Up:
case Qt::Key_K:
- v_pan = sp->yAxis->range().size() * 0.1;
+ v_pan = sp->yAxis->range().size() * 10.0 / sp->yAxis->axisRect()->height();
break;
case Qt::Key_Down:
case Qt::Key_J:
- v_pan = sp->yAxis->range().size() * -0.1;
+ v_pan = sp->yAxis->range().size() * -10.0 / sp->yAxis->axisRect()->height();
break;
case Qt::Key_Space: