Improve conversion of bytes to human readable string

Fixes issues like showing 0 MiB when the value is just slightly less then 1 MiB.
This commit is contained in:
eelke 2024-04-12 13:26:10 +02:00
parent db2594a87c
commit 5bdd3fa95d
7 changed files with 125 additions and 44 deletions

View file

@ -87,7 +87,8 @@ SOURCES += \
catalog/PgLanguage.cpp \
catalog/PgAcl.cpp \
catalog/PgSequence.cpp \
catalog/PgSequenceContainer.cpp
catalog/PgSequenceContainer.cpp \
utils/HumanReadableBytes.cpp
HEADERS += \
Pglablib.h \
@ -119,7 +120,7 @@ HEADERS += \
ui/catalog/tables/TableNode.h \
ui/catalog/tables/TableSize.h \
ui/catalog/tables/TableTreeBuilder.h \
util.h \
util.h \
SqlFormattingUtils.h \
catalog/PgCatalogTypes.h \
catalog/PgKeywordList.h \
@ -162,7 +163,8 @@ HEADERS += \
catalog/PgLanguage.h \
catalog/PgAcl.h \
catalog/PgSequence.h \
catalog/PgSequenceContainer.h
catalog/PgSequenceContainer.h \
utils/HumanReadableBytes.h
unix {
target.path = /usr/lib