Merge branch 'glfw_upstream' of https://github.com/Luflosi/kitty
This commit is contained in:
commit
6eb0c10339
2
glfw/cocoa_platform.h
vendored
2
glfw/cocoa_platform.h
vendored
@ -104,7 +104,7 @@ typedef VkResult (APIENTRY *PFN_vkCreateMetalSurfaceEXT)(VkInstance,const VkMeta
|
||||
#define _glfw_dlclose(handle) dlclose(handle)
|
||||
#define _glfw_dlsym(handle, name) dlsym(handle, name)
|
||||
|
||||
#define _GLFW_EGL_NATIVE_WINDOW ((EGLNativeWindowType) window->ns.view)
|
||||
#define _GLFW_EGL_NATIVE_WINDOW ((EGLNativeWindowType) window->ns.layer)
|
||||
#define _GLFW_EGL_NATIVE_DISPLAY EGL_DEFAULT_DISPLAY
|
||||
|
||||
#define _GLFW_PLATFORM_WINDOW_STATE _GLFWwindowNS ns
|
||||
|
||||
@ -1460,6 +1460,11 @@ int _glfwPlatformCreateWindow(_GLFWwindow* window,
|
||||
}
|
||||
else if (ctxconfig->source == GLFW_EGL_CONTEXT_API)
|
||||
{
|
||||
// EGL implementation on macOS use CALayer* EGLNativeWindowType so we
|
||||
// need to get the layer for EGL window surface creation.
|
||||
[window->ns.view setWantsLayer:YES];
|
||||
window->ns.layer = [window->ns.view layer];
|
||||
|
||||
if (!_glfwInitEGL())
|
||||
return false;
|
||||
if (!_glfwCreateContextEGL(window, ctxconfig, fbconfig))
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user