Browse Source

Fix build with custom DGL namespace, use it for OSX class names

pull/32/head
falkTX 7 years ago
parent
commit
c8d968a230
3 changed files with 9 additions and 6 deletions
  1. +3
    -0
      dgl/src/pugl/pugl_osx.m
  2. +3
    -3
      distrho/DistrhoUI.hpp
  3. +3
    -3
      distrho/src/DistrhoUIInternal.hpp

+ 3
- 0
dgl/src/pugl/pugl_osx.m View File

@@ -24,6 +24,9 @@

#include "pugl_internal.h"

#define PuglWindow PuglWindow ## DGL_NAMESPACE
#define PuglOpenGLView PuglOpenGLView ## DGL_NAMESPACE

@interface PuglWindow : NSWindow
{
@public


+ 3
- 3
distrho/DistrhoUI.hpp View File

@@ -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)


+ 3
- 3
distrho/src/DistrhoUIInternal.hpp View File

@@ -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


Loading…
Cancel
Save