Skip to content

Commit

Permalink
Core: Replace the migration dialog with a warning and formulate it le…
Browse files Browse the repository at this point in the history
…ss dramatic
  • Loading branch information
wwmayer committed Dec 19, 2024
1 parent 44065bf commit 897e669
Showing 1 changed file with 7 additions and 19 deletions.
26 changes: 7 additions & 19 deletions src/Gui/CommandDoc.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -122,26 +122,14 @@ void StdCmdOpen::activated(int iMsg)
return;
}

// Display the warning message
QMessageBox msgBox(QMessageBox::Warning,
QObject::tr("File Migration Warning"),
QObject::tr("This file was created with an older version of %1. "
"Origin axes had incorrect placements, which have now been corrected.\n\n"
QString msg = QObject::tr("This file was created with an older version of %1.\n"
"Origin axes had inconsistent placements between different coordinate systems,"
" which have now been harmonized.\n\n"
"However, if you save this file in the current version and reopen it in an"
" older version of %1, the origin axes will be misaligned. Additionally, "
"if your file references these origin axes, your file will likely be broken.")
.arg(QApplication::applicationName()),
QMessageBox::Ok);

QCheckBox* checkBox = new QCheckBox(QObject::tr("Don't show this warning again"));
msgBox.setCheckBox(checkBox);

msgBox.exec();

// Save preference if the user selects "Don't show again"
if (checkBox->isChecked()) {
grp->SetBool("ShowLCSMigrationWarning", false);
}
" older version of %1, the origin axes will be misaligned.")
.arg(QApplication::applicationName());
std::string str = msg.toStdString();
Base::Console().Warning(str.c_str());
}
};
// clang-format on
Expand Down

0 comments on commit 897e669

Please sign in to comment.