summaryrefslogtreecommitdiff
path: root/vcl/source/opengl
diff options
context:
space:
mode:
authorTor Lillqvist <tml@collabora.com>2015-12-08 13:58:27 +0200
committerTor Lillqvist <tml@collabora.com>2015-12-08 14:03:33 +0200
commitdff18c2be9c72aa05940982f506804eb41d3d79a (patch)
treec3105a0bb2cc5d9b0943af928ffc44f407384b9a /vcl/source/opengl
parent4c4999d944bbf8a34f8a320b8de6f4a325bd5d97 (diff)
Bin the pointless and thin OS X specific wrapper namespace 'OpenGLWrapper'
Besides, the namespace was confusingly named the same as the public cross-platform OpenGLWrapper struct (which is effectively just a namespace, too). Change-Id: I9a5255ec446dcdb5086d92a742f29327d0780685
Diffstat (limited to 'vcl/source/opengl')
-rw-r--r--vcl/source/opengl/OpenGLContext.cxx13
1 files changed, 7 insertions, 6 deletions
diff --git a/vcl/source/opengl/OpenGLContext.cxx b/vcl/source/opengl/OpenGLContext.cxx
index 4a68ab823bf7..8c5db0fe9708 100644
--- a/vcl/source/opengl/OpenGLContext.cxx
+++ b/vcl/source/opengl/OpenGLContext.cxx
@@ -20,7 +20,8 @@
#if defined(MACOSX)
#include <premac.h>
-#include "OpenGLWrapper.hxx"
+#include <AppKit/NSOpenGLView.h>
+#include <AppKit/NSOpenGL.h>
#include <postmac.h>
#endif
@@ -986,7 +987,7 @@ bool OpenGLContext::ImplInit()
VCL_GL_INFO("OpenGLContext::ImplInit----start");
NSOpenGLView* pView = getOpenGLView();
- OpenGLWrapper::makeCurrent(pView);
+ [[pView openGLContext] makeCurrentContext];
bool bRet = InitGLEW();
InitGLEWDebugging();
@@ -1252,7 +1253,7 @@ void OpenGLContext::reset()
m_aGLWin.hRC = 0;
}
#elif defined( MACOSX )
- OpenGLWrapper::resetCurrent();
+ [NSOpenGLContext clearCurrentContext];
#elif defined( IOS ) || defined( ANDROID ) || defined(LIBO_HEADLESS)
// nothing
#elif defined( UNX )
@@ -1408,7 +1409,7 @@ void OpenGLContext::makeCurrent()
}
#elif defined( MACOSX )
NSOpenGLView* pView = getOpenGLView();
- OpenGLWrapper::makeCurrent(pView);
+ [[pView openGLContext] makeCurrentContext];
#elif defined( IOS ) || defined( ANDROID ) || defined(LIBO_HEADLESS)
// nothing
#elif defined( UNX )
@@ -1462,7 +1463,7 @@ void OpenGLContext::resetCurrent()
wglMakeCurrent(NULL, NULL);
#elif defined( MACOSX )
(void) this; // loplugin:staticmethods
- OpenGLWrapper::resetCurrent();
+ [NSOpenGLContext clearCurrentContext];
#elif defined( IOS ) || defined( ANDROID ) || defined(LIBO_HEADLESS)
// nothing
#elif defined( UNX )
@@ -1479,7 +1480,7 @@ void OpenGLContext::swapBuffers()
SwapBuffers(m_aGLWin.hDC);
#elif defined( MACOSX )
NSOpenGLView* pView = getOpenGLView();
- OpenGLWrapper::swapBuffers(pView);
+ [[pView openGLContext] flushBuffer];
#elif defined( IOS ) || defined( ANDROID ) || defined(LIBO_HEADLESS)
// nothing
#elif defined( UNX )