summaryrefslogtreecommitdiffstats
path: root/src/corelib/kernel/qpropertyprivate.h
diff options
context:
space:
mode:
authorFabian Kosmale <fabian.kosmale@qt.io>2020-06-18 16:55:48 +0200
committerFabian Kosmale <fabian.kosmale@qt.io>2020-06-25 14:11:56 +0200
commit6a24ac7c4e0a7737b0cd0738c4e6fe8b9ac589ca (patch)
tree52e1f7b48a57da297d5eef19396b5c30408a1062 /src/corelib/kernel/qpropertyprivate.h
parentc2fb27f054b228311fdba71f2a49cb09ae2a8fc8 (diff)
QNotifiedProperty: pass old value to callback if requested
Check at compile time whether the static callback takes an argument (which has to be of the same time as the type of the property). If so, retrieve the old value and pass it to the callback. Change-Id: Ib1c4c9e05b826b6be492b03f66fa72ad015963ee Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Diffstat (limited to 'src/corelib/kernel/qpropertyprivate.h')
-rw-r--r--src/corelib/kernel/qpropertyprivate.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/corelib/kernel/qpropertyprivate.h b/src/corelib/kernel/qpropertyprivate.h
index 7a2c6a5b77..43318f25c0 100644
--- a/src/corelib/kernel/qpropertyprivate.h
+++ b/src/corelib/kernel/qpropertyprivate.h
@@ -84,7 +84,7 @@ public:
QUntypedPropertyBinding setBinding(const QUntypedPropertyBinding &newBinding,
void *propertyDataPtr, void *staticObserver = nullptr,
- void (*staticObserverCallback)(void*) = nullptr);
+ void (*staticObserverCallback)(void *, void *) = nullptr);
QPropertyBindingPrivate *binding();
void evaluateIfDirty();