From 8524e6261175549575d3bf82bcce31cb615a5717 Mon Sep 17 00:00:00 2001 From: Laurent Pinchart Date: Mon, 28 Oct 2019 05:16:31 +0200 Subject: libcamera: signal: Specify connection type for signals MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Add a connection type parameter to the Signal::connect() method to control signal delivery. Signed-off-by: Laurent Pinchart Reviewed-by: Niklas Söderlund --- include/libcamera/signal.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'include/libcamera/signal.h') diff --git a/include/libcamera/signal.h b/include/libcamera/signal.h index b8a60281..57598335 100644 --- a/include/libcamera/signal.h +++ b/include/libcamera/signal.h @@ -55,11 +55,12 @@ public: #ifndef __DOXYGEN__ template::value>::type * = nullptr> - void connect(T *obj, void (T::*func)(Args...)) + void connect(T *obj, void (T::*func)(Args...), + ConnectionType type = ConnectionTypeAuto) { Object *object = static_cast(obj); object->connect(this); - slots_.push_back(new BoundMemberMethod(obj, object, func)); + slots_.push_back(new BoundMemberMethod(obj, object, func, type)); } template::value>::type * = nullptr> -- cgit v1.2.1