summaryrefslogtreecommitdiffstats
path: root/gui/progressbar.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'gui/progressbar.cpp')
-rw-r--r--gui/progressbar.cpp12
1 files changed, 8 insertions, 4 deletions
diff --git a/gui/progressbar.cpp b/gui/progressbar.cpp
index 83de4d13b..a4d132932 100644
--- a/gui/progressbar.cpp
+++ b/gui/progressbar.cpp
@@ -156,11 +156,15 @@ int GUIProgressBar::Update(void)
cur -= min;
min = 0;
- if (cur < min) cur = min;
- if (cur > max) cur = max;
+ if (cur < min)
+ cur = min;
+ if (cur > max)
+ cur = max;
- if (max == 0) pos = 0;
- else pos = (cur * mRenderW) / max;
+ if (max == 0)
+ pos = 0;
+ else
+ pos = (cur * mRenderW) / max;
if (pos == mLastPos)
return 0;