From bea613d8ba11a64ccf36a01735f2839894ca9476 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Mon, 25 May 2015 20:43:53 +0300 Subject: Fix some issues in safe OpenGL renderer after last changes. --- src/gui/widgets/progressindicator.cpp | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'src/gui/widgets/progressindicator.cpp') diff --git a/src/gui/widgets/progressindicator.cpp b/src/gui/widgets/progressindicator.cpp index a3df73b8a..cdbbc7335 100644 --- a/src/gui/widgets/progressindicator.cpp +++ b/src/gui/widgets/progressindicator.cpp @@ -82,5 +82,13 @@ void ProgressIndicator::draw(Graphics *graphics) void ProgressIndicator::safeDraw(Graphics *graphics) { - ProgressIndicator::draw(graphics); + BLOCK_START("ProgressIndicator::draw") + if (mIndicator) + { + // Draw the indicator centered on the widget + const int x = (mDimension.width - 32) / 2; + const int y = (mDimension.height - 32) / 2; + mIndicator->draw(graphics, x, y); + } + BLOCK_END("ProgressIndicator::draw") } -- cgit v1.2.3-70-g09d2