mirror of
https://github.com/qbittorrent/qBittorrent
synced 2025-07-11 15:56:17 -07:00
friendlyUnit: Properly replace spaces with non-breaking spaces
This commit is contained in:
parent
311b060c70
commit
f8213f5d56
2 changed files with 3 additions and 2 deletions
|
@ -356,9 +356,9 @@ QString Utils::Misc::friendlyUnit(qint64 bytesValue, bool isSpeed)
|
|||
return QCoreApplication::translate("misc", "Unknown", "Unknown (size)");
|
||||
QString ret;
|
||||
if (unit == SizeUnit::Byte)
|
||||
ret = QString::number(bytesValue) + " " + unitString(unit);
|
||||
ret = QString::number(bytesValue) + QString::fromUtf8(C_NON_BREAKING_SPACE) + unitString(unit);
|
||||
else
|
||||
ret = Utils::String::fromDouble(friendlyVal, friendlyUnitPrecision(unit)) + " " + unitString(unit);
|
||||
ret = Utils::String::fromDouble(friendlyVal, friendlyUnitPrecision(unit)) + QString::fromUtf8(C_NON_BREAKING_SPACE) + unitString(unit);
|
||||
if (isSpeed)
|
||||
ret += QCoreApplication::translate("misc", "/s", "per second");
|
||||
return ret;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue