mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-03-29 22:20:48 +00:00
Use corresponding SI/IEC units
This commit is contained in:
parent
8feccffec0
commit
9ffa923da6
@ -627,12 +627,12 @@ namespace gui
|
|||||||
usz divisor = 1;
|
usz divisor = 1;
|
||||||
#if defined(__APPLE__)
|
#if defined(__APPLE__)
|
||||||
constexpr multiplier = 1000;
|
constexpr multiplier = 1000;
|
||||||
|
static const QString s_units[]{"B", "kB", "MB", "GB", "TB", "PB"};
|
||||||
#else
|
#else
|
||||||
constexpr multiplier = 1024;
|
constexpr multiplier = 1024;
|
||||||
|
static const QString s_units[]{"B", "KiB", "MiB", "GiB", "TiB", "PiB"};
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
static const QString s_units[]{"B", "KB", "MB", "GB", "TB", "PB"};
|
|
||||||
|
|
||||||
while (byte_unit < std::size(s_units) - 1 && size / divisor >= multiplier)
|
while (byte_unit < std::size(s_units) - 1 && size / divisor >= multiplier)
|
||||||
{
|
{
|
||||||
byte_unit++;
|
byte_unit++;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user