summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorAaron Kennedy <aaron.kennedy@nokia.com>2010-03-24 07:47:17 (GMT)
committerAaron Kennedy <aaron.kennedy@nokia.com>2010-03-24 07:47:17 (GMT)
commit5ddcc726a623fea3534f76c07b6c1d2835a0e2d6 (patch)
tree617d5a956af0d2f5ca2cda8b45f755c030d43a82 /src
parent63d2d82031c69c35ea2bd6bf48e357b6297f67df (diff)
downloadQt-5ddcc726a623fea3534f76c07b6c1d2835a0e2d6.zip
Qt-5ddcc726a623fea3534f76c07b6c1d2835a0e2d6.tar.gz
Qt-5ddcc726a623fea3534f76c07b6c1d2835a0e2d6.tar.bz2
Disallow the implicit QDeclarativeGuardedContextData copy constructor
Task-number: QTBUG-9312
Diffstat (limited to 'src')
-rw-r--r--src/declarative/qml/qdeclarativecontext_p.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/declarative/qml/qdeclarativecontext_p.h b/src/declarative/qml/qdeclarativecontext_p.h
index e5f18b3..397f37a 100644
--- a/src/declarative/qml/qdeclarativecontext_p.h
+++ b/src/declarative/qml/qdeclarativecontext_p.h
@@ -213,8 +213,11 @@ public:
inline operator QDeclarativeContextData*() const { return m_contextData; }
inline QDeclarativeContextData* operator->() const { return m_contextData; }
+ inline QDeclarativeGuardedContextData &operator=(QDeclarativeContextData *d);
private:
+ QDeclarativeGuardedContextData &operator=(const QDeclarativeGuardedContextData &);
+ QDeclarativeGuardedContextData(const QDeclarativeGuardedContextData &);
friend class QDeclarativeContextData;
inline void clear();
@@ -269,6 +272,13 @@ void QDeclarativeGuardedContextData::clear()
}
}
+QDeclarativeGuardedContextData &
+QDeclarativeGuardedContextData::operator=(QDeclarativeContextData *d)
+{
+ setContextData(d);
+ return *this;
+}
+
QT_END_NAMESPACE
#endif // QDECLARATIVECONTEXT_P_H