Commit 40d5c83e authored by Laurent Montel's avatar Laurent Montel 😁

Use QLatin1String

parent d9ac01b8
......@@ -212,7 +212,7 @@ void ThemeEditorPage::addExtraPage()
{
QString filename = QInputDialog::getText(this, i18n("Filename of extra page"), i18n("Filename:"));
if (!filename.trimmed().isEmpty()) {
if (!filename.endsWith(QStringLiteral(".html")) && !filename.endsWith(QStringLiteral(".css")) && !filename.endsWith(QStringLiteral(".js"))) {
if (!filename.endsWith(QLatin1String(".html")) && !filename.endsWith(QLatin1String(".css")) && !filename.endsWith(QLatin1String(".js"))) {
filename += QLatin1String(".html");
}
createExtraPage(filename);
......
......@@ -221,7 +221,7 @@ void ContactEditorPage::addExtraPage()
{
QString filename = QInputDialog::getText(this, i18n("Filename of extra page"), i18n("Filename:"));
if (!filename.trimmed().isEmpty()) {
if (!filename.endsWith(QStringLiteral(".html")) && !filename.endsWith(QStringLiteral(".css")) && !filename.endsWith(QStringLiteral(".js"))) {
if (!filename.endsWith(QLatin1String(".html")) && !filename.endsWith(QLatin1String(".css")) && !filename.endsWith(QLatin1String(".js"))) {
filename += QLatin1String(".html");
}
createExtraPage(filename);
......
......@@ -237,7 +237,7 @@ void ThemeEditorPage::addExtraPage()
{
QString filename = QInputDialog::getText(this, i18n("Filename of extra page"), i18n("Filename:"));
if (!filename.trimmed().isEmpty()) {
if (!filename.endsWith(QStringLiteral(".html")) && !filename.endsWith(QStringLiteral(".css")) && !filename.endsWith(QStringLiteral(".js"))) {
if (!filename.endsWith(QLatin1String(".html")) && !filename.endsWith(QLatin1String(".css")) && !filename.endsWith(QLatin1String(".js"))) {
filename += QLatin1String(".html");
}
createExtraPage(filename);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment