summaryrefslogtreecommitdiff
path: root/src/units.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2016-02-07 16:18:13 +0300
committerAndrei Karas <akaras@inbox.ru>2016-02-07 16:18:13 +0300
commit9fe21fcd8883b37bdc30224822e6e42afb35b8f0 (patch)
tree798117abd4dc7e610997d59d530a96ddc1509f53 /src/units.cpp
parent4429cb14e9e187edef27aba692a4266733f79c17 (diff)
downloadmv-9fe21fcd8883b37bdc30224822e6e42afb35b8f0.tar.gz
mv-9fe21fcd8883b37bdc30224822e6e42afb35b8f0.tar.bz2
mv-9fe21fcd8883b37bdc30224822e6e42afb35b8f0.tar.xz
mv-9fe21fcd8883b37bdc30224822e6e42afb35b8f0.zip
Replace most static_cast<Type> to shorter versions from defines.
Diffstat (limited to 'src/units.cpp')
-rw-r--r--src/units.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/units.cpp b/src/units.cpp
index 6d7e2a49c..6fa0a963a 100644
--- a/src/units.cpp
+++ b/src/units.cpp
@@ -203,7 +203,7 @@ static std::string formatUnit(const int value, const int type)
else
{
double amount = ud.conversion * value;
- const unsigned int sz = static_cast<unsigned int>(ud.levels.size());
+ const unsigned int sz = CAST_U32(ud.levels.size());
// If only the first level is needed, act like mix if false
if (ud.mix && !ud.levels.empty() && ud.levels[1].count < amount)
@@ -211,7 +211,7 @@ static std::string formatUnit(const int value, const int type)
std::string output;
UnitLevel pl = ud.levels[0];
ul = ud.levels[1];
- int levelAmount = static_cast<int>(amount);
+ int levelAmount = CAST_S32(amount);
int nextAmount = 0;
if (ul.count)