From 5049953041cbc9592f0470eb185e1448b69835d6 Mon Sep 17 00:00:00 2001 From: David Robillard Date: Sat, 27 Jul 2019 00:59:16 +0200 Subject: Completely separate backends from platform implementation This removes PuglContextType and allows the user to pass a backend directly. Normally this would come from one of the two accessors declared in the headers, but it would be possible to add backends without changing any of the existing code at all. Unfortunately, it is not possible to preserve backwards compatibility and achieve the ultimate goal of linking only to the required dependencies, so puglInitContextType() has just been removed. --- pugl/pugl_osx.m | 7 ------- 1 file changed, 7 deletions(-) (limited to 'pugl/pugl_osx.m') diff --git a/pugl/pugl_osx.m b/pugl/pugl_osx.m index 30eb84d..6ddb24d 100644 --- a/pugl/pugl_osx.m +++ b/pugl/pugl_osx.m @@ -745,13 +745,6 @@ puglCreateWindow(PuglView* view, const char* title) [NSAutoreleasePool new]; impl->app = [NSApplication sharedApplication]; - view->backend = puglGlBackend(); - if (view->ctx_type == PUGL_CAIRO) { -#ifdef PUGL_HAVE_CAIRO - view->backend = puglCairoBackend(); -#endif - } - impl->glview = [PuglOpenGLView alloc]; impl->glview->trackingArea = nil; impl->glview->markedText = [[NSMutableAttributedString alloc] init]; -- cgit v1.2.1