commit c8d968a230e509c3b886e4482c17de8e4f466f35
parent 0393d1e42956ea707488be47f82d65c6cbd20a4d
Author: falkTX <falktx@gmail.com>
Date: Mon, 1 Jan 2018 12:42:55 +0100
Fix build with custom DGL namespace, use it for OSX class names
Diffstat:
3 files changed, 9 insertions(+), 6 deletions(-)
diff --git a/dgl/src/pugl/pugl_osx.m b/dgl/src/pugl/pugl_osx.m
@@ -24,6 +24,9 @@
#include "pugl_internal.h"
+#define PuglWindow PuglWindow ## DGL_NAMESPACE
+#define PuglOpenGLView PuglOpenGLView ## DGL_NAMESPACE
+
@interface PuglWindow : NSWindow
{
@public
diff --git a/distrho/DistrhoUI.hpp b/distrho/DistrhoUI.hpp
@@ -25,10 +25,10 @@
typedef DISTRHO_NAMESPACE::ExternalWindow UIWidget;
#elif DISTRHO_UI_USE_NANOVG
# include "../dgl/NanoVG.hpp"
-typedef DGL::NanoWidget UIWidget;
+typedef DGL_NAMESPACE::NanoWidget UIWidget;
#else
# include "../dgl/Widget.hpp"
-typedef DGL::Widget UIWidget;
+typedef DGL_NAMESPACE::Widget UIWidget;
#endif
START_NAMESPACE_DISTRHO
@@ -214,7 +214,7 @@ private:
void setAbsoluteX(int) const noexcept {}
void setAbsoluteY(int) const noexcept {}
void setAbsolutePos(int, int) const noexcept {}
- void setAbsolutePos(const DGL::Point<int>&) const noexcept {}
+ void setAbsolutePos(const DGL_NAMESPACE::Point<int>&) const noexcept {}
#endif
DISTRHO_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR(UI)
diff --git a/distrho/src/DistrhoUIInternal.hpp b/distrho/src/DistrhoUIInternal.hpp
@@ -22,9 +22,9 @@
#ifdef HAVE_DGL
# include "../../dgl/Application.hpp"
# include "../../dgl/Window.hpp"
-using DGL::Application;
-using DGL::IdleCallback;
-using DGL::Window;
+using DGL_NAMESPACE::Application;
+using DGL_NAMESPACE::IdleCallback;
+using DGL_NAMESPACE::Window;
#endif
START_NAMESPACE_DISTRHO