summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorLaszlo Papp <lpapp@kde.org>2013-01-10 03:03:28 +0100
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-04-17 13:03:06 +0200
commit9d2466d086dbe81e96bdb5bdd3767c9528e4c361 (patch)
tree131ce2e5b504f5086da7ddb709e5fb4c9d13ec6b /tests
parentf49af55a3d6f0483695a66662f23072c5002c773 (diff)
Remove the bad API for the distance unit of the ray
It is a bad API because of the following reasons: 1) fromPoint does not imply if it is a distance, direction, or something else from the point. 2) More importantly, it reads as a static method converting a point to a ray at first glance according to the other Qt API occurrences around. Change-Id: If92f6642138821916cda43dc33a8c3e84267c626 Reviewed-by: James Turner <james.turner@kdab.com> Reviewed-by: Samuel Rødal <samuel.rodal@digia.com> Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
Diffstat (limited to 'tests')
-rw-r--r--tests/auto/threed/qray3d/tst_qray3d.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/auto/threed/qray3d/tst_qray3d.cpp b/tests/auto/threed/qray3d/tst_qray3d.cpp
index 385ed236d..a1968be40 100644
--- a/tests/auto/threed/qray3d/tst_qray3d.cpp
+++ b/tests/auto/threed/qray3d/tst_qray3d.cpp
@@ -252,8 +252,8 @@ void tst_QRay3D::point()
QRay3D line(point, direction);
QVERIFY(fuzzyCompare(line.point(0.6), point_on_line_pos_0_6));
QVERIFY(fuzzyCompare(line.point(-7.2), point_on_line_neg_7_2));
- QVERIFY(fuzzyCompare(line.fromPoint(point_on_line_pos_0_6), 0.6));
- QVERIFY(fuzzyCompare(line.fromPoint(point_on_line_neg_7_2), -7.2));
+ QVERIFY(fuzzyCompare(line.projectedDistance(point_on_line_pos_0_6), 0.6));
+ QVERIFY(fuzzyCompare(line.projectedDistance(point_on_line_neg_7_2), -7.2));
}
void tst_QRay3D::contains_point_data()