summaryrefslogtreecommitdiffstats
path: root/api/logic/QObjectPtr.h
diff options
context:
space:
mode:
Diffstat (limited to 'api/logic/QObjectPtr.h')
-rw-r--r--api/logic/QObjectPtr.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/api/logic/QObjectPtr.h b/api/logic/QObjectPtr.h
index b81b3234..000d228d 100644
--- a/api/logic/QObjectPtr.h
+++ b/api/logic/QObjectPtr.h
@@ -48,6 +48,10 @@ public:
using namespace std::placeholders;
m_ptr.reset(wrap, std::bind(&QObject::deleteLater, _1));
}
+ void reset(const shared_qobject_ptr<T> &other)
+ {
+ m_ptr = other.m_ptr;
+ }
void reset()
{
m_ptr.reset();