summaryrefslogtreecommitdiffstats
path: root/src/widgets/qprogressbar.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/widgets/qprogressbar.cpp')
-rw-r--r--src/widgets/qprogressbar.cpp10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/widgets/qprogressbar.cpp b/src/widgets/qprogressbar.cpp
index bf40d9e45..d1300d3e2 100644
--- a/src/widgets/qprogressbar.cpp
+++ b/src/widgets/qprogressbar.cpp
@@ -429,8 +429,10 @@ void TQProgressBar::drawContents( TQPainter *p )
TQWMatrix oldMatrix = buffer.painter()->worldMatrix();
- TQStyleControlElementData ceData = populateControlElementDataFromWidget(this, TQStyleOption());
- TQStyle::ControlElementFlags elementFlags = getControlElementFlagsForObject(this, ceData.widgetObjectTypes, TQStyleOption());
+ const TQStyleControlElementData &ceData = populateControlElementDataFromWidget(this, TQStyleOption());
+ TQStyle::ControlElementFlags elementFlags = getControlElementFlagsForObject(this, TQStyleOption());
+
+ TQRect ceDataRectOrig = ceData.rect;
// Draw contents
if (m_orientation == TQt::Vertical) {
@@ -447,7 +449,7 @@ void TQProgressBar::drawContents( TQPainter *p )
buffer.painter()->setWorldMatrix(m, TRUE);
- ceData.rect = TQRect(ceData.rect.y(), ceData.rect.x(), ceData.rect.height(), ceData.rect.width());
+ const_cast<TQStyleControlElementData&>(ceData).rect = TQRect(ceData.rect.y(), ceData.rect.x(), ceData.rect.height(), ceData.rect.width());
}
style().drawControl(TQStyle::CE_ProgressBarContents, buffer.painter(), ceData, elementFlags,
@@ -461,6 +463,8 @@ void TQProgressBar::drawContents( TQPainter *p )
TQStyle::visualRect(style().subRect(TQStyle::SR_ProgressBarLabel, this), this ),
colorGroup(), flags);
}
+
+ const_cast<TQStyleControlElementData&>(ceData).rect = ceDataRectOrig;
}
#endif