diff transform/TransformFactory.h @ 34:8ad306d8a568

* Pull transforms out of Layer menu (again) and into a separate Transforms menu * Add Recent Transforms submenu * Add effects and generators to the transforms menu (not yet implemented) as well as analysis plugins and data-from-effects (control output ports) * Add a nice dictionary-volume-style alphabetic subdivision of plugin names in plugins By Name menus
author Chris Cannam
date Fri, 22 Sep 2006 16:12:23 +0000
parents 544ab25d2372
children fbd7a497fd89
line wrap: on
line diff
--- a/transform/TransformFactory.h	Thu Sep 21 16:43:50 2006 +0000
+++ b/transform/TransformFactory.h	Fri Sep 22 16:12:23 2006 +0000
@@ -41,6 +41,7 @@
     // to be user-readable, for use in menus.
 
     struct TransformDesc {
+
         TransformDesc() { }
 	TransformDesc(QString _type, QString _category,
                       TransformName _name, QString _description,
@@ -50,6 +51,7 @@
             name(_name), description(_description),
             friendlyName(_friendlyName),
             maker(_maker), units(_units), configurable(_configurable) { }
+
         QString type;
         QString category;
 	TransformName name;
@@ -58,6 +60,10 @@
         QString maker;
         QString units;
         bool configurable;
+
+        bool operator<(const TransformDesc &od) const {
+            return (description < od.description);
+        };
     };
     typedef std::vector<TransformDesc> TransformList;
 
@@ -119,7 +125,7 @@
      * If the transform has a prescribed number or range of channel
      * inputs, return true and set minChannels and maxChannels to the
      * minimum and maximum number of channel inputs the transform can
-     * accept.
+     * accept.  Return false if it doesn't care.
      */
     bool getTransformChannelRange(TransformName name,
                                   int &minChannels, int &maxChannels);