diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2016-06-17 15:48:13 -0400 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2016-09-27 14:59:29 -0500 |
commit | 4847544144c00a68ed836c3964a37af5bba8d9e2 (patch) | |
tree | c9aeb7ca57c0b78ef2e6a514a3fa01a30364fb71 /libs/ardour/ardour/presentation_info.h | |
parent | d7a16786fc2bfa79d33dac676013fb34132d6fba (diff) |
fix PresentationInfo::flag_match() to match type bits
Diffstat (limited to 'libs/ardour/ardour/presentation_info.h')
-rw-r--r-- | libs/ardour/ardour/presentation_info.h | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/libs/ardour/ardour/presentation_info.h b/libs/ardour/ardour/presentation_info.h index 6ef0fae7bb..612187e376 100644 --- a/libs/ardour/ardour/presentation_info.h +++ b/libs/ardour/ardour/presentation_info.h @@ -125,7 +125,9 @@ class LIBARDOUR_API PresentationInfo : public PBD::Stateful OrderSet = 0x400, /* special mask to delect out "state" bits */ - StatusMask = (Selected|Hidden) + StatusMask = (Selected|Hidden), + /* special mask to delect select type bits */ + TypeMask = (AudioBus|AudioTrack|MidiTrack|MidiBus|VCA|MasterOut|MonitorOut|Auditioner) }; static const Flag AllStripables; /* mask to use for any route or VCA (but not auditioner) */ @@ -205,10 +207,13 @@ class LIBARDOUR_API PresentationInfo : public PBD::Stateful return true; } - /* compare without status mask - we already checked that above + /* check for any matching type bits. + * + * Do comparisoon without status mask or order set bits - we + * already checked that above. */ - return (_flags & (f &~ (StatusMask|OrderSet))) != 0; /* some flag matches */ + return ((f & TypeMask) & _flags); } int set_state (XMLNode const&, int); |