X-Git-Url: https://main.carlh.net/gitweb/?a=blobdiff_plain;f=libs%2Fpbd%2Fpbd%2Fdestructible.h;h=78f6f83b7a894be476e6b21fa0c05c244a82b0c6;hb=e3329000557015ce54691235769db8821e75666b;hp=241d847aff1940c526aed4d051e914d0963f37cd;hpb=f6fdd8dcbf41f864e9f0cc32dabe81fe3533ddfe;p=ardour.git diff --git a/libs/pbd/pbd/destructible.h b/libs/pbd/pbd/destructible.h index 241d847aff..78f6f83b7a 100644 --- a/libs/pbd/pbd/destructible.h +++ b/libs/pbd/pbd/destructible.h @@ -20,20 +20,20 @@ #ifndef __pbd_destructible_h__ #define __pbd_destructible_h__ -#include +#include "pbd/signals.h" +#include "pbd/libpbd_visibility.h" namespace PBD { -class Destructible { +class LIBPBD_API Destructible { public: - Destructible() : refs_dropped (false){} - virtual ~Destructible () {} + Destructible() {} + virtual ~Destructible () { Destroyed(); } - boost::signals2::signal GoingAway; - void drop_references () { if (!refs_dropped) { GoingAway(); } refs_dropped = true; } + PBD::Signal0 Destroyed; + PBD::Signal0 DropReferences; - private: - bool refs_dropped; + void drop_references () { DropReferences(); } }; }