[ekiga] Services: Added a way to remove services from the ServiceCore.
- From: Damien Sandras <dsandras src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [ekiga] Services: Added a way to remove services from the ServiceCore.
- Date: Sat, 24 Jan 2015 13:04:32 +0000 (UTC)
commit ae6f728da9fed31c0cb8dcef9ffd3ac3cb739524
Author: Damien Sandras <dsandras seconix com>
Date: Sat Jan 24 14:04:02 2015 +0100
Services: Added a way to remove services from the ServiceCore.
lib/engine/framework/services.cpp | 7 +++++++
lib/engine/framework/services.h | 3 +++
2 files changed, 10 insertions(+), 0 deletions(-)
---
diff --git a/lib/engine/framework/services.cpp b/lib/engine/framework/services.cpp
index 426fbfd..3be429f 100644
--- a/lib/engine/framework/services.cpp
+++ b/lib/engine/framework/services.cpp
@@ -136,6 +136,13 @@ Ekiga::ServiceCore::add (ServicePtr service)
}
void
+Ekiga::ServiceCore::remove (ServicePtr service)
+{
+ service_removed (service);
+ services.remove (service);
+}
+
+void
Ekiga::ServiceCore::close ()
{
closed = true;
diff --git a/lib/engine/framework/services.h b/lib/engine/framework/services.h
index 72399cb..6b2f648 100644
--- a/lib/engine/framework/services.h
+++ b/lib/engine/framework/services.h
@@ -95,6 +95,8 @@ namespace Ekiga
bool add (ServicePtr service);
+ bool remove (ServicePtr service);
+
ServicePtr get (const std::string name) const;
template<typename T>
@@ -106,6 +108,7 @@ namespace Ekiga
void dump (std::ostream &stream) const;
boost::signals2::signal<void(ServicePtr)> service_added;
+ boost::signals2::signal<void(ServicePtr)> service_removed;
private:
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]