From e6e5da5de3d0f5b1864ba45215c83308b6c5cc80 Mon Sep 17 00:00:00 2001 From: Lionel Chauvin Date: Sun, 9 Aug 2009 08:52:09 +0200 Subject: progress bar at 100% is better drawn (fix division issue with int value) --- src/urlbar.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/urlbar.cpp b/src/urlbar.cpp index 28c63b78..1b1fbc54 100644 --- a/src/urlbar.cpp +++ b/src/urlbar.cpp @@ -225,7 +225,7 @@ void UrlBar::paintEvent(QPaintEvent *event) painter.setPen(Qt::transparent); QRect backgroundRect = lineEdit()->frameGeometry(); - int mid = backgroundRect.width() / 100 * m_progress; + int mid = backgroundRect.width() * m_progress / 100; QRect progressRect(backgroundRect.x(), backgroundRect.y(), mid, backgroundRect.height()); painter.drawRect(progressRect); painter.end(); -- cgit v1.2.1