diff options
author | Hennadii Stepanov <32963518+hebasto@users.noreply.github.com> | 2022-04-16 19:18:54 +0200 |
---|---|---|
committer | Hennadii Stepanov <32963518+hebasto@users.noreply.github.com> | 2022-04-16 19:18:54 +0200 |
commit | 6958a26aa136e0976870237ccc6ea015d113f7ac (patch) | |
tree | 73f86e6ed0ea24b4f26679e16c069cccce9e733a /src/qt/guiutil.h | |
parent | 249984f4f93fe6fae81391f474e4d64ad9df3d6d (diff) |
Revert "qt: Add ObjectInvoke template function"
This reverts commit 5659e73493fcdfb5d0cb9d686c24c4fbe1c217ed.
Diffstat (limited to 'src/qt/guiutil.h')
-rw-r--r-- | src/qt/guiutil.h | 12 |
1 files changed, 0 insertions, 12 deletions
diff --git a/src/qt/guiutil.h b/src/qt/guiutil.h index 76e5207d81..e38ac6026a 100644 --- a/src/qt/guiutil.h +++ b/src/qt/guiutil.h @@ -361,18 +361,6 @@ namespace GUIUtil #endif } - /** - * Queue a function to run in an object's event loop. This can be - * replaced by a call to the QMetaObject::invokeMethod functor overload after Qt 5.10, but - * for now use a QObject::connect for compatibility with older Qt versions, based on - * https://stackoverflow.com/questions/21646467/how-to-execute-a-functor-or-a-lambda-in-a-given-thread-in-qt-gcd-style - */ - template <typename Fn> - void ObjectInvoke(QObject* object, Fn&& function, Qt::ConnectionType connection = Qt::QueuedConnection) - { - QObject source; - QObject::connect(&source, &QObject::destroyed, object, std::forward<Fn>(function), connection); - } /** * Replaces a plain text link with an HTML tagged one. |