From 35bc104729abf2653a23618603b55e2c316a870f Mon Sep 17 00:00:00 2001 From: Pierre Rossi Date: Thu, 16 Sep 2010 15:58:37 +0200 Subject: Ensure building of WebKit and QtConcurrent are disabled with SunCC. As there are versions of SunCC > 5.9 Reviewed-by: TrustMe --- configure | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure b/configure index 1ad0181..b933ac1 100755 --- a/configure +++ b/configure @@ -7051,7 +7051,7 @@ case "$XPLATFORM" in canBuildQtXmlPatterns="no" canBuildQtConcurrent="no" ;; - 5.9) + 5.*) canBuildWebKit="no" canBuildQtConcurrent="no" ;; -- cgit v0.12 From 3d7ef01963f2e15b7fd8fd23ffe22198ced00c87 Mon Sep 17 00:00:00 2001 From: Eskil Abrahamsen Blomfeldt Date: Thu, 16 Sep 2010 15:40:42 +0200 Subject: Compile on Mac Extern missing symbol Reviewed-by: Fabien Freling --- src/gui/kernel/qwidget_mac.mm | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/gui/kernel/qwidget_mac.mm b/src/gui/kernel/qwidget_mac.mm index 159c45d..1e2aa9f 100644 --- a/src/gui/kernel/qwidget_mac.mm +++ b/src/gui/kernel/qwidget_mac.mm @@ -114,6 +114,9 @@ QT_BEGIN_NAMESPACE +// qmainwindow.cpp +extern QMainWindowLayout *qt_mainwindow_layout(const QMainWindow *window); + #define XCOORD_MAX 16383 #define WRECT_MAX 8191 -- cgit v0.12 From e76564e8a3b305f4fe69135bebb409e357f29f57 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B8rn=20Erik=20Nilsen?= Date: Thu, 16 Sep 2010 12:38:51 +0200 Subject: Wrong bounding rect returned by QGraphicsEffect::boundingRect(). Regression after: f5c5e20a Problem was that the cached bounding rect was never invalidated. We can also remove the cached bounding rect in QGraphicsEffectSource because QGraphicsItem::childrenBoundingRect now clips by default. This basically means partially reverting above commit and invalidate whenever ItemClipsChildrenToShape flag changes. Auto test included. Task-number: Discovered while investigating QT-3633 Reviewed-by: samuel --- src/gui/graphicsview/qgraphicsitem.cpp | 18 +++++++-------- src/gui/graphicsview/qgraphicsitem_p.h | 14 ++++-------- tests/auto/qgraphicseffect/tst_qgraphicseffect.cpp | 26 ++++++++++++++++++++++ 3 files changed, 38 insertions(+), 20 deletions(-) diff --git a/src/gui/graphicsview/qgraphicsitem.cpp b/src/gui/graphicsview/qgraphicsitem.cpp index 2600d06..364fdbb 100644 --- a/src/gui/graphicsview/qgraphicsitem.cpp +++ b/src/gui/graphicsview/qgraphicsitem.cpp @@ -1272,7 +1272,7 @@ void QGraphicsItemPrivate::setParentItemHelper(QGraphicsItem *newParent, const Q Returns the bounding rect of this item's children (excluding itself). */ -void QGraphicsItemPrivate::childrenBoundingRectHelper(QTransform *x, QRectF *rect, bool doClip) +void QGraphicsItemPrivate::childrenBoundingRectHelper(QTransform *x, QRectF *rect) { Q_Q(QGraphicsItem); @@ -1302,7 +1302,7 @@ void QGraphicsItemPrivate::childrenBoundingRectHelper(QTransform *x, QRectF *rec } } - if (doClip && (flags & QGraphicsItem::ItemClipsChildrenToShape)){ + if (flags & QGraphicsItem::ItemClipsChildrenToShape){ if (x) *rect &= x->mapRect(q->boundingRect()); else @@ -1870,6 +1870,10 @@ void QGraphicsItem::setFlags(GraphicsItemFlags flags) // Item children clipping changes. Propagate the ancestor flag to // all children. d_ptr->updateAncestorFlag(ItemClipsChildrenToShape); + // The childrenBoundingRect is clipped to the boundingRect in case of ItemClipsChildrenToShape, + // which means we have to invalidate the cached childrenBoundingRect whenever this flag changes. + d_ptr->dirtyChildrenBoundingRect = 1; + d_ptr->markParentDirty(true); } if ((flags & ItemIgnoresTransformations) != (oldFlags & ItemIgnoresTransformations)) { @@ -11168,14 +11172,8 @@ QRectF QGraphicsItemEffectSourcePrivate::boundingRect(Qt::CoordinateSystem syste } QRectF rect = item->boundingRect(); - if (!item->d_ptr->children.isEmpty()) { - if (dirtyChildrenBoundingRect) { - childrenBoundingRect = QRectF(); - item->d_ptr->childrenBoundingRectHelper(0, &childrenBoundingRect, true); - dirtyChildrenBoundingRect = false; - } - rect |= childrenBoundingRect; - } + if (!item->d_ptr->children.isEmpty()) + rect |= item->childrenBoundingRect(); if (deviceCoordinates) { Q_ASSERT(info->painter); diff --git a/src/gui/graphicsview/qgraphicsitem_p.h b/src/gui/graphicsview/qgraphicsitem_p.h index cce9439..bc5e5ad 100644 --- a/src/gui/graphicsview/qgraphicsitem_p.h +++ b/src/gui/graphicsview/qgraphicsitem_p.h @@ -300,7 +300,7 @@ public: QDeclarativeListProperty childrenList(); void setParentItemHelper(QGraphicsItem *parent, const QVariant *newParentVariant, const QVariant *thisPointerVariant); - void childrenBoundingRectHelper(QTransform *x, QRectF *rect, bool doClip = true); + void childrenBoundingRectHelper(QTransform *x, QRectF *rect); void initStyleOption(QStyleOptionGraphicsItem *option, const QTransform &worldTransform, const QRegion &exposedRegion, bool allItems = false) const; QRectF effectiveBoundingRect() const; @@ -661,7 +661,7 @@ class QGraphicsItemEffectSourcePrivate : public QGraphicsEffectSourcePrivate { public: QGraphicsItemEffectSourcePrivate(QGraphicsItem *i) - : QGraphicsEffectSourcePrivate(), dirtyChildrenBoundingRect(true), item(i), info(0) + : QGraphicsEffectSourcePrivate(), item(i), info(0) {} inline void detach() @@ -712,9 +712,6 @@ public: QGraphicsEffect::PixmapPadMode mode) const; QRect paddedEffectRect(Qt::CoordinateSystem system, QGraphicsEffect::PixmapPadMode mode, const QRectF &sourceRect, bool *unpadded = 0) const; - mutable bool dirtyChildrenBoundingRect; - mutable QRectF childrenBoundingRect; - QGraphicsItem *item; QGraphicsItemPaintInfo *info; QTransform lastEffectTransform; @@ -872,12 +869,9 @@ inline void QGraphicsItemPrivate::markParentDirty(bool updateBoundingRect) #ifndef QT_NO_GRAPHICSEFFECT if (parentp->graphicsEffect) { if (updateBoundingRect) { - QGraphicsItemEffectSourcePrivate *sourcep = - static_cast(parentp->graphicsEffect->d_func() - ->source->d_func()); - parentp->dirtyChildrenBoundingRect = 1; + static_cast(parentp->graphicsEffect->d_func() + ->source->d_func())->invalidateCache(); parentp->notifyInvalidated = 1; - sourcep->invalidateCache(); } if (parentp->scene && parentp->graphicsEffect->isEnabled()) { parentp->dirty = 1; diff --git a/tests/auto/qgraphicseffect/tst_qgraphicseffect.cpp b/tests/auto/qgraphicseffect/tst_qgraphicseffect.cpp index e1bfb79..985d466 100644 --- a/tests/auto/qgraphicseffect/tst_qgraphicseffect.cpp +++ b/tests/auto/qgraphicseffect/tst_qgraphicseffect.cpp @@ -66,6 +66,7 @@ private slots: void source(); void boundingRectFor(); void boundingRect(); + void boundingRect2(); void draw(); void opacity(); void grayscale(); @@ -264,6 +265,31 @@ void tst_QGraphicsEffect::boundingRect() delete item; } +void tst_QGraphicsEffect::boundingRect2() +{ + CustomEffect *effect = new CustomEffect; + QGraphicsRectItem *root = new QGraphicsRectItem; + root->setGraphicsEffect(effect); + + QGraphicsRectItem *child = new QGraphicsRectItem; + QRectF childRect(0, 0, 100, 100); + child->setFlag(QGraphicsItem::ItemClipsChildrenToShape); + child->setRect(childRect); + child->setParentItem(root); + + QGraphicsRectItem *grandChild = new QGraphicsRectItem; + QRectF grandChildRect(0, 0, 200, 200); + grandChild->setRect(grandChildRect); + grandChild->setParentItem(child); + + // Make sure the effect's bounding rect is clipped to the child's bounding rect. + QCOMPARE(effect->boundingRect(), effect->boundingRectFor(childRect)); + + // Disable ItemClipsChildrenToShape; effect's bounding rect is no longer clipped. + child->setFlag(QGraphicsItem::ItemClipsChildrenToShape, false); + QCOMPARE(effect->boundingRect(), effect->boundingRectFor(childRect | grandChildRect)); +} + void tst_QGraphicsEffect::draw() { QGraphicsScene scene; -- cgit v0.12 From 9601abf3b03cfef589c092182bec3672fab6cde0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B8rn=20Erik=20Nilsen?= Date: Thu, 16 Sep 2010 16:37:24 +0200 Subject: QGraphicsItem::childrenBoundingRect behavior breaks QGraphicsEffect::sourceBoundingRect(). Context: QGraphicsEffect::sourceBoundingRect() returns: item->boundingRect() | item->childrenBoundingRect(); Problem was that item->childrenBoundingRect() adjusted the children's bounding rect with the children's ancestor effects (child -> root item), which means the source bounding rect was bigger than needed. We should only account for effects downwards in the hierarchy. root (has effect) | item (has effect) | child | grandChild Auto test included. Task-number: QT-3633, QT-3828 Reviewed-by: samuel --- src/gui/graphicsview/qgraphicsitem.cpp | 27 ++++++++++++++-------- src/gui/graphicsview/qgraphicsitem_p.h | 4 ++-- tests/auto/qgraphicseffect/tst_qgraphicseffect.cpp | 26 +++++++++++++++++++++ 3 files changed, 45 insertions(+), 12 deletions(-) diff --git a/src/gui/graphicsview/qgraphicsitem.cpp b/src/gui/graphicsview/qgraphicsitem.cpp index 364fdbb..b404692 100644 --- a/src/gui/graphicsview/qgraphicsitem.cpp +++ b/src/gui/graphicsview/qgraphicsitem.cpp @@ -1272,33 +1272,36 @@ void QGraphicsItemPrivate::setParentItemHelper(QGraphicsItem *newParent, const Q Returns the bounding rect of this item's children (excluding itself). */ -void QGraphicsItemPrivate::childrenBoundingRectHelper(QTransform *x, QRectF *rect) +void QGraphicsItemPrivate::childrenBoundingRectHelper(QTransform *x, QRectF *rect, QGraphicsItem *topMostEffectItem) { Q_Q(QGraphicsItem); QRectF childrenRect; QRectF *result = rect; rect = &childrenRect; + const bool setTopMostEffectItem = !topMostEffectItem; for (int i = 0; i < children.size(); ++i) { QGraphicsItem *child = children.at(i); QGraphicsItemPrivate *childd = child->d_ptr.data(); + if (setTopMostEffectItem) + topMostEffectItem = child; bool hasPos = !childd->pos.isNull(); if (hasPos || childd->transformData) { // COMBINE QTransform matrix = childd->transformToParent(); if (x) matrix *= *x; - *rect |= matrix.mapRect(child->d_ptr->effectiveBoundingRect()); + *rect |= matrix.mapRect(child->d_ptr->effectiveBoundingRect(topMostEffectItem)); if (!childd->children.isEmpty()) - childd->childrenBoundingRectHelper(&matrix, rect); + childd->childrenBoundingRectHelper(&matrix, rect, topMostEffectItem); } else { if (x) - *rect |= x->mapRect(child->d_ptr->effectiveBoundingRect()); + *rect |= x->mapRect(child->d_ptr->effectiveBoundingRect(topMostEffectItem)); else - *rect |= child->d_ptr->effectiveBoundingRect(); + *rect |= child->d_ptr->effectiveBoundingRect(topMostEffectItem); if (!childd->children.isEmpty()) - childd->childrenBoundingRectHelper(x, rect); + childd->childrenBoundingRectHelper(x, rect, topMostEffectItem); } } @@ -2804,6 +2807,8 @@ QRectF QGraphicsItemPrivate::effectiveBoundingRect(const QRectF &rect) const Q_Q(const QGraphicsItem); QGraphicsEffect *effect = graphicsEffect; if (scene && effect && effect->isEnabled()) { + if (scene->d_func()->views.isEmpty()) + return effect->boundingRectFor(rect); QRectF sceneRect = q->mapRectToScene(rect); QRectF sceneEffectRect; foreach (QGraphicsView *view, scene->views()) { @@ -2827,12 +2832,12 @@ QRectF QGraphicsItemPrivate::effectiveBoundingRect(const QRectF &rect) const \sa boundingRect() */ -QRectF QGraphicsItemPrivate::effectiveBoundingRect() const +QRectF QGraphicsItemPrivate::effectiveBoundingRect(QGraphicsItem *topMostEffectItem) const { #ifndef QT_NO_GRAPHICSEFFECT Q_Q(const QGraphicsItem); QRectF brect = effectiveBoundingRect(q_ptr->boundingRect()); - if (ancestorFlags & QGraphicsItemPrivate::AncestorClipsChildren) + if (ancestorFlags & QGraphicsItemPrivate::AncestorClipsChildren || topMostEffectItem == q) return brect; const QGraphicsItem *effectParent = parent; @@ -2843,8 +2848,10 @@ QRectF QGraphicsItemPrivate::effectiveBoundingRect() const const QRectF effectRectInParentSpace = effectParent->d_ptr->effectiveBoundingRect(brectInParentSpace); brect = effectParent->mapRectToItem(q, effectRectInParentSpace); } - if (effectParent->d_ptr->ancestorFlags & QGraphicsItemPrivate::AncestorClipsChildren) + if (effectParent->d_ptr->ancestorFlags & QGraphicsItemPrivate::AncestorClipsChildren + || topMostEffectItem == effectParent) { return brect; + } effectParent = effectParent->d_ptr->parent; } @@ -4719,7 +4726,7 @@ QRectF QGraphicsItem::childrenBoundingRect() const return d_ptr->childrenBoundingRect; d_ptr->childrenBoundingRect = QRectF(); - d_ptr->childrenBoundingRectHelper(0, &d_ptr->childrenBoundingRect); + d_ptr->childrenBoundingRectHelper(0, &d_ptr->childrenBoundingRect, 0); d_ptr->dirtyChildrenBoundingRect = 0; return d_ptr->childrenBoundingRect; } diff --git a/src/gui/graphicsview/qgraphicsitem_p.h b/src/gui/graphicsview/qgraphicsitem_p.h index bc5e5ad..77e4054 100644 --- a/src/gui/graphicsview/qgraphicsitem_p.h +++ b/src/gui/graphicsview/qgraphicsitem_p.h @@ -300,10 +300,10 @@ public: QDeclarativeListProperty childrenList(); void setParentItemHelper(QGraphicsItem *parent, const QVariant *newParentVariant, const QVariant *thisPointerVariant); - void childrenBoundingRectHelper(QTransform *x, QRectF *rect); + void childrenBoundingRectHelper(QTransform *x, QRectF *rect, QGraphicsItem *topMostEffectItem); void initStyleOption(QStyleOptionGraphicsItem *option, const QTransform &worldTransform, const QRegion &exposedRegion, bool allItems = false) const; - QRectF effectiveBoundingRect() const; + QRectF effectiveBoundingRect(QGraphicsItem *topMostEffectItem = 0) const; QRectF sceneEffectiveBoundingRect() const; QRectF effectiveBoundingRect(const QRectF &rect) const; diff --git a/tests/auto/qgraphicseffect/tst_qgraphicseffect.cpp b/tests/auto/qgraphicseffect/tst_qgraphicseffect.cpp index 985d466..07fa630 100644 --- a/tests/auto/qgraphicseffect/tst_qgraphicseffect.cpp +++ b/tests/auto/qgraphicseffect/tst_qgraphicseffect.cpp @@ -288,6 +288,32 @@ void tst_QGraphicsEffect::boundingRect2() // Disable ItemClipsChildrenToShape; effect's bounding rect is no longer clipped. child->setFlag(QGraphicsItem::ItemClipsChildrenToShape, false); QCOMPARE(effect->boundingRect(), effect->boundingRectFor(childRect | grandChildRect)); + + // Add root item to a scene, do the same tests as above. Results should be the same. + QGraphicsScene scene; + scene.addItem(root); + + child->setFlag(QGraphicsItem::ItemClipsChildrenToShape); + QCOMPARE(effect->boundingRect(), effect->boundingRectFor(childRect)); + + child->setFlag(QGraphicsItem::ItemClipsChildrenToShape, false); + QCOMPARE(effect->boundingRect(), effect->boundingRectFor(childRect | grandChildRect)); + + // Now add the scene to a view, results should be the same. + QGraphicsView view(&scene); + + child->setFlag(QGraphicsItem::ItemClipsChildrenToShape); + QCOMPARE(effect->boundingRect(), effect->boundingRectFor(childRect)); + + child->setFlag(QGraphicsItem::ItemClipsChildrenToShape, false); + QCOMPARE(effect->boundingRect(), effect->boundingRectFor(childRect | grandChildRect)); + + CustomEffect *childEffect = new CustomEffect; + child->setGraphicsEffect(childEffect); + QCOMPARE(effect->boundingRect(), effect->boundingRectFor(childEffect->boundingRectFor(childRect | grandChildRect))); + + child->setGraphicsEffect(0); + QCOMPARE(effect->boundingRect(), effect->boundingRectFor(childRect | grandChildRect)); } void tst_QGraphicsEffect::draw() -- cgit v0.12 From a4920cd2c10d4fb0420b629d8b40c8d368b791ca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B8rn=20Erik=20Nilsen?= Date: Fri, 17 Sep 2010 11:33:53 +0200 Subject: Update Symbian def files. Build error reported by CI gate, commit: 9601abf3b03cfef589c092182bec3672fab6cde0 Reviewed-by: jbarron --- src/s60installs/eabi/QtGuiu.def | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/s60installs/eabi/QtGuiu.def b/src/s60installs/eabi/QtGuiu.def index 6696beb..47e893b 100644 --- a/src/s60installs/eabi/QtGuiu.def +++ b/src/s60installs/eabi/QtGuiu.def @@ -9389,7 +9389,7 @@ EXPORTS _ZNK20QGraphicsItemPrivate19genericMapFromSceneERK7QPointFPK7QWidget @ 9388 NONAME _ZNK20QGraphicsItemPrivate19maybeExtraItemCacheEv @ 9389 NONAME _ZNK20QGraphicsItemPrivate20discardUpdateRequestEbbbb @ 9390 NONAME ABSENT - _ZNK20QGraphicsItemPrivate21effectiveBoundingRectEv @ 9391 NONAME + _ZNK20QGraphicsItemPrivate21effectiveBoundingRectEv @ 9391 NONAME ABSENT _ZNK20QGraphicsItemPrivate22inputMethodQueryHelperEN2Qt16InputMethodQueryE @ 9392 NONAME _ZNK20QGraphicsItemPrivate24combineTransformToParentEP10QTransformPKS0_ @ 9393 NONAME _ZNK20QGraphicsItemPrivate26combineTransformFromParentEP10QTransformPKS0_ @ 9394 NONAME @@ -12092,6 +12092,6 @@ EXPORTS _ZN11QFontEngine16lastRightBearingERK12QGlyphLayoutb @ 12091 NONAME _ZN18QTapAndHoldGesture10setTimeoutEi @ 12092 NONAME _ZN18QTapAndHoldGesture7timeoutEv @ 12093 NONAME - _ZN20QGraphicsItemPrivate26childrenBoundingRectHelperEP10QTransformP6QRectFb @ 12094 NONAME + _ZN20QGraphicsItemPrivate26childrenBoundingRectHelperEP10QTransformP6QRectFb @ 12094 NONAME ABSENT _ZN20QGraphicsItemPrivate14children_clearEP24QDeclarativeListPropertyI15QGraphicsObjectE @ 12095 NONAME -- cgit v0.12 From 0f6dbb14ede58ebe86c1042dab5a0f086635770f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Samuel=20R=C3=B8dal?= Date: Fri, 17 Sep 2010 12:19:01 +0200 Subject: Added autotest for QPixmap::size() with null pixmaps. For change 82575a9f6123eed3e858 which fixed a behavioural regression. Reviewed-by: Olivier Goffart --- tests/auto/qpixmap/tst_qpixmap.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/tests/auto/qpixmap/tst_qpixmap.cpp b/tests/auto/qpixmap/tst_qpixmap.cpp index 7e0f466..8005ec5 100644 --- a/tests/auto/qpixmap/tst_qpixmap.cpp +++ b/tests/auto/qpixmap/tst_qpixmap.cpp @@ -742,6 +742,11 @@ void tst_QPixmap::testMetrics() QCOMPARE(bitmap.width(), 100); QCOMPARE(bitmap.height(), 100); QCOMPARE(bitmap.depth(), 1); + + QPixmap null; + + QCOMPARE(null.size().width(), null.width()); + QCOMPARE(null.size().height(), null.height()); } void tst_QPixmap::createMaskFromColor() -- cgit v0.12 From fa373ee165b32b712690656a5f69f862292a2c1e Mon Sep 17 00:00:00 2001 From: Anders Bakken Date: Fri, 17 Sep 2010 15:56:34 +0000 Subject: Export qt_directfb_.* functions in plugin as well These functions can be a big help in debugging rendering errors in an application and can even be handy to use for real functionality. While it requires the app to explicitly link to the plugin (when compiling with -plugin-gfx-directfb this is still much better than not exporting them). Since this was the only use-case for QT_DIRECTFB_PLUGIN it's probably better to take that define out. Merge-request: 2470 Reviewed-by: Donald Carr --- src/plugins/gfxdrivers/directfb/directfb.pro | 2 +- src/plugins/gfxdrivers/directfb/qdirectfbpixmap.cpp | 2 -- src/plugins/gfxdrivers/directfb/qdirectfbscreen.cpp | 2 -- 3 files changed, 1 insertion(+), 5 deletions(-) diff --git a/src/plugins/gfxdrivers/directfb/directfb.pro b/src/plugins/gfxdrivers/directfb/directfb.pro index 0706f01..d397050 100644 --- a/src/plugins/gfxdrivers/directfb/directfb.pro +++ b/src/plugins/gfxdrivers/directfb/directfb.pro @@ -11,5 +11,5 @@ SOURCES += qdirectfbscreenplugin.cpp QMAKE_CXXFLAGS += $$QT_CFLAGS_DIRECTFB LIBS += $$QT_LIBS_DIRECTFB -DEFINES += $$QT_DEFINES_DIRECTFB QT_DIRECTFB_PLUGIN +DEFINES += $$QT_DEFINES_DIRECTFB contains(gfx-plugins, directfb):DEFINES += QT_QWS_DIRECTFB diff --git a/src/plugins/gfxdrivers/directfb/qdirectfbpixmap.cpp b/src/plugins/gfxdrivers/directfb/qdirectfbpixmap.cpp index f704432..c0d96d7 100644 --- a/src/plugins/gfxdrivers/directfb/qdirectfbpixmap.cpp +++ b/src/plugins/gfxdrivers/directfb/qdirectfbpixmap.cpp @@ -585,7 +585,6 @@ void QDirectFBPixmapData::invalidate() imageFormat = QImage::Format_Invalid; } -#ifndef QT_DIRECTFB_PLUGIN Q_GUI_EXPORT IDirectFBSurface *qt_directfb_surface_for_pixmap(const QPixmap &pixmap) { const QPixmapData *data = pixmap.pixmapData(); @@ -594,7 +593,6 @@ Q_GUI_EXPORT IDirectFBSurface *qt_directfb_surface_for_pixmap(const QPixmap &pix const QDirectFBPixmapData *dfbData = static_cast(data); return dfbData->directFBSurface(); } -#endif QT_END_NAMESPACE diff --git a/src/plugins/gfxdrivers/directfb/qdirectfbscreen.cpp b/src/plugins/gfxdrivers/directfb/qdirectfbscreen.cpp index cffd4e3..bf6164d 100644 --- a/src/plugins/gfxdrivers/directfb/qdirectfbscreen.cpp +++ b/src/plugins/gfxdrivers/directfb/qdirectfbscreen.cpp @@ -1790,7 +1790,6 @@ IDirectFBSurface *QDirectFBScreen::subSurfaceForWidget(const QWidget *widget, co } #endif -#ifndef QT_DIRECTFB_PLUGIN Q_GUI_EXPORT IDirectFBSurface *qt_directfb_surface_for_widget(const QWidget *widget, QRect *rect) { return QDirectFBScreen::instance() ? QDirectFBScreen::instance()->surfaceForWidget(widget, rect) : 0; @@ -1808,7 +1807,6 @@ Q_GUI_EXPORT IDirectFBWindow *qt_directfb_window_for_widget(const QWidget *widge } #endif -#endif QT_END_NAMESPACE -- cgit v0.12