From dce6bb0e301a7985b302143ff4405b5526ab5dd6 Mon Sep 17 00:00:00 2001 From: Laurent Pinchart Date: Sat, 4 Jan 2020 06:03:47 +0200 Subject: libcamera: bound_method: Rename Bound*Method to BoundMethod* MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Most of the bound method classes are named with a BoundMethod prefix, except for BoundMemberMethod and BoundStaticMethod. Rename them to BoundMethodMember and BoundMethodStatic respectively to make the code more coherent. Signed-off-by: Laurent Pinchart Reviewed-by: Niklas Söderlund --- include/libcamera/signal.h | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'include/libcamera/signal.h') diff --git a/include/libcamera/signal.h b/include/libcamera/signal.h index 7fbe5a2c..432d95d0 100644 --- a/include/libcamera/signal.h +++ b/include/libcamera/signal.h @@ -60,7 +60,7 @@ public: { Object *object = static_cast(obj); object->connect(this); - slots_.push_back(new BoundMemberMethod(obj, object, func, type)); + slots_.push_back(new BoundMethodMember(obj, object, func, type)); } template::value>::type * = nullptr> @@ -69,13 +69,13 @@ public: #endif void connect(T *obj, R (T::*func)(Args...)) { - slots_.push_back(new BoundMemberMethod(obj, nullptr, func)); + slots_.push_back(new BoundMethodMember(obj, nullptr, func)); } template void connect(R (*func)(Args...)) { - slots_.push_back(new BoundStaticMethod(func)); + slots_.push_back(new BoundMethodStatic(func)); } void disconnect() @@ -100,11 +100,11 @@ public: /* * If the object matches the slot, the slot is * guaranteed to be a member slot, so we can safely - * cast it to BoundMemberMethod to match + * cast it to BoundMethodMember to match * func. */ if (slot->match(obj) && - static_cast *>(slot)->match(func)) { + static_cast *>(slot)->match(func)) { iter = slots_.erase(iter); delete slot; } else { @@ -119,7 +119,7 @@ public: for (auto iter = slots_.begin(); iter != slots_.end(); ) { BoundMethodArgs *slot = *iter; if (slot->match(nullptr) && - static_cast *>(slot)->match(func)) { + static_cast *>(slot)->match(func)) { iter = slots_.erase(iter); delete slot; } else { -- cgit v1.2.1