From 9c3d03cfab2ac6eda5c87325dcd3174e5812bc39 Mon Sep 17 00:00:00 2001 From: David Robillard Date: Sat, 29 Nov 2008 00:20:28 +0000 Subject: Only write index for Patches (i.e. don't even save the index of plugin ports, as per LV2r3). git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@1821 a436a847-0d15-0410-975c-d299462d15a1 --- src/serialisation/Serialiser.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/serialisation/Serialiser.cpp') diff --git a/src/serialisation/Serialiser.cpp b/src/serialisation/Serialiser.cpp index b9eff1f2..baf8a475 100644 --- a/src/serialisation/Serialiser.cpp +++ b/src/serialisation/Serialiser.cpp @@ -440,8 +440,9 @@ Serialiser::serialise_port(const Port* port, const Redland::Node& port_id) _model->add_statement(port_id, "rdf:type", Redland::Node(_model->world(), Redland::Node::RESOURCE, "lv2:OutputPort")); - _model->add_statement(port_id, "lv2:index", - AtomRDF::atom_to_node(_model->world(), Atom((int)port->index()))); + if (dynamic_cast(port->graph_parent())) + _model->add_statement(port_id, "lv2:index", + AtomRDF::atom_to_node(_model->world(), Atom((int)port->index()))); _model->add_statement(port_id, "lv2:symbol", Redland::Node(_model->world(), Redland::Node::LITERAL, port->path().name())); -- cgit v1.2.1