Display coordinates

This commit is contained in:
T'JAMPENS QUENTIN p2406187 2025-06-20 09:16:07 +02:00
parent 2126a66c96
commit aed27c2483
3 changed files with 12 additions and 1 deletions

View File

@ -99,6 +99,8 @@ void MainWindow::loadPath()
if(!steps.isEmpty()) {
ui->stepTitle->setText(p->getStep().first().getTitle());
ui->LatitudeSpin->setValue(p->getStep().first().getLatitude());
ui->longitudeSpin->setValue(p->getStep().first().getLongitude());
}
int pathCount = path.length();

View File

@ -353,6 +353,9 @@
<property name="decimals">
<number>6</number>
</property>
<property name="maximum">
<double>90.000000000000000</double>
</property>
</widget>
</item>
</layout>
@ -376,6 +379,12 @@
<property name="decimals">
<number>6</number>
</property>
<property name="minimum">
<double>-180.000000000000000</double>
</property>
<property name="maximum">
<double>180.000000000000000</double>
</property>
</widget>
</item>
</layout>

View File

@ -41,7 +41,7 @@ Step::Step( QJsonObject &in)
QString gps = in["GPS"].toString();
QStringList parts = gps.split(" ", Qt::SkipEmptyParts);
QChar latDir = parts[0][0]; // c'est le premier QChar du QString t'as capté
QChar latDir = parts[0][0];
int latDeg = parts[1].toInt();
float latMin = parts[2].toFloat();
setLatitude(latDeg, latMin, latDir);