aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHanspeter Portner <dev@open-music-kontrollers.ch>2016-10-28 10:36:19 +0200
committerHanspeter Portner <dev@open-music-kontrollers.ch>2016-10-28 10:36:19 +0200
commit7a9500aa25a7e610e31e26f44e0508b4c3dabc15 (patch)
tree1736b8d82c26de3ac1777b83b7f37ecedd832898
parentc0ca27488d0902ba400037161ad32edbbd4a150d (diff)
downloadsherlock.lv2-7a9500aa25a7e610e31e26f44e0508b4c3dabc15.tar.xz
implement ui:noUserResize.
-rw-r--r--sandbox_slave.c17
-rw-r--r--sandbox_slave.h3
2 files changed, 20 insertions, 0 deletions
diff --git a/sandbox_slave.c b/sandbox_slave.c
index b0c3bec..a5ae98b 100644
--- a/sandbox_slave.c
+++ b/sandbox_slave.c
@@ -53,6 +53,7 @@ struct _sandbox_slave_t {
const LilvPlugin *plug;
const LilvUI *ui;
+ bool no_user_resize;
void *lib;
const LV2UI_Descriptor *desc;
void *handle;
@@ -317,6 +318,13 @@ sandbox_slave_new(int argc, char **argv, const sandbox_slave_driver_t *driver, v
goto fail;
}
+ LilvNode *no_user_resize_uri = lilv_new_uri(sb->world, LV2_UI__noUserResize);
+ if(no_user_resize_uri)
+ {
+ sb->no_user_resize = lilv_world_ask(sb->world, sb->ui_node, no_user_resize_uri, NULL);
+ lilv_node_free(no_user_resize_uri);
+ }
+
#if defined(LILV_0_22)
char *binary_path = lilv_file_uri_parse(lilv_node_as_string(ui_path), NULL);
#else
@@ -559,3 +567,12 @@ sandbox_slave_title_get(sandbox_slave_t *sb)
return NULL;
}
+
+bool
+sandbox_slave_no_user_resize_get(sandbox_slave_t *sb)
+{
+ if(sb)
+ return sb->no_user_resize;
+
+ return false;
+}
diff --git a/sandbox_slave.h b/sandbox_slave.h
index dcd78bb..7616fc3 100644
--- a/sandbox_slave.h
+++ b/sandbox_slave.h
@@ -66,6 +66,9 @@ sandbox_slave_fd_get(sandbox_slave_t *sb, int *fd);
const char *
sandbox_slave_title_get(sandbox_slave_t *sb);
+bool
+sandbox_slave_no_user_resize_get(sandbox_slave_t *sb);
+
#ifdef __cplusplus
}
#endif