changeset 35:0164c8d3023b

* Rejig project file a bit to do pkg-config detection &c and change some HAVE_* symbol names accordingly * Add selection move/resize/delete * First stubs for add layer / pane commands
author Chris Cannam
date Wed, 01 Mar 2006 18:13:01 +0000
parents aaf73f7309f2
children 935a2419a77c
files base/Layer.h plugin/DSSIPluginFactory.cpp plugin/DSSIPluginFactory.h plugin/LADSPAPluginFactory.cpp plugin/LADSPAPluginFactory.h
diffstat 5 files changed, 24 insertions(+), 17 deletions(-) [+]
line wrap: on
line diff
--- a/base/Layer.h	Mon Feb 27 17:34:41 2006 +0000
+++ b/base/Layer.h	Wed Mar 01 18:13:01 2006 +0000
@@ -13,6 +13,7 @@
 
 #include "PropertyContainer.h"
 #include "XmlExportable.h"
+#include "Selection.h"
 
 #include <QObject>
 #include <QRect>
@@ -40,6 +41,7 @@
     virtual ~Layer();
 
     virtual const Model *getModel() const = 0;
+    virtual const View *getView() const { return m_view; }
     virtual const ZoomConstraint *getZoomConstraint() const { return 0; }
     virtual void paint(QPainter &, QRect) const = 0;   
 
@@ -119,6 +121,11 @@
 
     virtual void editOpen(QMouseEvent *) { } // on double-click
 
+    virtual void moveSelection(Selection s, size_t newStartFrame) { }
+    virtual void resizeSelection(Selection s, Selection newSize) { }
+    virtual void deleteSelection(Selection s) { }
+
+
     // Text mode:
     //
     // Label nearest feature.  We need to get the feature coordinates
--- a/plugin/DSSIPluginFactory.cpp	Mon Feb 27 17:34:41 2006 +0000
+++ b/plugin/DSSIPluginFactory.cpp	Wed Mar 01 18:13:01 2006 +0000
@@ -26,9 +26,9 @@
 
 #include "base/System.h"
 
-#ifdef HAVE_LIBLRDF
+#ifdef HAVE_LRDF
 #include "lrdf.h"
-#endif // HAVE_LIBLRDF
+#endif // HAVE_LRDF
 
 
 DSSIPluginFactory::DSSIPluginFactory() :
@@ -217,7 +217,7 @@
 }
 
 
-#ifdef HAVE_LIBLRDF
+#ifdef HAVE_LRDF
 std::vector<QString>
 DSSIPluginFactory::getLRDFPath(QString &baseUri)
 {
@@ -280,7 +280,7 @@
 	    continue;
 	}
 
-#ifdef HAVE_LIBLRDF
+#ifdef HAVE_LRDF
 	char *def_uri = 0;
 	lrdf_defaults *defs = 0;
 		
@@ -330,7 +330,7 @@
 		++controlPortNumber;
 	    }
 	}
-#endif // HAVE_LIBLRDF
+#endif // HAVE_LRDF
 
 	QString identifier = PluginIdentifier::createIdentifier
 	    ("dssi", soname, ladspaDescriptor->Label);
--- a/plugin/DSSIPluginFactory.h	Mon Feb 27 17:34:41 2006 +0000
+++ b/plugin/DSSIPluginFactory.h	Wed Mar 01 18:13:01 2006 +0000
@@ -45,7 +45,7 @@
 
     virtual std::vector<QString> getPluginPath();
 
-#ifdef HAVE_LIBLRDF
+#ifdef HAVE_LRDF
     virtual std::vector<QString> getLRDFPath(QString &baseUri);
 #endif
 
--- a/plugin/LADSPAPluginFactory.cpp	Mon Feb 27 17:34:41 2006 +0000
+++ b/plugin/LADSPAPluginFactory.cpp	Wed Mar 01 18:13:01 2006 +0000
@@ -27,9 +27,9 @@
 
 #include "base/System.h"
 
-#ifdef HAVE_LIBLRDF
+#ifdef HAVE_LRDF
 #include "lrdf.h"
-#endif // HAVE_LIBLRDF
+#endif // HAVE_LRDF
 
 
 LADSPAPluginFactory::LADSPAPluginFactory()
@@ -453,7 +453,7 @@
 }
 
 
-#ifdef HAVE_LIBLRDF
+#ifdef HAVE_LRDF
 std::vector<QString>
 LADSPAPluginFactory::getLRDFPath(QString &baseUri)
 {
@@ -486,7 +486,7 @@
     }
     std::cerr << std::endl;
 
-#ifdef HAVE_LIBLRDF
+#ifdef HAVE_LRDF
     // Initialise liblrdf and read the description files 
     //
     lrdf_init();
@@ -509,7 +509,7 @@
     if (haveSomething) {
 	generateTaxonomy(baseUri + "Plugin", "");
     }
-#endif // HAVE_LIBLRDF
+#endif // HAVE_LRDF
 
     generateFallbackCategories();
 
@@ -523,11 +523,11 @@
 	}
     }
 
-#ifdef HAVE_LIBLRDF
+#ifdef HAVE_LRDF
     // Cleanup after the RDF library
     //
     lrdf_cleanup();
-#endif // HAVE_LIBLRDF
+#endif // HAVE_LRDF
 }
 
 void
@@ -554,7 +554,7 @@
     int index = 0;
     while ((descriptor = fn(index))) {
 
-#ifdef HAVE_LIBLRDF
+#ifdef HAVE_LRDF
 	char *def_uri = 0;
 	lrdf_defaults *defs = 0;
 		
@@ -600,7 +600,7 @@
 		++controlPortNumber;
 	    }
 	}
-#endif // HAVE_LIBLRDF
+#endif // HAVE_LRDF
 
 	QString identifier = PluginIdentifier::createIdentifier
 	    ("ladspa", soname, descriptor->Label);
@@ -664,7 +664,7 @@
 void
 LADSPAPluginFactory::generateTaxonomy(QString uri, QString base)
 {
-#ifdef HAVE_LIBLRDF
+#ifdef HAVE_LRDF
     lrdf_uris *uris = lrdf_get_instances(uri.toStdString().c_str());
 
     if (uris != NULL) {
--- a/plugin/LADSPAPluginFactory.h	Mon Feb 27 17:34:41 2006 +0000
+++ b/plugin/LADSPAPluginFactory.h	Wed Mar 01 18:13:01 2006 +0000
@@ -55,7 +55,7 @@
 
     virtual std::vector<QString> getPluginPath();
 
-#ifdef HAVE_LIBLRDF
+#ifdef HAVE_LRDF
     virtual std::vector<QString> getLRDFPath(QString &baseUri);
 #endif