aboutsummaryrefslogtreecommitdiff
path: root/atom_inspector_nk.c
diff options
context:
space:
mode:
authorHanspeter Portner <dev@open-music-kontrollers.ch>2017-05-10 23:20:07 +0200
committerHanspeter Portner <dev@open-music-kontrollers.ch>2017-05-10 23:20:07 +0200
commit5275019820f74aaf8858b334e1640c7fbcda9261 (patch)
tree30afe2e1be5516bc73bd871f35b7449bc84f7ab0 /atom_inspector_nk.c
parent7713b47006f76cc332981c634e4293028960252b (diff)
downloadsherlock.lv2-5275019820f74aaf8858b334e1640c7fbcda9261.tar.xz
only consider number atoms as primitives.
Diffstat (limited to 'atom_inspector_nk.c')
-rw-r--r--atom_inspector_nk.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/atom_inspector_nk.c b/atom_inspector_nk.c
index fc886dd..ed639d3 100644
--- a/atom_inspector_nk.c
+++ b/atom_inspector_nk.c
@@ -200,12 +200,14 @@ _atom_inspector_expose(struct nk_context *ctx, struct nk_rect wbounds, void *dat
|| (body->type == handle->forge.Int)
|| (body->type == handle->forge.Long)
|| (body->type == handle->forge.Float)
- || (body->type == handle->forge.Double)
+ || (body->type == handle->forge.Double);
+ /*
|| (body->type == handle->forge.String)
|| (body->type == handle->forge.URI)
|| (body->type == handle->forge.URID)
|| (body->type == handle->forge.Path)
|| (body->type == handle->forge.Literal);
+ */
nk_layout_row_begin(ctx, NK_DYNAMIC, widget_h, 3 + is_primitive);
{
@@ -258,6 +260,7 @@ _atom_inspector_expose(struct nk_context *ctx, struct nk_rect wbounds, void *dat
const LV2_Atom_Double *ref = (const LV2_Atom_Double *)body;
nk_labelf_colored(ctx, NK_TEXT_RIGHT, green, "%lf", ref->body);
}
+ /*
else if(body->type == handle->forge.String)
{
nk_label_colored(ctx, LV2_ATOM_BODY_CONST(body), NK_TEXT_RIGHT, red);
@@ -268,7 +271,8 @@ _atom_inspector_expose(struct nk_context *ctx, struct nk_rect wbounds, void *dat
}
else if(body->type == handle->forge.URID)
{
- const char *_uri = "urn"; //FIXME
+ const LV2_Atom_URID *urid = (const LV2_Atom_URID *)body;
+ const char *_uri = handle->unmap->unmap(handle->unmap->handle, urid->body);
nk_label_colored(ctx, _uri, NK_TEXT_RIGHT, yellow);
}
else if(body->type == handle->forge.Path)
@@ -279,6 +283,7 @@ _atom_inspector_expose(struct nk_context *ctx, struct nk_rect wbounds, void *dat
{
nk_label_colored(ctx, LV2_ATOM_CONTENTS_CONST(LV2_Atom_Literal, body), NK_TEXT_RIGHT, red);
}
+ */
}
nk_layout_row_push(ctx, 0.1);