Save step info
This commit is contained in:
parent
c591f2dbdb
commit
992874a603
@ -131,6 +131,7 @@ void MainWindow::loadStep(Step s) {
|
||||
ui->stepTitle->setText(s.getTitle());
|
||||
ui->LatitudeSpin->setValue(s.getLatitude());
|
||||
ui->longitudeSpin->setValue(s.getLongitude());
|
||||
ui->responseSpin->setValue(s.getResponse());
|
||||
|
||||
for(int i = 0; i < s.getTexte().length(); i++) {
|
||||
QString q = s.getPersonnage().at(i) + ": " + s.getTexte().at(i);
|
||||
@ -276,9 +277,8 @@ void MainWindow::on_validateBtn_clicked()
|
||||
currentPath->setDifficulty(ui->diffSpin->value());
|
||||
currentPath->setDuration(ui->durationSpin->value());
|
||||
|
||||
Step currentStep = currentPath->getStep().at(ui->stepNumber->value()-1);
|
||||
currentPath->getStep()[ui->stepNumber->value()-1].setTitle(ui->stepTitle->text());
|
||||
currentPath->getStep()[ui->stepNumber->value()-1].setResponse(ui->responseSpin->value());
|
||||
|
||||
currentStep.setTitle(ui->stepTitle->text());
|
||||
currentStep.setResponse(ui->responseSpin->value());
|
||||
}
|
||||
|
||||
|
||||
2
path.cpp
2
path.cpp
@ -45,7 +45,7 @@ QString Path::getImage() const
|
||||
return image;
|
||||
}
|
||||
|
||||
QList<Step> Path::getStep() const
|
||||
QList<Step>& Path::getStep()
|
||||
{
|
||||
return step;
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user