Merge branch 'main' into 'dev'
# Conflicts: # mainwindow.cpp
This commit is contained in:
commit
af4426191f
@ -23,7 +23,8 @@ MainWindow::MainWindow(QWidget *parent)
|
|||||||
{
|
{
|
||||||
ui->setupUi(this);
|
ui->setupUi(this);
|
||||||
indexPath++;
|
indexPath++;
|
||||||
//currentPath = new Path();
|
currentPath = new Path();
|
||||||
|
|
||||||
|
|
||||||
connect(ui->titleEdit, &QLineEdit::editingFinished, this, [this]() {
|
connect(ui->titleEdit, &QLineEdit::editingFinished, this, [this]() {
|
||||||
static QString previousText;
|
static QString previousText;
|
||||||
@ -54,6 +55,7 @@ MainWindow::MainWindow(QWidget *parent)
|
|||||||
|
|
||||||
connect(ui->actionEditUndo, &QAction::triggered, undoStack, &QUndoStack::undo);
|
connect(ui->actionEditUndo, &QAction::triggered, undoStack, &QUndoStack::undo);
|
||||||
connect(ui->actionEditRedo, &QAction::triggered, undoStack, &QUndoStack::redo);
|
connect(ui->actionEditRedo, &QAction::triggered, undoStack, &QUndoStack::redo);
|
||||||
|
currentPath->getStep().append(Step());
|
||||||
}
|
}
|
||||||
|
|
||||||
MainWindow::~MainWindow()
|
MainWindow::~MainWindow()
|
||||||
@ -564,10 +566,8 @@ void MainWindow::on_validateBtn_clicked()
|
|||||||
currentPath->setLength(ui->lengthSpin->value());
|
currentPath->setLength(ui->lengthSpin->value());
|
||||||
currentPath->setDifficulty(ui->diffSpin->value());
|
currentPath->setDifficulty(ui->diffSpin->value());
|
||||||
currentPath->setDuration(ui->durationSpin->value());
|
currentPath->setDuration(ui->durationSpin->value());
|
||||||
|
|
||||||
currentPath->getStep()[ui->stepNumber->value()-1].setTitle(ui->stepTitle->text());
|
currentPath->getStep()[ui->stepNumber->value()-1].setTitle(ui->stepTitle->text());
|
||||||
currentPath->getStep()[ui->stepNumber->value()-1].setResponse(ui->responseSpin->value());
|
currentPath->getStep()[ui->stepNumber->value()-1].setResponse(ui->responseSpin->value());
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void MainWindow::loadAndExportPaths(QStringList fichiers) {
|
void MainWindow::loadAndExportPaths(QStringList fichiers) {
|
||||||
|
|||||||
2
path.cpp
2
path.cpp
@ -85,6 +85,8 @@ void Path::setImage(const QString &newImage)
|
|||||||
image = newImage;
|
image = newImage;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Path::Path(){}
|
||||||
|
|
||||||
Path::Path(QFile *file){
|
Path::Path(QFile *file){
|
||||||
if (!file->open(QIODevice::ReadOnly)) {
|
if (!file->open(QIODevice::ReadOnly)) {
|
||||||
qWarning() << "Could not open file:" << file->errorString();
|
qWarning() << "Could not open file:" << file->errorString();
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user