aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHanspeter Portner <dev@open-music-kontrollers.ch>2022-07-16 01:21:50 +0200
committerHanspeter Portner <dev@open-music-kontrollers.ch>2022-07-16 01:21:50 +0200
commitba3644ca88d728561fa8fe4b33131b1fa06d3478 (patch)
tree7edd1a7ca6d9f9068a67ef47e4c2adc086a1f002
parentea7a82e5de95167ea729aec6163107c3a02db7f2 (diff)
downloadmoony.lv2-master.tar.xz
deprecate ui:resize feature/extensionHEADmaster
-rw-r--r--VERSION2
-rw-r--r--plugin/d2tk_ui.c26
-rw-r--r--plugin/moony_ui.ttl8
-rw-r--r--plugin/nk_ui.c23
4 files changed, 10 insertions, 49 deletions
diff --git a/VERSION b/VERSION
index 126de13..9ed317f 100644
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-0.40.0 cut -d. -f1.41.1
+0.41.1
diff --git a/plugin/d2tk_ui.c b/plugin/d2tk_ui.c
index 9baac05..837e80b 100644
--- a/plugin/d2tk_ui.c
+++ b/plugin/d2tk_ui.c
@@ -2184,7 +2184,6 @@ instantiate(const LV2UI_Descriptor *descriptor,
return NULL;
void *parent = NULL;
- LV2UI_Resize *host_resize = NULL;
LV2UI_Port_Map *port_map = NULL;
LV2_Options_Option *opts = NULL;
for(int i=0; features[i]; i++)
@@ -2193,10 +2192,6 @@ instantiate(const LV2UI_Descriptor *descriptor,
{
parent = features[i]->data;
}
- else if(!strcmp(features[i]->URI, LV2_UI__resize))
- {
- host_resize = features[i]->data;
- }
else if(!strcmp(features[i]->URI, LV2_URID__map))
{
handle->map = features[i]->data;
@@ -2384,11 +2379,6 @@ instantiate(const LV2UI_Descriptor *descriptor,
handle->state.font_height = 16;
_update_font_height(handle);
- if(host_resize)
- {
- host_resize->ui_resize(host_resize->handle, w, h);
- }
-
strncpy(handle->template, "/tmp/XXXXXX.lua", sizeof(handle->template));
handle->fd = mkstemps(handle->template, 4);
if(handle->fd == -1)
@@ -2521,25 +2511,13 @@ static const LV2UI_Idle_Interface idle_ext = {
.idle = _idle
};
-static int
-_resize(LV2UI_Handle instance, int width, int height)
-{
- plughandle_t *handle = instance;
-
- return d2tk_frontend_set_size(handle->dpugl, width, height);
-}
-
-static const LV2UI_Resize resize_ext = {
- .ui_resize = _resize
-};
-
static const void *
_extension_data(const char *uri)
{
if(!strcmp(uri, LV2_UI__idleInterface))
+ {
return &idle_ext;
- else if(!strcmp(uri, LV2_UI__resize))
- return &resize_ext;
+ }
return NULL;
}
diff --git a/plugin/moony_ui.ttl b/plugin/moony_ui.ttl
index 0b2eb93..65c3d0b 100644
--- a/plugin/moony_ui.ttl
+++ b/plugin/moony_ui.ttl
@@ -62,9 +62,9 @@ moony:moony_ui
ui:protocol atom:eventTransfer ;
] ;
lv2:requiredFeature ui:idleInterface, ui:portMap, urid:map, urid:unmap, ui:parent ;
- lv2:optionalFeature ui:resize, opts:options, log:log ;
+ lv2:optionalFeature opts:options, log:log ;
opts:supportedOption ui:scaleFactor ;
- lv2:extensionData ui:idleInterface, ui:resize .
+ lv2:extensionData ui:idleInterface .
moony:moony_d2tk
ui:portNotification [
@@ -105,6 +105,6 @@ moony:moony_d2tk
ui:protocol atom:eventTransfer ;
] ;
lv2:requiredFeature ui:idleInterface, ui:portMap, urid:map, urid:unmap, ui:parent ;
- lv2:optionalFeature ui:resize, ui:requestValue, opts:options, log:log ;
+ lv2:optionalFeature ui:requestValue, opts:options, log:log ;
opts:supportedOption ui:scaleFactor ;
- lv2:extensionData ui:idleInterface, ui:resize .
+ lv2:extensionData ui:idleInterface .
diff --git a/plugin/nk_ui.c b/plugin/nk_ui.c
index 51882be..4989372 100644
--- a/plugin/nk_ui.c
+++ b/plugin/nk_ui.c
@@ -2890,7 +2890,6 @@ instantiate(const LV2UI_Descriptor *descriptor, const char *plugin_uri,
srand(time(NULL));
void *parent = NULL;
- LV2UI_Resize *host_resize = NULL;
LV2UI_Port_Map *port_map = NULL;
LV2_Options_Option *opts = NULL;
for(int i=0; features[i]; i++)
@@ -2899,10 +2898,6 @@ instantiate(const LV2UI_Descriptor *descriptor, const char *plugin_uri,
{
parent = features[i]->data;
}
- else if(!strcmp(features[i]->URI, LV2_UI__resize))
- {
- host_resize = features[i]->data;
- }
else if(!strcmp(features[i]->URI, LV2_UI__portMap))
{
port_map = features[i]->data;
@@ -3096,7 +3091,7 @@ instantiate(const LV2UI_Descriptor *descriptor, const char *plugin_uri,
cfg->class = "moony";
cfg->title = "Moony";
cfg->parent = (intptr_t)parent;
- cfg->host_resize = host_resize;
+ cfg->host_resize = NULL;
cfg->data = handle;
cfg->expose = _expose;
@@ -3931,25 +3926,13 @@ static const LV2UI_Idle_Interface idle_ext = {
.idle = _idle
};
-static int
-_resize(LV2UI_Handle instance, int width, int height)
-{
- plughandle_t *handle = instance;
-
- return nk_pugl_resize(&handle->win, width, height);
-}
-
-static const LV2UI_Resize resize_ext = {
- .ui_resize = _resize
-};
-
static const void *
ext_data(const char *uri)
{
if(!strcmp(uri, LV2_UI__idleInterface))
+ {
return &idle_ext;
- else if(!strcmp(uri, LV2_UI__resize))
- return &resize_ext;
+ }
return NULL;
}