From 567184dc9fd6376511449577105859eb8303fea7 Mon Sep 17 00:00:00 2001 From: ocornut Date: Mon, 9 Mar 2015 13:38:23 +0000 Subject: [PATCH] Examples: Clang warning fix. --- examples/opengl3_example/imgui_impl_glfw_gl3.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/examples/opengl3_example/imgui_impl_glfw_gl3.cpp b/examples/opengl3_example/imgui_impl_glfw_gl3.cpp index cbe9f60c4..92def5ed6 100644 --- a/examples/opengl3_example/imgui_impl_glfw_gl3.cpp +++ b/examples/opengl3_example/imgui_impl_glfw_gl3.cpp @@ -233,9 +233,8 @@ static void InitGL() bool ImGui_ImplGlfwGL3_Init(GLFWwindow* window, bool install_callbacks) { - InitGL(); - g_Window = window; + InitGL(); ImGuiIO& io = ImGui::GetIO(); io.KeyMap[ImGuiKey_Tab] = GLFW_KEY_TAB; // Keyboard mapping. ImGui will use those indices to peek into the io.KeyDown[] array. @@ -292,7 +291,7 @@ void ImGui_ImplGlfwGL3_Shutdown() glDeleteProgram(g_ShaderHandle); g_ShaderHandle = 0; - if (GLuint tex_id = (GLuint)ImGui::GetIO().Fonts->TexID) + if (GLuint tex_id = (GLuint)(intptr_t)ImGui::GetIO().Fonts->TexID) { glDeleteTextures(1, &tex_id); ImGui::GetIO().Fonts->TexID = 0;