summaryrefslogtreecommitdiffstats
path: root/src/gui/graphicsview
diff options
context:
space:
mode:
authorJohn Tapsell <john.tapsell.ext@basyskom.de>2011-09-16 13:41:41 (GMT)
committerSamuel Rødal <samuel.rodal@nokia.com>2011-09-16 13:41:48 (GMT)
commit6f64c1087245c0ae034bcd09ca7549a33df5a6c7 (patch)
tree3ab23d121fefcab0949711743a74816775c2b38d /src/gui/graphicsview
parent489661d3e69edf0c3011dcd5dd3ae800c9616617 (diff)
downloadQt-6f64c1087245c0ae034bcd09ca7549a33df5a6c7.zip
Qt-6f64c1087245c0ae034bcd09ca7549a33df5a6c7.tar.gz
Qt-6f64c1087245c0ae034bcd09ca7549a33df5a6c7.tar.bz2
QGraphicsWidget::setLayoutDirection doesn't propagate to new children
Merge-request: 1360 Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
Diffstat (limited to 'src/gui/graphicsview')
-rw-r--r--src/gui/graphicsview/qgraphicswidget.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/gui/graphicsview/qgraphicswidget.cpp b/src/gui/graphicsview/qgraphicswidget.cpp
index 965b1b34..d3562fc 100644
--- a/src/gui/graphicsview/qgraphicswidget.cpp
+++ b/src/gui/graphicsview/qgraphicswidget.cpp
@@ -1173,6 +1173,12 @@ QVariant QGraphicsWidget::itemChange(GraphicsItemChange change, const QVariant &
QApplication::sendEvent(this, &event);
break;
}
+ case ItemChildAddedChange: {
+ QGraphicsItem *child = qVariantValue<QGraphicsItem *>(value);
+ if (child->isWidget())
+ static_cast<QGraphicsWidget *>(child)->d_func()->resolveLayoutDirection();
+ break;
+ }
default:
break;
}