Add convenience ControlFlags operators
Explicit functions for operator&=~ and operator|=
This commit is contained in:
parent
45f5513b66
commit
2b17ded785
@ -100,6 +100,18 @@ Controllable::set_flags (Flag f)
|
||||
_flags = f;
|
||||
}
|
||||
|
||||
void
|
||||
Controllable::set_flag (Flag f)
|
||||
{
|
||||
_flags = Flag ((int)_flags | f);
|
||||
}
|
||||
|
||||
void
|
||||
Controllable::clear_flag (Flag f)
|
||||
{
|
||||
_flags = Flag ((int)_flags & ~f);
|
||||
}
|
||||
|
||||
void
|
||||
Controllable::add (Controllable& ctl)
|
||||
{
|
||||
|
@ -163,6 +163,9 @@ public:
|
||||
Flag flags() const { return _flags; }
|
||||
void set_flags (Flag f);
|
||||
|
||||
void set_flag (Flag f); ///< _flags |= f;
|
||||
void clear_flag (Flag f); ///< _flags &= ~f;
|
||||
|
||||
static boost::shared_ptr<Controllable> by_id (const PBD::ID&);
|
||||
static void dump_registry ();
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user