--- C:\projects\qt_wk52\src\gui\styles\qs60style_s60.cpp 2010-12-29 10:55:58.000000000 +-0200 +++ K:\sf\mw\qt\src\gui\styles\qs60style_s60.cpp 2011-01-21 13:32:43.000000000 +-0200 @@ -46,13 +46,13 @@ #include "qstyle.h" #include "private/qt_s60_p.h" #include "private/qpixmap_s60_p.h" #include "private/qcore_symbian_p.h" #include "qapplication.h" #include "qsettings.h" - +#include "qdesktopwidget.h" #include "qpluginloader.h" #include "qlibraryinfo.h" #include "private/qs60style_feedbackinterface_p.h" #include #include @@ -1391,26 +1391,27 @@ return result; } QPixmap QS60StylePrivate::backgroundTexture() { bool createNewBackground = false; + TRect clientRect = (static_cast(S60->appUi())->ApplicationRect()); if (!m_background) { createNewBackground = true; } else { //if background brush does not match screensize, re-create it - if (m_background->width() != S60->screenWidthInPixels || - m_background->height() != S60->screenHeightInPixels) { + if (m_background->width() != clientRect.Width() || + m_background->height() != clientRect.Height()) { delete m_background; createNewBackground = true; } } if (createNewBackground) { QPixmap background = part(QS60StyleEnums::SP_QsnBgScreen, - QSize(S60->screenWidthInPixels, S60->screenHeightInPixels), 0, SkinElementFlags()); + QSize(clientRect.Width(), clientRect.Height()), 0, SkinElementFlags()); m_background = new QPixmap(background); } return *m_background; } QSize QS60StylePrivate::screenSize() @@ -1424,13 +1425,12 @@ } #ifdef Q_WS_S60 void QS60StylePrivate::handleDynamicLayoutVariantSwitch() { clearCaches(QS60StylePrivate::CC_LayoutChange); - setBackgroundTexture(qApp); setActiveLayout(); refreshUI(); foreach (QWidget *widget, QApplication::allWidgets()) widget->ensurePolished(); }