From 995afbfc2ca81960ca840f50b2a837938a4f1d52 Mon Sep 17 00:00:00 2001 From: Sami Merila Date: Sun, 14 Feb 2010 12:16:00 +0200 Subject: Change a name of a variable to be more descriptive Currently when calculating a button content size, QS60Style has a variable called buttonWidth, which actually is the width of the content, not the button itself. Change this to buttonContentWidth. Reviewed-by: TrustMe --- src/gui/styles/qs60style.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/gui/styles/qs60style.cpp b/src/gui/styles/qs60style.cpp index 9025e5b..14e9b95 100644 --- a/src/gui/styles/qs60style.cpp +++ b/src/gui/styles/qs60style.cpp @@ -2559,11 +2559,11 @@ QRect QS60Style::subControlRect(ComplexControl control, const QStyleOptionComple if (const QStyleOptionSpinBox *spinbox = qstyleoption_cast(option)) { const int frameThickness = spinbox->frame ? pixelMetric(PM_SpinBoxFrameWidth, spinbox, widget) : 0; const int buttonMargin = spinbox->frame ? 2 : 0; - const int buttonWidth = QS60StylePrivate::pixelMetric(PM_ButtonIconSize) + 2 * buttonMargin; + const int buttonContentWidth = QS60StylePrivate::pixelMetric(PM_ButtonIconSize) + 2 * buttonMargin; QSize buttonSize; buttonSize.setHeight(qMax(8, spinbox->rect.height() - frameThickness)); //width should at least be equal to height - buttonSize.setWidth(qMax(buttonSize.height(), buttonWidth)); + buttonSize.setWidth(qMax(buttonSize.height(), buttonContentWidth)); buttonSize = buttonSize.expandedTo(QApplication::globalStrut()); const int y = frameThickness + spinbox->rect.y(); -- cgit v0.12