From ff439396a538ade7ab470d4993912da93342e5d1 Mon Sep 17 00:00:00 2001 From: "Lubomir I. Ivanov" Date: Mon, 19 Oct 2015 00:25:15 +0300 Subject: Print: remove the warning about editing bundled templates Bundled templates can no longer be edited, because copies are made in the user directory. The TemplateEdit special case warning is no longer relevant so it can be removed. Signed-off-by: Lubomir I. Ivanov Signed-off-by: Dirk Hohndel --- qt-ui/templateedit.cpp | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) (limited to 'qt-ui') diff --git a/qt-ui/templateedit.cpp b/qt-ui/templateedit.cpp index 83830047b..4964016b9 100644 --- a/qt-ui/templateedit.cpp +++ b/qt-ui/templateedit.cpp @@ -128,19 +128,12 @@ void TemplateEdit::on_colorpalette_currentIndexChanged(int index) void TemplateEdit::saveSettings() { - QStringList bundledTemplates; - bundledTemplates << "Flowlayout.html" << "One Dive.html" << "Six Dives.html" << "Table.html" << "Two Dives.html"; if ((*templateOptions) != newTemplateOptions || grantlee_template.compare(ui->plainTextEdit->toPlainText())) { QMessageBox msgBox(this); QString message = tr("Do you want to save your changes?"); bool templateChanged = false; - if (grantlee_template.compare(ui->plainTextEdit->toPlainText())) { - if (bundledTemplates.contains(printOptions->p_template) || (printOptions->p_template == "Default.html" && printOptions->type == print_options::STATISTICS)) { - msgBox.setIcon(QMessageBox::Warning); - message = tr("You are about to modify a template bundled with Subsurface.\n") + message; - } + if (grantlee_template.compare(ui->plainTextEdit->toPlainText())) templateChanged = true; - } msgBox.setText(message); msgBox.setStandardButtons(QMessageBox::Save | QMessageBox::Cancel); msgBox.setDefaultButton(QMessageBox::Cancel); -- cgit v1.2.3-70-g09d2