summaryrefslogtreecommitdiffstats
path: root/src/declarative
diff options
context:
space:
mode:
authorAaron Kennedy <aaron.kennedy@nokia.com>2010-03-18 04:02:59 (GMT)
committerAaron Kennedy <aaron.kennedy@nokia.com>2010-03-18 04:03:24 (GMT)
commit67fedb14501b47fec6892cf6b88739fba985b366 (patch)
tree2e2259aeb54d0e0d74cd801199521ecdd2e233d5 /src/declarative
parenta096555227b39c3107ab5eea497176746083cd4b (diff)
downloadQt-67fedb14501b47fec6892cf6b88739fba985b366.zip
Qt-67fedb14501b47fec6892cf6b88739fba985b366.tar.gz
Qt-67fedb14501b47fec6892cf6b88739fba985b366.tar.bz2
Make it harder to accidentally delete a binding
Diffstat (limited to 'src/declarative')
-rw-r--r--src/declarative/qml/qdeclarativebinding_p.h12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/declarative/qml/qdeclarativebinding_p.h b/src/declarative/qml/qdeclarativebinding_p.h
index 533b6d4..56f1715 100644
--- a/src/declarative/qml/qdeclarativebinding_p.h
+++ b/src/declarative/qml/qdeclarativebinding_p.h
@@ -68,7 +68,6 @@ class Q_DECLARATIVE_EXPORT QDeclarativeAbstractBinding
{
public:
QDeclarativeAbstractBinding();
- virtual ~QDeclarativeAbstractBinding();
virtual void destroy();
@@ -88,14 +87,15 @@ public:
void removeFromObject();
protected:
+ virtual ~QDeclarativeAbstractBinding();
void clear();
private:
+
friend class QDeclarativeDeclarativeData;
- friend class QDeclarativeProperty;
+ friend class QDeclarativeValueTypeProxyBinding;
friend class QDeclarativePropertyPrivate;
friend class QDeclarativeVME;
- friend class QDeclarativeValueTypeProxyBinding;
QObject *m_object;
QDeclarativeAbstractBinding **m_mePtr;
@@ -107,7 +107,6 @@ class QDeclarativeValueTypeProxyBinding : public QDeclarativeAbstractBinding
{
public:
QDeclarativeValueTypeProxyBinding(QObject *o, int coreIndex);
- virtual ~QDeclarativeValueTypeProxyBinding();
virtual Type bindingType() const { return ValueTypeProxy; }
@@ -117,6 +116,9 @@ public:
QDeclarativeAbstractBinding *binding(int propertyIndex);
+protected:
+ ~QDeclarativeValueTypeProxyBinding();
+
private:
void recursiveEnable(QDeclarativeAbstractBinding *, QDeclarativePropertyPrivate::WriteFlags);
void recursiveDisable(QDeclarativeAbstractBinding *);
@@ -137,7 +139,6 @@ public:
QDeclarativeBinding(const QString &, QObject *, QDeclarativeContextData *, QObject *parent=0);
QDeclarativeBinding(void *, QDeclarativeRefCount *, QObject *, QDeclarativeContextData *,
const QString &, int, QObject *parent);
- ~QDeclarativeBinding();
void setTarget(const QDeclarativeProperty &);
QDeclarativeProperty property() const;
@@ -154,6 +155,7 @@ public Q_SLOTS:
void update() { update(QDeclarativePropertyPrivate::DontRemoveBinding); }
protected:
+ ~QDeclarativeBinding();
void emitValueChanged();
private: