Provide dummy endpoints for Cocoa/Win32

This commit is contained in:
jgcodes2020 2023-10-24 18:17:06 -04:00
parent 6c38a99923
commit 36a3c1ef32
6 changed files with 18 additions and 6 deletions

View File

@ -525,6 +525,7 @@ GLFWbool _glfwConnectCocoa(int platformID, _GLFWplatform* platform)
_glfwGetGammaRampCocoa, _glfwGetGammaRampCocoa,
_glfwSetGammaRampCocoa, _glfwSetGammaRampCocoa,
_glfwCreateWindowCocoa, _glfwCreateWindowCocoa,
_glfwAttachWindowCocoa,
_glfwDestroyWindowCocoa, _glfwDestroyWindowCocoa,
_glfwSetWindowTitleCocoa, _glfwSetWindowTitleCocoa,
_glfwSetWindowIconCocoa, _glfwSetWindowIconCocoa,
@ -694,4 +695,3 @@ void _glfwTerminateCocoa(void)
} }
#endif // _GLFW_COCOA #endif // _GLFW_COCOA

View File

@ -215,6 +215,7 @@ int _glfwInitCocoa(void);
void _glfwTerminateCocoa(void); void _glfwTerminateCocoa(void);
GLFWbool _glfwCreateWindowCocoa(_GLFWwindow* window, const _GLFWwndconfig* wndconfig, const _GLFWctxconfig* ctxconfig, const _GLFWfbconfig* fbconfig); GLFWbool _glfwCreateWindowCocoa(_GLFWwindow* window, const _GLFWwndconfig* wndconfig, const _GLFWctxconfig* ctxconfig, const _GLFWfbconfig* fbconfig);
GLFWbool _glfwAttachWindowCocoa(_GLFWwindow* window, intptr_t native, const _GLFWwndconfig* wndconfig, const _GLFWctxconfig* ctxconfig, const _GLFWfbconfig* fbconfig);
void _glfwDestroyWindowCocoa(_GLFWwindow* window); void _glfwDestroyWindowCocoa(_GLFWwindow* window);
void _glfwSetWindowTitleCocoa(_GLFWwindow* window, const char* title); void _glfwSetWindowTitleCocoa(_GLFWwindow* window, const char* title);
void _glfwSetWindowIconCocoa(_GLFWwindow* window, int count, const GLFWimage* images); void _glfwSetWindowIconCocoa(_GLFWwindow* window, int count, const GLFWimage* images);
@ -299,4 +300,3 @@ GLFWbool _glfwCreateContextNSGL(_GLFWwindow* window,
const _GLFWctxconfig* ctxconfig, const _GLFWctxconfig* ctxconfig,
const _GLFWfbconfig* fbconfig); const _GLFWfbconfig* fbconfig);
void _glfwDestroyContextNSGL(_GLFWwindow* window); void _glfwDestroyContextNSGL(_GLFWwindow* window);

View File

@ -983,6 +983,15 @@ GLFWbool _glfwCreateWindowCocoa(_GLFWwindow* window,
} // autoreleasepool } // autoreleasepool
} }
GLFWbool _glfwAttachWindowCocoa(_GLFWwindow* window,
intptr_t native,
const _GLFWwndconfig* wndconfig,
const _GLFWctxconfig* ctxconfig,
const _GLFWfbconfig* fbconfig) {
_glfwInputError(GLFW_PLATFORM_ERROR, "Cocoa window attachment is not implemented");
return GLFW_FALSE;
}
void _glfwDestroyWindowCocoa(_GLFWwindow* window) void _glfwDestroyWindowCocoa(_GLFWwindow* window)
{ {
@autoreleasepool { @autoreleasepool {
@ -2050,4 +2059,3 @@ GLFWAPI id glfwGetCocoaWindow(GLFWwindow* handle)
} }
#endif // _GLFW_COCOA #endif // _GLFW_COCOA

View File

@ -635,6 +635,7 @@ GLFWbool _glfwConnectWin32(int platformID, _GLFWplatform* platform)
_glfwGetGammaRampWin32, _glfwGetGammaRampWin32,
_glfwSetGammaRampWin32, _glfwSetGammaRampWin32,
_glfwCreateWindowWin32, _glfwCreateWindowWin32,
_glfwAttachWindowWin32,
_glfwDestroyWindowWin32, _glfwDestroyWindowWin32,
_glfwSetWindowTitleWin32, _glfwSetWindowTitleWin32,
_glfwSetWindowIconWin32, _glfwSetWindowIconWin32,
@ -728,4 +729,3 @@ void _glfwTerminateWin32(void)
} }
#endif // _GLFW_WIN32 #endif // _GLFW_WIN32

View File

@ -540,6 +540,7 @@ void _glfwRestoreVideoModeWin32(_GLFWmonitor* monitor);
void _glfwGetHMONITORContentScaleWin32(HMONITOR handle, float* xscale, float* yscale); void _glfwGetHMONITORContentScaleWin32(HMONITOR handle, float* xscale, float* yscale);
GLFWbool _glfwCreateWindowWin32(_GLFWwindow* window, const _GLFWwndconfig* wndconfig, const _GLFWctxconfig* ctxconfig, const _GLFWfbconfig* fbconfig); GLFWbool _glfwCreateWindowWin32(_GLFWwindow* window, const _GLFWwndconfig* wndconfig, const _GLFWctxconfig* ctxconfig, const _GLFWfbconfig* fbconfig);
GLFWbool _glfwAttachWindowWin32(_GLFWwindow* window, intptr_t native, const _GLFWwndconfig* wndconfig, const _GLFWctxconfig* ctxconfig, const _GLFWfbconfig* fbconfig);
void _glfwDestroyWindowWin32(_GLFWwindow* window); void _glfwDestroyWindowWin32(_GLFWwindow* window);
void _glfwSetWindowTitleWin32(_GLFWwindow* window, const char* title); void _glfwSetWindowTitleWin32(_GLFWwindow* window, const char* title);
void _glfwSetWindowIconWin32(_GLFWwindow* window, int count, const GLFWimage* images); void _glfwSetWindowIconWin32(_GLFWwindow* window, int count, const GLFWimage* images);
@ -621,4 +622,3 @@ void _glfwTerminateWGL(void);
GLFWbool _glfwCreateContextWGL(_GLFWwindow* window, GLFWbool _glfwCreateContextWGL(_GLFWwindow* window,
const _GLFWctxconfig* ctxconfig, const _GLFWctxconfig* ctxconfig,
const _GLFWfbconfig* fbconfig); const _GLFWfbconfig* fbconfig);

View File

@ -1501,6 +1501,11 @@ GLFWbool _glfwCreateWindowWin32(_GLFWwindow* window,
return GLFW_TRUE; return GLFW_TRUE;
} }
GLFWbool _glfwAttachWindowWin32(_GLFWwindow* window, intptr_t native, const _GLFWwndconfig* wndconfig, const _GLFWctxconfig* ctxconfig, const _GLFWfbconfig* fbconfig) {
_glfwInputError(GLFW_PLATFORM_ERROR, "Win32 window attachment is not implemented");
return GLFW_FALSE;
}
void _glfwDestroyWindowWin32(_GLFWwindow* window) void _glfwDestroyWindowWin32(_GLFWwindow* window)
{ {
if (window->monitor) if (window->monitor)
@ -2501,4 +2506,3 @@ GLFWAPI HWND glfwGetWin32Window(GLFWwindow* handle)
} }
#endif // _GLFW_WIN32 #endif // _GLFW_WIN32