diff options
author | Olivier Goffart <olivier.goffart@nokia.com> | 2011-05-31 15:33:12 (GMT) |
---|---|---|
committer | Olivier Goffart <olivier.goffart@nokia.com> | 2011-05-31 15:33:12 (GMT) |
commit | 73fc68802d8c0c8d3d499b279782ce270f1c5bc6 (patch) | |
tree | 8cd7f54bc06864a741f0a2fd34412124c53e5953 /src/gui/painting | |
parent | 9e4ded47bc9e3fed3ee2a15e572603bb3f7b48fc (diff) | |
parent | 570f8970bea646055583671397c3d2706ac45004 (diff) | |
download | Qt-73fc68802d8c0c8d3d499b279782ce270f1c5bc6.zip Qt-73fc68802d8c0c8d3d499b279782ce270f1c5bc6.tar.gz Qt-73fc68802d8c0c8d3d499b279782ce270f1c5bc6.tar.bz2 |
Merge remote-tracking branch 'origin/4.7' into qt-4.8-from-4.7
Conflicts:
src/gui/text/qtextengine.cpp
src/gui/text/qtextengine_p.h
src/gui/text/qtextlayout.cpp
src/plugins/phonon/mmf/mmf.pro
src/plugins/s60/5_0/5_0.pro
tests/auto/qtextlayout/tst_qtextlayout.cpp
Diffstat (limited to 'src/gui/painting')
-rw-r--r-- | src/gui/painting/qgraphicssystemex_symbian.cpp | 36 | ||||
-rw-r--r-- | src/gui/painting/qgraphicssystemex_symbian_p.h | 3 |
2 files changed, 32 insertions, 7 deletions
diff --git a/src/gui/painting/qgraphicssystemex_symbian.cpp b/src/gui/painting/qgraphicssystemex_symbian.cpp index b53353b..4469704 100644 --- a/src/gui/painting/qgraphicssystemex_symbian.cpp +++ b/src/gui/painting/qgraphicssystemex_symbian.cpp @@ -44,10 +44,39 @@ #include "private/qbackingstore_p.h" #include "private/qapplication_p.h" -#include <QDebug> +#include <e32property.h> QT_BEGIN_NAMESPACE +static bool bcm2727Initialized = false; +static bool bcm2727 = false; + +bool QSymbianGraphicsSystemEx::hasBCM2727() +{ + if (bcm2727Initialized) + return bcm2727; + + const TUid KIvePropertyCat = {0x2726beef}; + enum TIvePropertyChipType { + EVCBCM2727B1 = 0x00000000, + EVCBCM2763A0 = 0x04000100, + EVCBCM2763B0 = 0x04000102, + EVCBCM2763C0 = 0x04000103, + EVCBCM2763C1 = 0x04000104, + EVCBCMUnknown = 0x7fffffff + }; + + TInt chipType = EVCBCMUnknown; + if (RProperty::Get(KIvePropertyCat, 0, chipType) == KErrNone) { + if (chipType == EVCBCM2727B1) + bcm2727 = true; + } + + bcm2727Initialized = true; + + return bcm2727; +} + void QSymbianGraphicsSystemEx::releaseCachedGpuResources() { // Do nothing here @@ -64,11 +93,6 @@ void QSymbianGraphicsSystemEx::releaseAllGpuResources() } } -bool QSymbianGraphicsSystemEx::hasBCM2727() -{ - return !QApplicationPrivate::instance()->useTranslucentEGLSurfaces; -} - void QSymbianGraphicsSystemEx::forceToRaster(QWidget *window) { if (window && window->isWindow()) { diff --git a/src/gui/painting/qgraphicssystemex_symbian_p.h b/src/gui/painting/qgraphicssystemex_symbian_p.h index c1d1bdf..1f2a7c6 100644 --- a/src/gui/painting/qgraphicssystemex_symbian_p.h +++ b/src/gui/painting/qgraphicssystemex_symbian_p.h @@ -62,9 +62,10 @@ class QWidget; class Q_GUI_EXPORT QSymbianGraphicsSystemEx : public QGraphicsSystemEx { public: + static bool hasBCM2727(); + virtual void releaseCachedGpuResources(); virtual void releaseAllGpuResources(); - virtual bool hasBCM2727(); virtual void forceToRaster(QWidget *window); }; |