From 030bdc723413808ce738d399fc8758c55b02af69 Mon Sep 17 00:00:00 2001 From: David Robillard Date: Fri, 16 Mar 2012 21:30:05 +0000 Subject: Properly implement non-resizable UIs, not that any plugins that should set this seem to actually do so... git-svn-id: http://svn.drobilla.net/lad/trunk/jalv@4069 a436a847-0d15-0410-975c-d299462d15a1 --- src/jalv.c | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) (limited to 'src/jalv.c') diff --git a/src/jalv.c b/src/jalv.c index 8deea96..d71d2b4 100644 --- a/src/jalv.c +++ b/src/jalv.c @@ -54,6 +54,7 @@ #define NS_MIDI "http://lv2plug.in/ns/ext/midi#" #define NS_PSET "http://lv2plug.in/ns/ext/presets#" #define NS_RDF "http://www.w3.org/1999/02/22-rdf-syntax-ns#" +#define NS_UI "http://lv2plug.in/ns/extensions/ui#" #define USTR(str) ((const uint8_t*)str) @@ -535,6 +536,22 @@ jack_session_cb(jack_session_event_t* event, void* arg) } #endif /* JALV_JACK_SESSION */ +bool +jalv_ui_is_resizable(Jalv* jalv) +{ + const LilvNode* s = lilv_ui_get_uri(jalv->ui); + LilvNode* p = lilv_new_uri(jalv->world, LV2_CORE__requiredFeature); + LilvNode* o = lilv_new_uri(jalv->world, NS_UI "fixedSize"); + + LilvNodes* matches = lilv_world_find_nodes(jalv->world, s, p, o); + + lilv_node_free(o); + lilv_node_free(p); + lilv_nodes_free(matches); + + return matches == NULL; +} + void jalv_ui_write(SuilController controller, uint32_t port_index, -- cgit v1.2.1