PPI: Implement Connector and Event un-registration
[senf.git] / senf / PPI / Events.cc
index 7aa0298..f74a329 100644 (file)
@@ -28,6 +28,7 @@
 
 // Custom includes
 #include "Route.hh"
+#include "EventManager.hh"
 
 //#include "Events.mpp"
 #define prefix_
 ///////////////////////////////////////////////////////////////////////////
 // senf::ppi::EventDescriptor
 
+prefix_ senf::ppi::EventDescriptor::~EventDescriptor()
+{
+    if (binding_)
+        binding_->manager().destroyEvent(*this);
+}
+
 prefix_ void senf::ppi::EventDescriptor::notifyUnthrottle()
 {
     Routes::const_iterator i (routes_.begin());