mirror of
https://github.com/Drezil/imgui.git
synced 2024-12-23 16:16:36 +00:00
Examples: Renamed glfw error callback for clarity.
This commit is contained in:
parent
b2453d7e8f
commit
1c18d65313
@ -11,7 +11,7 @@
|
||||
#include <stdio.h>
|
||||
#include <GLFW/glfw3.h>
|
||||
|
||||
static void error_callback(int error, const char* description)
|
||||
static void glfw_error_callback(int error, const char* description)
|
||||
{
|
||||
fprintf(stderr, "Error %d: %s\n", error, description);
|
||||
}
|
||||
@ -19,7 +19,7 @@ static void error_callback(int error, const char* description)
|
||||
int main(int, char**)
|
||||
{
|
||||
// Setup window
|
||||
glfwSetErrorCallback(error_callback);
|
||||
glfwSetErrorCallback(glfw_error_callback);
|
||||
if (!glfwInit())
|
||||
return 1;
|
||||
GLFWwindow* window = glfwCreateWindow(1280, 720, "ImGui OpenGL2 example", NULL, NULL);
|
||||
|
@ -9,7 +9,7 @@
|
||||
#include <GL/gl3w.h> // This example is using gl3w to access OpenGL functions (because it is small). You may use glew/glad/glLoadGen/etc. whatever already works for you.
|
||||
#include <GLFW/glfw3.h>
|
||||
|
||||
static void error_callback(int error, const char* description)
|
||||
static void glfw_error_callback(int error, const char* description)
|
||||
{
|
||||
fprintf(stderr, "Error %d: %s\n", error, description);
|
||||
}
|
||||
@ -17,7 +17,7 @@ static void error_callback(int error, const char* description)
|
||||
int main(int, char**)
|
||||
{
|
||||
// Setup window
|
||||
glfwSetErrorCallback(error_callback);
|
||||
glfwSetErrorCallback(glfw_error_callback);
|
||||
if (!glfwInit())
|
||||
return 1;
|
||||
glfwWindowHint(GLFW_CONTEXT_VERSION_MAJOR, 3);
|
||||
|
@ -583,7 +583,7 @@ static void frame_present()
|
||||
g_FrameIndex = (g_FrameIndex + 1) % IMGUI_VK_QUEUED_FRAMES;
|
||||
}
|
||||
|
||||
static void error_callback(int error, const char* description)
|
||||
static void glfw_error_callback(int error, const char* description)
|
||||
{
|
||||
fprintf(stderr, "Error %d: %s\n", error, description);
|
||||
}
|
||||
@ -591,7 +591,7 @@ static void error_callback(int error, const char* description)
|
||||
int main(int, char**)
|
||||
{
|
||||
// Setup window
|
||||
glfwSetErrorCallback(error_callback);
|
||||
glfwSetErrorCallback(glfw_error_callback);
|
||||
if (!glfwInit())
|
||||
return 1;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user