Fix displaying & in the entry removal msgbox

This commit is contained in:
sewe2000 2023-05-15 21:17:23 +02:00 committed by Jonathan White
parent 029b4c25ac
commit deebcad59b

View File

@ -33,7 +33,7 @@ namespace GuiTools
QString prompt; QString prompt;
if (entries.size() == 1) { if (entries.size() == 1) {
prompt = QObject::tr("Do you really want to delete the entry \"%1\" for good?") prompt = QObject::tr("Do you really want to delete the entry \"%1\" for good?")
.arg(entries.first()->title().toHtmlEscaped()); .arg(entries.first()->title().toHtmlEscaped().replace("&", "&"));
} else { } else {
prompt = QObject::tr("Do you really want to delete %n entry(s) for good?", "", entries.size()); prompt = QObject::tr("Do you really want to delete %n entry(s) for good?", "", entries.size());
} }
@ -51,7 +51,7 @@ namespace GuiTools
QString prompt; QString prompt;
if (entries.size() == 1) { if (entries.size() == 1) {
prompt = QObject::tr("Do you really want to move entry \"%1\" to the recycle bin?") prompt = QObject::tr("Do you really want to move entry \"%1\" to the recycle bin?")
.arg(entries.first()->title().toHtmlEscaped()); .arg(entries.first()->title().toHtmlEscaped().replace("&", "&"));
} else { } else {
prompt = QObject::tr("Do you really want to move %n entry(s) to the recycle bin?", "", entries.size()); prompt = QObject::tr("Do you really want to move %n entry(s) to the recycle bin?", "", entries.size());
} }