aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Hanspeter Portner <dev@open-music-kontrollers.ch>2017-10-20 12:23:55 +0200
committerGravatar Hanspeter Portner <dev@open-music-kontrollers.ch>2017-10-20 12:23:55 +0200
commitefcf34fb773111e633870a7d6327548bc499c0f9 (patch)
treebabd4a7455cb1884d7a283ba230f66635fc3faf0
parent7938006ddec524ca41593d36cf095ba81adf10fc (diff)
downloadnuk.lv2-efcf34fb773111e633870a7d6327548bc499c0f9.zip
nuk.lv2-efcf34fb773111e633870a7d6327548bc499c0f9.tar.gz
nuk.lv2-efcf34fb773111e633870a7d6327548bc499c0f9.tar.bz2
nuk.lv2-efcf34fb773111e633870a7d6327548bc499c0f9.tar.xz
nk: fixes for updated nuklear.
-rw-r--r--VERSION2
-rw-r--r--nuk_ui.c11
2 files changed, 7 insertions, 6 deletions
diff --git a/VERSION b/VERSION
index b7978fd..0ccf3e3 100644
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-0.1.2857
+0.1.2867
diff --git a/nuk_ui.c b/nuk_ui.c
index 30d0758..30189a0 100644
--- a/nuk_ui.c
+++ b/nuk_ui.c
@@ -112,10 +112,10 @@ _dial_float(struct nk_context *ctx, float min, float *val, float max, float mul)
}
else if(nk_input_is_mouse_hovering_rect(in, bounds))
{
- if(in->mouse.scroll_delta != 0.f) // has scrolling
+ if(in->mouse.scroll_delta.y != 0.f) // has scrolling
{
- dd = in->mouse.scroll_delta;
- in->mouse.scroll_delta = 0.f;
+ dd = in->mouse.scroll_delta.y;
+ in->mouse.scroll_delta.y = 0.f;
}
bg = &ctx->style.progress.hover;
@@ -168,10 +168,11 @@ _expose(struct nk_context *ctx, struct nk_rect wbounds, void *data)
const float width2 = wbounds.w/2;
const float height2 = wbounds.h/2;
- if(nk_begin(ctx, "Nuk", wbounds, NK_WINDOW_CLOSABLE | NK_WINDOW_NO_SCROLLBAR))
+ const char *window_name = "Nuk";
+ if(nk_begin(ctx, window_name, wbounds, NK_WINDOW_CLOSABLE | NK_WINDOW_NO_SCROLLBAR))
{
const struct nk_panel *root = nk_window_get_panel(ctx);
- nk_window_set_bounds(ctx, wbounds);
+ nk_window_set_bounds(ctx, window_name, wbounds);
const nk_flags nuk_f = NK_WINDOW_BORDER | NK_WINDOW_TITLE;
const float nuk_h = root->bounds.h - root->footer_height;