summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ingen/URIs.hpp1
-rw-r--r--ingen/client/ObjectModel.hpp2
-rw-r--r--ingen/client/PortModel.hpp16
-rw-r--r--src/URIs.cpp1
-rw-r--r--src/client/ObjectModel.cpp4
-rw-r--r--src/client/PortModel.cpp10
-rw-r--r--src/gui/NodeModule.cpp2
-rw-r--r--src/server/PortImpl.cpp5
-rw-r--r--src/server/PortImpl.hpp2
9 files changed, 21 insertions, 22 deletions
diff --git a/ingen/URIs.hpp b/ingen/URIs.hpp
index 7ef4385b..a76e6dce 100644
--- a/ingen/URIs.hpp
+++ b/ingen/URIs.hpp
@@ -135,6 +135,7 @@ public:
const Quark lv2_connectionOptional;
const Quark lv2_default;
const Quark lv2_designation;
+ const Quark lv2_enumeration;
const Quark lv2_extensionData;
const Quark lv2_index;
const Quark lv2_integer;
diff --git a/ingen/client/ObjectModel.hpp b/ingen/client/ObjectModel.hpp
index 69601bc2..42849110 100644
--- a/ingen/client/ObjectModel.hpp
+++ b/ingen/client/ObjectModel.hpp
@@ -58,7 +58,7 @@ class INGEN_API ObjectModel : public Node
public:
virtual ~ObjectModel();
- bool is_a(const Raul::URI& type) const;
+ bool is_a(const URIs::Quark& type) const;
const Atom& get_property(const Raul::URI& key) const;
diff --git a/ingen/client/PortModel.hpp b/ingen/client/PortModel.hpp
index 8fe7e445..0d921fb1 100644
--- a/ingen/client/PortModel.hpp
+++ b/ingen/client/PortModel.hpp
@@ -42,7 +42,7 @@ public:
GraphType graph_type() const { return Node::GraphType::PORT; }
- bool supports(const Raul::URI& value_type) const;
+ bool supports(const URIs::Quark& value_type) const;
inline uint32_t index() const { return _index; }
inline const Atom& value() const { return get_property(_uris.ingen_value); }
@@ -50,15 +50,15 @@ public:
inline bool is_input() const { return (_direction == Direction::INPUT); }
inline bool is_output() const { return (_direction == Direction::OUTPUT); }
- bool port_property(const Raul::URI& uri) const;
+ bool port_property(const URIs::Quark& uri) const;
- bool is_logarithmic() const { return port_property(Raul::URI(LV2_PORT_PROPS__logarithmic)); }
- bool is_enumeration() const { return port_property(Raul::URI(LV2_CORE__enumeration)); }
- bool is_integer() const { return port_property(Raul::URI(LV2_CORE__integer)); }
- bool is_toggle() const { return port_property(Raul::URI(LV2_CORE__toggled)); }
+ bool is_logarithmic() const { return port_property(_uris.pprops_logarithmic); }
+ bool is_enumeration() const { return port_property(_uris.lv2_enumeration); }
+ bool is_integer() const { return port_property(_uris.lv2_integer); }
+ bool is_toggle() const { return port_property(_uris.lv2_toggled); }
bool is_numeric() const {
- return ObjectModel::is_a(Raul::URI(LV2_CORE__ControlPort))
- || ObjectModel::is_a(Raul::URI(LV2_CORE__CVPort));
+ return ObjectModel::is_a(_uris.lv2_ControlPort)
+ || ObjectModel::is_a(_uris.lv2_CVPort);
}
bool is_uri() const;
diff --git a/src/URIs.cpp b/src/URIs.cpp
index e25257a2..57a17ce0 100644
--- a/src/URIs.cpp
+++ b/src/URIs.cpp
@@ -117,6 +117,7 @@ URIs::URIs(Forge& f, URIMap* map, LilvWorld* lworld)
, lv2_connectionOptional(forge, map, lworld, LV2_CORE__connectionOptional)
, lv2_default (forge, map, lworld, LV2_CORE__default)
, lv2_designation (forge, map, lworld, LV2_CORE__designation)
+ , lv2_enumeration (forge, map, lworld, LV2_CORE__enumeration)
, lv2_extensionData (forge, map, lworld, LV2_CORE__extensionData)
, lv2_index (forge, map, lworld, LV2_CORE__index)
, lv2_integer (forge, map, lworld, LV2_CORE__integer)
diff --git a/src/client/ObjectModel.cpp b/src/client/ObjectModel.cpp
index 46282705..98f54cbe 100644
--- a/src/client/ObjectModel.cpp
+++ b/src/client/ObjectModel.cpp
@@ -41,9 +41,9 @@ ObjectModel::~ObjectModel()
}
bool
-ObjectModel::is_a(const Raul::URI& type) const
+ObjectModel::is_a(const URIs::Quark& type) const
{
- return has_property(_uris.rdf_type, _uris.forge.alloc_uri(type));
+ return has_property(_uris.rdf_type, type);
}
void
diff --git a/src/client/PortModel.cpp b/src/client/PortModel.cpp
index cd2ebb2a..9b534ae1 100644
--- a/src/client/PortModel.cpp
+++ b/src/client/PortModel.cpp
@@ -37,17 +37,15 @@ PortModel::on_property(const Raul::URI& uri, const Atom& value)
}
bool
-PortModel::supports(const Raul::URI& value_type) const
+PortModel::supports(const URIs::Quark& value_type) const
{
- return has_property(_uris.atom_supports,
- _uris.forge.alloc_uri(value_type));
+ return has_property(_uris.atom_supports, value_type);
}
bool
-PortModel::port_property(const Raul::URI& uri) const
+PortModel::port_property(const URIs::Quark& uri) const
{
- return has_property(_uris.lv2_portProperty,
- _uris.forge.alloc_uri(uri));
+ return has_property(_uris.lv2_portProperty, uri);
}
bool
diff --git a/src/gui/NodeModule.cpp b/src/gui/NodeModule.cpp
index 86d0c8e6..ae9a997d 100644
--- a/src/gui/NodeModule.cpp
+++ b/src/gui/NodeModule.cpp
@@ -175,7 +175,7 @@ NodeModule::port_activity(uint32_t index, const Atom& value)
return;
}
- if (_block->get_port(index)->is_a(Raul::URI(LV2_ATOM__AtomPort))) {
+ if (_block->get_port(index)->is_a(uris.atom_AtomPort)) {
_plugin_ui->port_event(index,
lv2_atom_total_size(value.atom()),
uris.atom_eventTransfer,
diff --git a/src/server/PortImpl.cpp b/src/server/PortImpl.cpp
index f943fbb8..ea71568c 100644
--- a/src/server/PortImpl.cpp
+++ b/src/server/PortImpl.cpp
@@ -141,10 +141,9 @@ PortImpl::has_value() const
}
bool
-PortImpl::supports(const Raul::URI& value_type) const
+PortImpl::supports(const URIs::Quark& value_type) const
{
- return has_property(_bufs.uris().atom_supports,
- _bufs.forge().alloc_uri(value_type));
+ return has_property(_bufs.uris().atom_supports, value_type);
}
void
diff --git a/src/server/PortImpl.hpp b/src/server/PortImpl.hpp
index a59925ab..98a9d81e 100644
--- a/src/server/PortImpl.hpp
+++ b/src/server/PortImpl.hpp
@@ -174,7 +174,7 @@ public:
PortType type() const { return _type; }
LV2_URID buffer_type() const { return _buffer_type; }
- bool supports(const Raul::URI& value_type) const;
+ bool supports(const URIs::Quark& value_type) const;
size_t buffer_size() const { return _buffer_size; }