summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ChangeLog1
-rw-r--r--src/instance.c15
-rw-r--r--src/qt4_in_gtk2.cpp2
-rw-r--r--wscript20
4 files changed, 34 insertions, 4 deletions
diff --git a/ChangeLog b/ChangeLog
index 90e177e..6f7c1b8 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,6 +1,7 @@
suil (UNRELEASED) unstable; urgency=low
* Use path variables in pkgconfig files
+ * Add support for embedding X11 UIs (ui:X11UI)
-- David Robillard <d@drobilla.net> (UNRELEASED)
diff --git a/src/instance.c b/src/instance.c
index e1f8e8e..c3e983e 100644
--- a/src/instance.c
+++ b/src/instance.c
@@ -28,6 +28,7 @@
#define NS_UI "http://lv2plug.in/ns/extensions/ui#"
#define GTK2_UI_URI NS_UI "GtkUI"
#define QT4_UI_URI NS_UI "Qt4UI"
+#define X11_UI_URI NS_UI "X11UI"
SUIL_API
unsigned
@@ -44,7 +45,11 @@ suil_ui_supported(const char* container_type_uri,
} else if ((!strcmp(container_type_uri, GTK2_UI_URI)
&& !strcmp(ui_type_uri, QT4_UI_URI))
|| (!strcmp(container_type_uri, QT4_UI_URI)
- && !strcmp(ui_type_uri, GTK2_UI_URI))) {
+ && !strcmp(ui_type_uri, GTK2_UI_URI))
+ || (!strcmp(container_type_uri, GTK2_UI_URI)
+ && !strcmp(ui_type_uri, X11_UI_URI))
+ || (!strcmp(container_type_uri, QT4_UI_URI)
+ && !strcmp(ui_type_uri, X11_UI_URI))) {
return SUIL_WRAPPING_EMBEDDED;
} else {
return SUIL_WRAPPING_UNSUPPORTED;
@@ -71,8 +76,14 @@ get_wrap_module(const char* container_type_uri,
&& !strcmp(ui_type_uri, GTK2_UI_URI)) {
module_name = "libsuil_gtk2_in_qt4";
} else if (!strcmp(container_type_uri, GTK2_UI_URI)
- && !strcmp(ui_type_uri, QT4_UI_URI)) {
+ && !strcmp(ui_type_uri, QT4_UI_URI)) {
module_name = "libsuil_qt4_in_gtk2";
+ } else if (!strcmp(container_type_uri, GTK2_UI_URI)
+ && !strcmp(ui_type_uri, X11_UI_URI)) {
+ module_name = "libsuil_x11_in_gtk2";
+ } else if (!strcmp(container_type_uri, QT4_UI_URI)
+ && !strcmp(ui_type_uri, X11_UI_URI)) {
+ module_name = "libsuil_x11_in_qt4";
}
if (!module_name) {
diff --git a/src/qt4_in_gtk2.cpp b/src/qt4_in_gtk2.cpp
index 191215e..a2aa28a 100644
--- a/src/qt4_in_gtk2.cpp
+++ b/src/qt4_in_gtk2.cpp
@@ -66,7 +66,7 @@ struct _WrapWidgetPrivate {
SuilInstance* instance;
};
-G_DEFINE_TYPE(WrapWidget, wrap_widget, GTK_TYPE_SOCKET);
+G_DEFINE_TYPE(WrapWidget, wrap_widget, GTK_TYPE_SOCKET)
static void
wrap_widget_dispose(GObject* gobject)
diff --git a/wscript b/wscript
index dbe74ff..856bbbf 100644
--- a/wscript
+++ b/wscript
@@ -7,7 +7,7 @@ from waflib.extras import autowaf as autowaf
import waflib.Logs as Logs, waflib.Options as Options
# Version of this package (even if built as a child)
-SUIL_VERSION = '0.4.4'
+SUIL_VERSION = '0.4.5'
SUIL_MAJOR_VERSION = '0'
# Library version (UNIX style major, minor, micro)
@@ -122,6 +122,24 @@ def build(bld):
cflags = cflags)
autowaf.use_lib(bld, obj, 'GTK2 QT4')
+ if bld.is_defined('HAVE_GTK2'):
+ obj = bld(features = 'c cshlib',
+ source = 'src/x11_in_gtk2.c',
+ target = 'suil_x11_in_gtk2',
+ includes = ['.'],
+ install_path = module_dir,
+ cflags = cflags)
+ autowaf.use_lib(bld, obj, 'GTK2')
+
+ if bld.is_defined('HAVE_QT4'):
+ obj = bld(features = 'cxx cxxshlib',
+ source = 'src/x11_in_qt4.cpp',
+ target = 'suil_x11_in_qt4',
+ includes = ['.'],
+ install_path = module_dir,
+ cflags = cflags)
+ autowaf.use_lib(bld, obj, 'QT4')
+
# Documentation
autowaf.build_dox(bld, 'SUIL', SUIL_VERSION, top, out)