diff --git a/Source/Core/DolphinWX/Src/Frame.h b/Source/Core/DolphinWX/Src/Frame.h index 7b01590e45..45a0eb1ad4 100644 --- a/Source/Core/DolphinWX/Src/Frame.h +++ b/Source/Core/DolphinWX/Src/Frame.h @@ -107,7 +107,7 @@ public: void* GetRenderHandle() { - #if defined(_WIN32) || defined(__APPLE__) + #ifdef _WIN32 return (void *)m_RenderParent->GetHandle(); #elif defined(HAVE_X11) && HAVE_X11 return (void *)X11Utils::XWindowFromHandle(m_RenderParent->GetHandle()); diff --git a/Source/Core/DolphinWX/Src/GLInterface/AGL.cpp b/Source/Core/DolphinWX/Src/GLInterface/AGL.cpp index c78a9f1448..c18800ad9b 100644 --- a/Source/Core/DolphinWX/Src/GLInterface/AGL.cpp +++ b/Source/Core/DolphinWX/Src/GLInterface/AGL.cpp @@ -20,6 +20,8 @@ #include "RenderBase.h" #include "ConfigManager.h" +#include + #include "VertexShaderManager.h" #include "../GLInterface.h" #include "AGL.h" @@ -72,7 +74,7 @@ bool cInterfaceAGL::Create(void *&window_handle) style |= NSResizableWindowMask | NSTitledWindowMask; } - GLWin.cocoaWin = (NSView*)window_handle; + GLWin.cocoaWin = (NSView*)(((wxPanel*)window_handle)->GetHandle());; if (GLWin.cocoaWin == nil) { ERROR_LOG(VIDEO, "failed to create window"); return NULL; @@ -95,6 +97,8 @@ bool cInterfaceAGL::MakeCurrent() width = [GLWin.cocoaWin frame].size.width; height = [GLWin.cocoaWin frame].size.height; + //if (width == s_backbuffer_width && height == s_backbuffer_height) + // return true; [GLWin.cocoaCtx setView: GLWin.cocoaWin]; [GLWin.cocoaCtx update];