summaryrefslogtreecommitdiff
path: root/libs/ardour/ardour/data_type.h
diff options
context:
space:
mode:
authorJulien "_FrnchFrgg_" RIVAUD <frnchfrgg@free.fr>2017-08-23 22:44:32 +0200
committerJulien "_FrnchFrgg_" RIVAUD <frnchfrgg@free.fr>2017-08-23 22:58:05 +0200
commitdb28d652ca64befb27e4d430f9dabb70413d5da5 (patch)
treec0183517db5b6576106a4a0e62fafd5039d491be /libs/ardour/ardour/data_type.h
parentf90a70e774726a5d67fa462cab06637d4baeabc8 (diff)
Add a method to get the first DataType
Also put a comment about the ordering of DataTypes.
Diffstat (limited to 'libs/ardour/ardour/data_type.h')
-rw-r--r--libs/ardour/ardour/data_type.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/libs/ardour/ardour/data_type.h b/libs/ardour/ardour/data_type.h
index bc59aebeb6..df241d5899 100644
--- a/libs/ardour/ardour/data_type.h
+++ b/libs/ardour/ardour/data_type.h
@@ -44,6 +44,9 @@ public:
* types are added, so this number is NOT suitable for serialization,
* network, or binary anything.
*
+ * Some heuristics in Ardour's UI assume that the DataTypes are ordered
+ * from most to least likely to be the main intended type of a route.
+ *
* WARNING: The number of non-NIL entries here must match num_types.
*/
enum Symbol {
@@ -61,6 +64,8 @@ public:
: _symbol(symbol)
{}
+ static DataType front() { return DataType((Symbol) 0); }
+
/** Construct from a string (Used for loading from XML and Ports)
* The string can be as in an XML file (eg "audio" or "midi"), or a
*/