From 2d6203bd21bc9efc0e365f962ba9bfaf9585830a Mon Sep 17 00:00:00 2001 From: Mark Vejvoda Date: Sun, 9 Jan 2011 09:32:32 +0000 Subject: [PATCH] - ftp progressbar calculation error fix --- source/glest_game/graphics/renderer.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/glest_game/graphics/renderer.cpp b/source/glest_game/graphics/renderer.cpp index a3426bf3..340b18a0 100644 --- a/source/glest_game/graphics/renderer.cpp +++ b/source/glest_game/graphics/renderer.cpp @@ -4168,7 +4168,7 @@ void Renderer::renderProgressBar(int size, int x, int y, Font2D *font, int custo string renderText = intToStr(static_cast(size)) + "%"; if(customWidth > 0) { if(size > 0) { - currentSize = customWidth * (size / 100); + currentSize = (int)((double)customWidth * ((double)size / 100.0)); } maxSize = customWidth; }