Replace PBD::Signals (1/2)

This commit is contained in:
Robin Gareus 2024-10-18 18:01:28 +02:00
parent 5808ab5608
commit 2d7cce44f1
No known key found for this signature in database
GPG key ID: A090BCE02CF57F04
163 changed files with 519 additions and 519 deletions

View file

@ -32,10 +32,10 @@
using namespace PBD;
using namespace std;
PBD::Signal1<bool, std::weak_ptr<PBD::Controllable> > Controllable::StartLearning;
PBD::Signal1<void, std::weak_ptr<PBD::Controllable> > Controllable::StopLearning;
PBD::Signal1<void, std::weak_ptr<PBD::Controllable> > Controllable::GUIFocusChanged;
PBD::Signal1<void, std::weak_ptr<PBD::Controllable> > Controllable::ControlTouched;
PBD::Signal<bool(std::weak_ptr<PBD::Controllable> )> Controllable::StartLearning;
PBD::Signal<void(std::weak_ptr<PBD::Controllable> )> Controllable::StopLearning;
PBD::Signal<void(std::weak_ptr<PBD::Controllable> )> Controllable::GUIFocusChanged;
PBD::Signal<void(std::weak_ptr<PBD::Controllable> )> Controllable::ControlTouched;
Glib::Threads::RWLock Controllable::registry_lock;
Controllable::Controllables Controllable::registry;

View file

@ -44,7 +44,7 @@ class LIBPBD_API Configuration : public PBD::Stateful
virtual XMLNode & get_variables (std::string const & nodename) const = 0;
virtual void set_variables (XMLNode const &) = 0;
PBD::Signal1<void,std::string> ParameterChanged;
PBD::Signal<void(std::string)> ParameterChanged;
typedef std::vector<std::string> Metadata;

View file

@ -138,15 +138,15 @@ public:
virtual std::string get_user_string() const { return std::string(); }
PBD::Signal0<void> LearningFinished;
PBD::Signal<void()> LearningFinished;
static PBD::Signal1<bool, std::weak_ptr<PBD::Controllable> > StartLearning;
static PBD::Signal1<void, std::weak_ptr<PBD::Controllable> > StopLearning;
static PBD::Signal<bool(std::weak_ptr<PBD::Controllable> )> StartLearning;
static PBD::Signal<void(std::weak_ptr<PBD::Controllable> )> StopLearning;
static PBD::Signal1<void, std::weak_ptr<PBD::Controllable> > GUIFocusChanged;
static PBD::Signal1<void, std::weak_ptr<PBD::Controllable> > ControlTouched;
static PBD::Signal<void(std::weak_ptr<PBD::Controllable> )> GUIFocusChanged;
static PBD::Signal<void(std::weak_ptr<PBD::Controllable> )> ControlTouched;
PBD::Signal2<void,bool,PBD::Controllable::GroupControlDisposition> Changed;
PBD::Signal<void(bool,PBD::Controllable::GroupControlDisposition)> Changed;
int set_state (const XMLNode&, int version);
virtual XMLNode& get_state () const;
@ -154,7 +154,7 @@ public:
std::string name() const { return _name; }
bool touching () const { return _touching; }
PBD::Signal0<void> TouchChanged;
PBD::Signal<void()> TouchChanged;
bool is_toggle() const { return _flags & Toggle; }
bool is_gain_like() const { return _flags & GainLike; }

View file

@ -27,8 +27,8 @@ class LIBPBD_API Destructible {
public:
virtual ~Destructible () { Destroyed(); }
PBD::Signal0<void> Destroyed;
PBD::Signal0<void> DropReferences;
PBD::Signal<void()> Destroyed;
PBD::Signal<void()> DropReferences;
virtual void drop_references () { DropReferences(); }
};

View file

@ -40,7 +40,7 @@ class LIBPBD_API Inflater : public PBD::FileArchive , public PBD::Progress
bool running() const { return thread != 0; }
int status() const { return _status; }
PBD::Signal1<void, float> Progress;
PBD::Signal<void(float)> Progress;
private:
PBD::Thread* thread;

