summaryrefslogtreecommitdiffstats
path: root/src/corelib/kernel/qobject.h
diff options
context:
space:
mode:
authorGunnar Sletta <gunnar.sletta@nokia.com>2010-09-27 11:41:38 +0200
committerGunnar Sletta <gunnar.sletta@nokia.com>2010-09-27 11:41:38 +0200
commit2271315eb46665b0a9e61ff0525340713163c1b6 (patch)
treed0068e34924eca85eb6af4089b3f443a89c929f6 /src/corelib/kernel/qobject.h
parent33e7ee9d1866f12a9b92fe4b5549c31e30974d8e (diff)
parent53d010a989aed878c21522cbaf0d75c7cf821b42 (diff)
Merge branch 'master' of scm.dev.nokia.troll.no:qt/qt
Conflicts: configure src/corelib/global/qglobal.h
Diffstat (limited to 'src/corelib/kernel/qobject.h')
-rw-r--r--src/corelib/kernel/qobject.h8
1 files changed, 2 insertions, 6 deletions
diff --git a/src/corelib/kernel/qobject.h b/src/corelib/kernel/qobject.h
index b5db936c2b..63fdf76801 100644
--- a/src/corelib/kernel/qobject.h
+++ b/src/corelib/kernel/qobject.h
@@ -351,7 +351,7 @@ inline QT_DEPRECATED T qFindChild(const QObject *o, const QString &name = QStrin
{ return o->findChild<T>(name); }
template<typename T>
-inline QList<T> qFindChildren(const QObject *o, const QString &name = QString())
+inline QT_DEPRECATED QList<T> qFindChildren(const QObject *o, const QString &name = QString())
{
return o->findChildren<T>(name);
}
@@ -378,14 +378,10 @@ inline T qobject_cast(QObject *object)
template <class T>
inline T qobject_cast(const QObject *object)
{
- // this will cause a compilation error if T is not const
- register T ptr = static_cast<T>(object);
- Q_UNUSED(ptr);
-
#if !defined(QT_NO_QOBJECT_CHECK)
reinterpret_cast<T>(0)->qt_check_for_QOBJECT_macro(*reinterpret_cast<T>(const_cast<QObject *>(object)));
#endif
- return static_cast<T>(const_cast<QObject *>(reinterpret_cast<T>(0)->staticMetaObject.cast(const_cast<QObject *>(object))));
+ return static_cast<T>(reinterpret_cast<T>(0)->staticMetaObject.cast(object));
}