Skip to content

Commit

Permalink
Use QStringLiteral to concatenate result and unit
Browse files Browse the repository at this point in the history
JJuiice authored and phoerious committed May 3, 2020
1 parent 1b18c5d commit ab6222a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/gui/entry/EntryModel.cpp
Original file line number Diff line number Diff line change
@@ -230,7 +230,7 @@ QVariant EntryModel::data(const QModelIndex& index, int role) const
for (int i = 0; i < unitsSize; i++) {
if (resultInt < 1024 || i == unitsSize - 1) {
resultInt = qRound(resultInt * 100) / 100.0;
result = QString::number(resultInt) + " " + units[i];
result = QStringLiteral("%1 %2").arg(QString::number(resultInt), units[i]);
break;
}
resultInt /= 1024.0;

0 comments on commit ab6222a

Please sign in to comment.