aboutsummaryrefslogtreecommitdiffstats
path: root/src/quick/items/qquickrectangle.cpp
diff options
context:
space:
mode:
authorKent Hansen <kent.hansen@nokia.com>2012-05-30 11:33:32 +0200
committerQt by Nokia <qt-info@nokia.com>2012-06-01 09:34:50 +0200
commit6cb34bd5000b68d04b2798f6aa16134464573420 (patch)
tree9a5dc8a6a638cccf783c39ed593262c91bb2215c /src/quick/items/qquickrectangle.cpp
parent2c65dce8f68bfb03848dbd395fd1501fd7cd1510 (diff)
Avoid string-based lookup of signals
Change-Id: I5b83b5d07b6a5d2de86d0f37471cf59baa7b0e43 Reviewed-by: Michael Brasser <michael.brasser@nokia.com>
Diffstat (limited to 'src/quick/items/qquickrectangle.cpp')
-rw-r--r--src/quick/items/qquickrectangle.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/quick/items/qquickrectangle.cpp b/src/quick/items/qquickrectangle.cpp
index f4fe4714ea..b4156d9749 100644
--- a/src/quick/items/qquickrectangle.cpp
+++ b/src/quick/items/qquickrectangle.cpp
@@ -48,6 +48,7 @@
#include <QtGui/qpixmapcache.h>
#include <QtCore/qstringbuilder.h>
#include <QtCore/qmath.h>
+#include <QtCore/qmetaobject.h>
QT_BEGIN_NAMESPACE
@@ -414,7 +415,7 @@ void QQuickRectangle::setGradient(QQuickGradient *gradient)
return;
static int updatedSignalIdx = -1;
if (updatedSignalIdx < 0)
- updatedSignalIdx = QQuickGradient::staticMetaObject.indexOfSignal("updated()");
+ updatedSignalIdx = QMetaMethod::fromSignal(&QQuickGradient::updated).methodIndex();
if (d->doUpdateSlotIdx < 0)
d->doUpdateSlotIdx = QQuickRectangle::staticMetaObject.indexOfSlot("doUpdate()");
if (d->gradient)