diff options
author | Qt Continuous Integration System <qt-info@nokia.com> | 2010-07-05 08:21:33 (GMT) |
---|---|---|
committer | Qt Continuous Integration System <qt-info@nokia.com> | 2010-07-05 08:21:33 (GMT) |
commit | 4e349cbea021bd504eb8c1575463fd8ee9ba937b (patch) | |
tree | 2bd548b7f958a3e27b593272b31e8574474da738 | |
parent | 76aad35bd9f699c966295738095d245a5e7a6457 (diff) | |
parent | d2b17542aabb4236022ce7edf5f005cc6ebfc0e1 (diff) | |
download | Qt-4e349cbea021bd504eb8c1575463fd8ee9ba937b.zip Qt-4e349cbea021bd504eb8c1575463fd8ee9ba937b.tar.gz Qt-4e349cbea021bd504eb8c1575463fd8ee9ba937b.tar.bz2 |
Merge branch '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-1 into 4.7-integration
* '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-1:
Warn when drawPixmapFragments is called with an invalid source rect
Fix build failure with cs2009q3 toolchain.
-rw-r--r-- | src/gui/painting/qpainter.cpp | 9 | ||||
-rw-r--r-- | src/plugins/bearer/icd/qicdengine.cpp | 10 | ||||
-rw-r--r-- | src/plugins/bearer/icd/qicdengine.h | 4 |
3 files changed, 16 insertions, 7 deletions
diff --git a/src/gui/painting/qpainter.cpp b/src/gui/painting/qpainter.cpp index 2ea6673..9dadbd5 100644 --- a/src/gui/painting/qpainter.cpp +++ b/src/gui/painting/qpainter.cpp @@ -8969,6 +8969,15 @@ void QPainter::drawPixmapFragments(const PixmapFragment *fragments, int fragment if (!d->engine) return; +#ifndef QT_NO_DEBUG + for (int i = 0; i < fragmentCount; ++i) { + QRectF sourceRect(fragments[i].sourceLeft, fragments[i].sourceTop, + fragments[i].width, fragments[i].height); + if (!(QRectF(pixmap.rect()).contains(sourceRect))) + qWarning("QPainter::drawPixmapFragments - the source rect is not contained by the pixmap's rectangle"); + } +#endif + if (d->engine->isExtended()) { d->extended->drawPixmapFragments(fragments, fragmentCount, pixmap, hints); } else { diff --git a/src/plugins/bearer/icd/qicdengine.cpp b/src/plugins/bearer/icd/qicdengine.cpp index 3033140..0083380 100644 --- a/src/plugins/bearer/icd/qicdengine.cpp +++ b/src/plugins/bearer/icd/qicdengine.cpp @@ -327,10 +327,10 @@ void QIcdEngine::deleteConfiguration(const QString &iap_id) } -static uint32_t getNetworkAttrs(bool is_iap_id, - const QString &iap_id, - const QString &iap_type, - QString security_method) +static quint32 getNetworkAttrs(bool is_iap_id, + const QString &iap_id, + const QString &iap_type, + QString security_method) { guint network_attr = 0; dbus_uint32_t cap = 0; @@ -368,7 +368,7 @@ static uint32_t getNetworkAttrs(bool is_iap_id, if (is_iap_id) network_attr |= ICD_NW_ATTR_IAPNAME; - return (uint32_t)network_attr; + return quint32(network_attr); } diff --git a/src/plugins/bearer/icd/qicdengine.h b/src/plugins/bearer/icd/qicdengine.h index 2f9f8ed..1b291eb 100644 --- a/src/plugins/bearer/icd/qicdengine.h +++ b/src/plugins/bearer/icd/qicdengine.h @@ -69,11 +69,11 @@ public: QString service_type; QString service_id; - uint32_t service_attrs; + quint32 service_attrs; // Network attributes for this IAP, this is the value returned by icd and // passed to it when connecting. - uint32_t network_attrs; + quint32 network_attrs; }; inline IcdNetworkConfigurationPrivate *toIcdConfig(QNetworkConfigurationPrivatePointer ptr) |