diff options
author | Sami Merila <sami.merila@nokia.com> | 2010-03-22 13:07:51 (GMT) |
---|---|---|
committer | Sami Merila <sami.merila@nokia.com> | 2010-03-22 13:07:51 (GMT) |
commit | 781e4d6190362818482864947a90d230fd700b06 (patch) | |
tree | ac894929dee53846bba38d0af4232cba94eea5b8 /src/gui | |
parent | 669c8042fa78c539cdefec87c85bce91e561871d (diff) | |
download | Qt-781e4d6190362818482864947a90d230fd700b06.zip Qt-781e4d6190362818482864947a90d230fd700b06.tar.gz Qt-781e4d6190362818482864947a90d230fd700b06.tar.bz2 |
QS60Style: Housekeeping
Remove unnecessary #include, remove unnecessary integer, correct
spelling issues in comments and replace tabs with spaces.
Reviewed-by: Alessandro Portale
Diffstat (limited to 'src/gui')
-rw-r--r-- | src/gui/styles/qs60style.cpp | 12 | ||||
-rw-r--r-- | src/gui/styles/qs60style_p.h | 2 | ||||
-rw-r--r-- | src/gui/styles/qs60style_s60.cpp | 4 |
3 files changed, 8 insertions, 10 deletions
diff --git a/src/gui/styles/qs60style.cpp b/src/gui/styles/qs60style.cpp index ed2074a..ec8b468 100644 --- a/src/gui/styles/qs60style.cpp +++ b/src/gui/styles/qs60style.cpp @@ -61,7 +61,6 @@ #include "qscrollarea.h" #include "qscrollbar.h" #include "qtabbar.h" -#include "qtablewidget.h" #include "qtableview.h" #include "qtextedit.h" #include "qtoolbar.h" @@ -1009,7 +1008,6 @@ void QS60Style::drawComplexControl(ComplexControl control, const QStyleOptionCom QS60StylePrivate::SE_SliderGrooveVertical; QS60StylePrivate::drawSkinElement(grooveElement, painter, sliderGroove, flags); } else { - const QRect sliderGroove = subControlRect(control, optionSlider, SC_SliderGroove, widget); const QPoint sliderGrooveCenter = sliderGroove.center(); const bool horizontal = optionSlider->orientation == Qt::Horizontal; painter->save(); @@ -1136,7 +1134,7 @@ void QS60Style::drawComplexControl(ComplexControl control, const QStyleOptionCom drawPrimitive(pe, &toolButton, painter, widget); } - if (toolBtn->text.length()>0 || + if (toolBtn->text.length() > 0 || !toolBtn->icon.isNull()) { const int frameWidth = pixelMetric(PM_DefaultFrameWidth, option, widget); toolButton.rect = button.adjusted(frameWidth, frameWidth, -frameWidth, -frameWidth); @@ -2316,7 +2314,7 @@ void QS60Style::drawPrimitive(PrimitiveElement element, const QStyleOption *opti (option->state & State_Open) ? QS60StyleEnums::SP_QgnIndiHlColSuper : QS60StyleEnums::SP_QgnIndiHlExpSuper; int minDimension = qMin(option->rect.width(), option->rect.height()); QRect iconRect(option->rect.topLeft(), QSize(minDimension, minDimension)); - const int magicTweak = 3; + const int magicTweak = 3; int resizeValue = minDimension >> 1; if (!QS60StylePrivate::isTouchSupported()) { minDimension += resizeValue; // Adjust the icon bigger because of empty space in svg icon. @@ -2461,9 +2459,9 @@ QSize QS60Style::sizeFromContents(ContentsType ct, const QStyleOption *opt, #ifndef QT_NO_COMBOBOX case CT_ComboBox: { // Fixing Ui design issues with too wide QComboBoxes and greedy SizeHints - // Make sure, that the combobox says within the screen. + // Make sure, that the combobox stays within the screen. const QSize desktopContentSize = QApplication::desktop()->availableGeometry().size() - -QSize(pixelMetric(PM_LayoutLeftMargin) + pixelMetric(PM_LayoutRightMargin), 0); + - QSize(pixelMetric(PM_LayoutLeftMargin) + pixelMetric(PM_LayoutRightMargin), 0); sz = QCommonStyle::sizeFromContents(ct, opt, csz, widget). boundedTo(desktopContentSize); } @@ -3249,7 +3247,7 @@ bool QS60Style::eventFilter(QObject *object, QEvent *event) /*! \internal - Handle the timer \a event. + Handle the timer \a event. */ void QS60Style::timerEvent(QTimerEvent *event) { diff --git a/src/gui/styles/qs60style_p.h b/src/gui/styles/qs60style_p.h index 84f50ea..df6f582 100644 --- a/src/gui/styles/qs60style_p.h +++ b/src/gui/styles/qs60style_p.h @@ -428,7 +428,7 @@ public: SE_ToolBarButton, SE_ToolBarButtonPressed, SE_PanelBackground, - SE_ScrollBarHandlePressedHorizontal, //only for 5.0+ + SE_ScrollBarHandlePressedHorizontal, SE_ScrollBarHandlePressedVertical, SE_ButtonInactive, SE_Editor, diff --git a/src/gui/styles/qs60style_s60.cpp b/src/gui/styles/qs60style_s60.cpp index bb862a3..0f014c1 100644 --- a/src/gui/styles/qs60style_s60.cpp +++ b/src/gui/styles/qs60style_s60.cpp @@ -755,7 +755,7 @@ QPixmap QS60StyleModeSpecifics::createSkinnedGraphicsLX( if (drawn) result = fromFbsBitmap(background, NULL, flags, targetSize); - // if drawing fails in skin server, just ignore the background (probably OOM occured) + // if drawing fails in skin server, just ignore the background (probably OOM case) CleanupStack::PopAndDestroy(4, background); //background, dev, gc, bgContext // QS60WindowSurface::lockBitmapHeap(); @@ -787,7 +787,7 @@ QPixmap QS60StyleModeSpecifics::createSkinnedGraphicsLX( const int currentFrame = QS60StylePrivate::currentAnimationFrame(part); if (constructedFromTheme && aknAnimation && aknAnimation->BitmapAnimData()->FrameArray().Count() > 0) { - //Animation was created succesfully and contains frames, just fetch current frame + //Animation was created successfully and contains frames, just fetch current frame if(currentFrame >= aknAnimation->BitmapAnimData()->FrameArray().Count()) User::Leave(KErrOverflow); const CBitmapFrameData* frameData = aknAnimation->BitmapAnimData()->FrameArray().At(currentFrame); |