aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArmin Berres <armin.berres@basyskom.de>2010-06-25 14:56:37 +0200
committerJörgen Scheibengruber <jorgen.scheibengruber@nokia.com>2010-06-29 14:52:39 +0300
commitd331da9897c32d3223508180b01fb0866358f17d (patch)
tree8bd97850a881354e72f9caf3d29601aba0edbc53
parentab195b29651e5e4b0e0b6e71e1be55bde3c50172 (diff)
Changes: initialize pixmaps transparent/green
RevBy: Peter, Jörgen Details: In the release builds temporary pixmaps should be transparent and not visible at all. Optionally for debugging purposes they can be rendered in green.
-rw-r--r--src/corelib/theme/mtheme.cpp12
1 files changed, 10 insertions, 2 deletions
diff --git a/src/corelib/theme/mtheme.cpp b/src/corelib/theme/mtheme.cpp
index afcfc8ad..09440d5f 100644
--- a/src/corelib/theme/mtheme.cpp
+++ b/src/corelib/theme/mtheme.cpp
@@ -265,7 +265,11 @@ QPixmap *MTheme::pixmapCopy(const QString &id, const QSize &size)
} else {
result = new QPixmap(realSize);
}
- result->fill(QColor(128, 128, 128, 32));
+ if (instance()->d_ptr->showAsyncRequests) {
+ result->fill(QColor(0, 255, 0, 255));
+ } else {
+ result->fill(QColor(0, 0, 0, 0));
+ }
instance()->d_ptr->pixmapIdentifiers.insert(identifier, CachedPixmap(result, id, realSize));
instance()->d_ptr->themeDaemon->pixmapHandleSync(id, realSize);
@@ -292,7 +296,11 @@ const MScalableImage *MTheme::scalableImage(const QString &id, int left, int rig
if (!p) {
// we have to create temporary pixmap
QPixmap *result = new QPixmap(1, 1);
- result->fill(QColor(128, 128, 128, 32));
+ if (instance()->d_ptr->showAsyncRequests) {
+ result->fill(QColor(0, 255, 0, 255));
+ } else {
+ result->fill(QColor(0, 0, 0, 0));
+ }
instance()->d_ptr->pixmapIdentifiers.insert(pixmapidentifier, CachedPixmap(result, id, QSize(0, 0)));
instance()->d_ptr->themeDaemon->pixmapHandle(id, QSize(0, 0));