View file

@ -99,7 +99,7 @@ LIBPBD_API bool pbd_mach_set_realtime_policy (pthread_t thread_id, double period
namespace PBD {
LIBPBD_API extern void notify_event_loops_about_thread_creation (pthread_t, const std::string&, int requests = 256);
LIBPBD_API extern PBD::Signal3<void,pthread_t,std::string,uint32_t> ThreadCreatedWithRequestSize;
LIBPBD_API extern PBD::Signal<void(pthread_t,std::string,uint32_t)> ThreadCreatedWithRequestSize;
class LIBPBD_API Thread {
public:

View file

@ -96,7 +96,7 @@ class LIBPBD_API Stateful {
virtual PropertyList* property_factory (const XMLNode&) const;
/* How stateful's notify of changes to their properties */
PBD::Signal1<void,const PropertyChange&> PropertyChanged;
PBD::Signal<void(const PropertyChange&)> PropertyChanged;
static int current_state_version;
static int loading_state_version;

View file

@ -202,14 +202,14 @@ class LIBPBD_API SystemExec
#ifdef NOPBD /* outside ardour */
sigc::signal<void, std::string,size_t> ReadStdout;
#else
PBD::Signal2<void, std::string,size_t> ReadStdout;
PBD::Signal<void(std::string,size_t)> ReadStdout;
#endif
/** The Terminated signal is emitted when application terminates. */
#ifdef NOPBD /* outside ardour */
sigc::signal<void> Terminated;
#else
PBD::Signal0<void> Terminated;
PBD::Signal<void()> Terminated;
#endif
/** interposer to emit signal for writes to STDOUT/ERR.

View file

@ -40,7 +40,7 @@ class LIBPBD_API Transmitter : public std::stringstream
Transmitter (Channel);
PBD::Signal2<void,Channel, const char *> &sender() {
PBD::Signal<void(Channel, const char *)> &sender() {
return *send;
}
@ -52,13 +52,13 @@ class LIBPBD_API Transmitter : public std::stringstream
private:
Channel channel;
PBD::Signal2<void, Channel, const char *> *send;
PBD::Signal<void(Channel, const char *)> *send;
PBD::Signal2<void, Channel, const char *> debug;
PBD::Signal2<void, Channel, const char *> info;
PBD::Signal2<void, Channel, const char *> warning;
PBD::Signal2<void, Channel, const char *> error;
PBD::Signal2<void, Channel, const char *> fatal;
PBD::Signal<void(Channel, const char *)> debug;
PBD::Signal<void(Channel, const char *)> info;
PBD::Signal<void(Channel, const char *)> warning;
PBD::Signal<void(Channel, const char *)> error;
PBD::Signal<void(Channel, const char *)> fatal;
};
/* for EGCS 2.91.66, if this function is not compiled within the same

View file

@ -130,9 +130,9 @@ public:
void set_depth (uint32_t);
PBD::Signal0<void> Changed;
PBD::Signal0<void> BeginUndoRedo;
PBD::Signal0<void> EndUndoRedo;
PBD::Signal<void()> Changed;
PBD::Signal<void()> BeginUndoRedo;
PBD::Signal<void()> EndUndoRedo;
private:
bool _clearing;

View file

@ -106,7 +106,7 @@ set_win_set_realtime_policy (pthread_t thread, int priority)
namespace PBD
{
PBD::Signal3<void, pthread_t, std::string, uint32_t> ThreadCreatedWithRequestSize;
PBD::Signal<void(pthread_t, std::string, uint32_t)> ThreadCreatedWithRequestSize;
}
using namespace PBD;

View file

@ -21,7 +21,7 @@ public:
Fred ();
}
PBD::Signal0<void> Fred;
PBD::Signal<void()> Fred;
};
static int N = 0;