31 #include <glibmm/threads.h>
78 NotAutomatable = 0x08,
81 MonitorControl = 0x40,
127 return (i-lower())/(upper() - lower());
131 return lower() + i*(upper() - lower());
135 virtual float get_interface(
bool rotary=
false)
const {
return (internal_to_interface(get_value(), rotary)); }
154 std::string
name()
const {
return _name; }
162 virtual double lower()
const {
return 0.0; }
163 virtual double upper()
const {
return 1.0; }
164 virtual double normal()
const {
return 0.0; }
180 if (_touching == yn) {
return; }
void set_touching(bool yn)
virtual XMLNode & get_state() const
static void dump_registry()
Controllable(const std::string &name, Flag f=Flag(0))
static PBD::Signal< void(std::weak_ptr< PBD::Controllable >)> ControlTouched
void clear_flag(Flag f)
_flags &= ~f;
virtual double interface_to_internal(double i, bool rotary=false) const
static ScopedConnectionList registry_connections
static void remove(Controllable *)
static std::shared_ptr< Controllable > by_id(const PBD::ID &)
virtual double get_save_value() const
bool is_gain_like() const
static PBD::Signal< bool(std::weak_ptr< PBD::Controllable >)> StartLearning
virtual std::string get_user_string() const
std::set< PBD::Controllable * > Controllables
static ControllableSet registered_controllables()
virtual void set_value(double value, GroupControlDisposition group_override)=0
virtual double lower() const
virtual double normal() const
virtual double get_value(void) const =0
virtual float get_interface(bool rotary=false) const
PBD::Signal< void()> TouchChanged
int set_state(const XMLNode &, int version)
virtual double internal_to_interface(double i, bool rotary=false) const
virtual void set_interface(float fraction, bool rotary=false, GroupControlDisposition gcd=NoGroup)
static const std::string xml_node_name
static PBD::Signal< void(std::weak_ptr< PBD::Controllable >)> GUIFocusChanged
static PBD::Signal< void(std::weak_ptr< PBD::Controllable >)> StopLearning
static void add(Controllable &)
static Controllables registry
static Glib::Threads::RWLock registry_lock
void set_flag(Flag f)
_flags |= f;
PBD::Signal< void(bool, PBD::Controllable::GroupControlDisposition)> Changed
virtual double upper() const
PBD::Signal< void()> LearningFinished
GtkImageIconNameData name
std::shared_ptr< PBD::Controllable > Controllable
std::set< std::shared_ptr< Controllable > > ControllableSet