QPropertyBinding: compare QMetaType directly

Change-Id: I36fbc8ebed096aa6f7be48456005395b65229359
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
This commit is contained in:
Fabian Kosmale 2020-10-11 13:58:53 +02:00
parent ed460ba7e2
commit 75b8c4d75e

View File

@ -422,7 +422,7 @@ public:
bool setBinding(const QUntypedPropertyBinding &newBinding)
{
if (!newBinding.isNull() && newBinding.valueMetaType().id() != qMetaTypeId<T>())
if (!newBinding.isNull() && newBinding.valueMetaType() != QMetaType::fromType<T>())
return false;
setBinding(static_cast<const QPropertyBinding<T> &>(newBinding));
return true;