build new class for information with pages

This commit is contained in:
2022-12-27 15:21:52 +01:00
parent 009d42f947
commit 1b0c5aa383
5 changed files with 168 additions and 110 deletions
-4
View File
@@ -141,9 +141,7 @@ CourseCorrection Navigation::getCourseCorrection() {
}
bool Navigation::addCurrentPosToRoute() {
std::cout << "Navigation::addCurrentPosToRoute: 1" << std::endl;
if (!this->currentPosition.isValid()) { return false; }
std::cout << "Navigation::addCurrentPosToRoute: 2" << std::endl;
// First Point
if (this->route->getRouteInfo().totalPoints == 0) {
@@ -151,7 +149,6 @@ bool Navigation::addCurrentPosToRoute() {
this->lastPoint = this->currentPosition;
return true;
}
std::cout << "Navigation::addCurrentPosToRoute: 3" << std::endl;
// Every Point after the first
if (MIN_DISTANCE_BETWEEN_POINTS <= this->currentPosition.distanceTo(this->lastPoint)) {
@@ -159,7 +156,6 @@ bool Navigation::addCurrentPosToRoute() {
this->lastPoint = this->currentPosition;
return true;
}
std::cout << "Navigation::addCurrentPosToRoute: 4" << std::endl;
return false;
}