diff options
author | J-P Nurmi <j-p.nurmi@nokia.com> | 2012-07-05 11:54:39 +0200 |
---|---|---|
committer | Gabriel de Dietrich <gabriel.dietrich-de@nokia.com> | 2012-07-05 14:23:10 +0200 |
commit | 8bc01ccf20b094880592b6c0e969afad74cc93ad (patch) | |
tree | 6d345b0213597161d1241ec06a4d303bd554bb38 | |
parent | a12ac2d82202caced9aad0d999f2056b2d925ac6 (diff) | |
download | qtquickcontrols-8bc01ccf20b094880592b6c0e969afad74cc93ad.tar.gz |
StyleItem: update when enabled/disabled
Change-Id: I45a2c4833d289748548100b6c543019c0c5d2e6b
Reviewed-by: Gabriel de Dietrich <gabriel.dietrich-de@nokia.com>
-rw-r--r-- | examples/Gallery.qml | 3 | ||||
-rw-r--r-- | src/qstyleitem.cpp | 1 |
2 files changed, 4 insertions, 0 deletions
diff --git a/examples/Gallery.qml b/examples/Gallery.qml index 230e9d85..1f282387 100644 --- a/examples/Gallery.qml +++ b/examples/Gallery.qml @@ -374,6 +374,7 @@ Rectangle { Tab { id:mytab title: "Itemviews" + enabled: enabledCheck.checked ModelView { anchors.fill: parent anchors.margins: 6 @@ -381,6 +382,7 @@ Rectangle { } Tab { title: "Range" + enabled: enabledCheck.checked Row { anchors.fill: parent anchors.margins:16 @@ -461,6 +463,7 @@ Rectangle { } Tab { title: "Sidebar" + enabled: enabledCheck.checked Panel { anchors.fill:parent diff --git a/src/qstyleitem.cpp b/src/qstyleitem.cpp index 2e022b9b..f9344cb9 100644 --- a/src/qstyleitem.cpp +++ b/src/qstyleitem.cpp @@ -90,6 +90,7 @@ QStyleItem::QStyleItem(QQuickPaintedItem *parent) setSmooth(false); //setCacheMode(QGraphicsItem::DeviceCoordinateCache); + connect(this, SIGNAL(enabledChanged()), this, SLOT(updateItem())); connect(this, SIGNAL(infoChanged()), this, SLOT(updateItem())); connect(this, SIGNAL(onChanged()), this, SLOT(updateItem())); connect(this, SIGNAL(selectedChanged()), this, SLOT(updateItem())); |