Skip to content

Instantly share code, notes, and snippets.

@Noctem
Last active August 29, 2015 14:17
Show Gist options
  • Save Noctem/2c03f24daf6705964347 to your computer and use it in GitHub Desktop.
Save Noctem/2c03f24daf6705964347 to your computer and use it in GitHub Desktop.
Avidemux SDL patch
diff --git a/avidemux/common/ADM_render/GUI_sdlRenderHelper.m b/avidemux/common/ADM_render/GUI_sdlRenderHelper.m
index ca74692..9da4d97 100644
--- a/avidemux/common/ADM_render/GUI_sdlRenderHelper.m
+++ b/avidemux/common/ADM_render/GUI_sdlRenderHelper.m
@@ -3,7 +3,7 @@
static NSWindow* nsParentWindow = nil;
static NSWindow* nsWindow = nil;
-static NSQuickDrawView* nsView = nil;
+static NSView* nsView = nil;
static bool cocoaApplication = false;
static id oldDelegate = nil;
static int widgetX = 0, widgetY = 0;
@@ -79,7 +79,7 @@ void initSdlCocoaView(void* parent, int x, int y, int width, int height, bool ca
if (!nsView)
{
- nsView = [[NSQuickDrawView alloc] initWithFrame:contentRect];
+ nsView = [[NSView alloc] initWithFrame:contentRect];
[[nsWindow contentView] addSubview:nsView];
[nsView release];
@@ -108,7 +108,7 @@ void initSdlCocoaView(void* parent, int x, int y, int width, int height, bool ca
sprintf(SDL_windowhack,"SDL_NSWindowPointer=%ld",(int)nsWindow);
putenv(SDL_windowhack);
- sprintf(SDL_windowhack,"SDL_NSQuickDrawViewPointer=%ld",(int)nsView);
+ sprintf(SDL_windowhack,"SDL_NSViewPointer=%ld",(int)nsView);
putenv(SDL_windowhack);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment