mirror of
https://github.com/Drezil/imgui.git
synced 2024-11-15 01:17:00 +00:00
Examples: GLFW: Made it possible to Shutdown/Init the backend again (by reseting the time storage properly). Changelog. Added to Vulkan example. (#1827)
This commit is contained in:
parent
e8a72d3e72
commit
663e2c9237
@ -46,6 +46,7 @@ Other Changes:
|
|||||||
- Nav: To keep the navigated item in view we also attempt to scroll the parent window as well as the current window. (#787)
|
- Nav: To keep the navigated item in view we also attempt to scroll the parent window as well as the current window. (#787)
|
||||||
- TreeNode: Fixed nodes with ImGuiTreeNodeFlags_Leaf flag always returning true which was meaningless.
|
- TreeNode: Fixed nodes with ImGuiTreeNodeFlags_Leaf flag always returning true which was meaningless.
|
||||||
- ColorEdit3, ColorEdit4, ColorButton: Added ImGuiColorEditFlags_NoDragDrop flag to disable ColorEditX as drag target and ColorButton as drag source. (#1826)
|
- ColorEdit3, ColorEdit4, ColorButton: Added ImGuiColorEditFlags_NoDragDrop flag to disable ColorEditX as drag target and ColorButton as drag source. (#1826)
|
||||||
|
- Examples: GLFW: Made it possible to Shutdown/Init the backend again (by reseting the time storage properly). (#1827) [@ice1000]
|
||||||
|
|
||||||
-----------------------------------------------------------------------
|
-----------------------------------------------------------------------
|
||||||
|
|
||||||
|
@ -49,7 +49,7 @@
|
|||||||
|
|
||||||
// GLFW data
|
// GLFW data
|
||||||
static GLFWwindow* g_Window = NULL;
|
static GLFWwindow* g_Window = NULL;
|
||||||
static double g_Time = 0.0f;
|
static double g_Time = 0.0;
|
||||||
static bool g_MouseJustPressed[3] = { false, false, false };
|
static bool g_MouseJustPressed[3] = { false, false, false };
|
||||||
static GLFWcursor* g_MouseCursors[ImGuiMouseCursor_COUNT] = { 0 };
|
static GLFWcursor* g_MouseCursors[ImGuiMouseCursor_COUNT] = { 0 };
|
||||||
|
|
||||||
@ -233,7 +233,7 @@ static void ImGui_ImplGlfw_InstallCallbacks(GLFWwindow* window)
|
|||||||
bool ImGui_ImplGlfwGL2_Init(GLFWwindow* window, bool install_callbacks)
|
bool ImGui_ImplGlfwGL2_Init(GLFWwindow* window, bool install_callbacks)
|
||||||
{
|
{
|
||||||
g_Window = window;
|
g_Window = window;
|
||||||
g_Time = 0;
|
g_Time = 0.0;
|
||||||
|
|
||||||
// Setup back-end capabilities flags
|
// Setup back-end capabilities flags
|
||||||
ImGuiIO& io = ImGui::GetIO();
|
ImGuiIO& io = ImGui::GetIO();
|
||||||
|
@ -52,7 +52,7 @@
|
|||||||
|
|
||||||
// GLFW data
|
// GLFW data
|
||||||
static GLFWwindow* g_Window = NULL;
|
static GLFWwindow* g_Window = NULL;
|
||||||
static double g_Time = 0.0f;
|
static double g_Time = 0.0;
|
||||||
static bool g_MouseJustPressed[3] = { false, false, false };
|
static bool g_MouseJustPressed[3] = { false, false, false };
|
||||||
static GLFWcursor* g_MouseCursors[ImGuiMouseCursor_COUNT] = { 0 };
|
static GLFWcursor* g_MouseCursors[ImGuiMouseCursor_COUNT] = { 0 };
|
||||||
|
|
||||||
@ -358,7 +358,7 @@ static void ImGui_ImplGlfw_InstallCallbacks(GLFWwindow* window)
|
|||||||
bool ImGui_ImplGlfwGL3_Init(GLFWwindow* window, bool install_callbacks, const char* glsl_version)
|
bool ImGui_ImplGlfwGL3_Init(GLFWwindow* window, bool install_callbacks, const char* glsl_version)
|
||||||
{
|
{
|
||||||
g_Window = window;
|
g_Window = window;
|
||||||
g_Time = 0;
|
g_Time = 0.0;
|
||||||
|
|
||||||
// Store GL version string so we can refer to it later in case we recreate shaders.
|
// Store GL version string so we can refer to it later in case we recreate shaders.
|
||||||
if (glsl_version == NULL)
|
if (glsl_version == NULL)
|
||||||
|
@ -41,7 +41,7 @@
|
|||||||
|
|
||||||
// GLFW data
|
// GLFW data
|
||||||
static GLFWwindow* g_Window = NULL;
|
static GLFWwindow* g_Window = NULL;
|
||||||
static double g_Time = 0.0f;
|
static double g_Time = 0.0;
|
||||||
static bool g_MouseJustPressed[3] = { false, false, false };
|
static bool g_MouseJustPressed[3] = { false, false, false };
|
||||||
static GLFWcursor* g_MouseCursors[ImGuiMouseCursor_COUNT] = { 0 };
|
static GLFWcursor* g_MouseCursors[ImGuiMouseCursor_COUNT] = { 0 };
|
||||||
|
|
||||||
@ -769,6 +769,7 @@ bool ImGui_ImplGlfwVulkan_Init(GLFWwindow* window, bool install_callbacks, Im
|
|||||||
g_CheckVkResult = init_data->check_vk_result;
|
g_CheckVkResult = init_data->check_vk_result;
|
||||||
|
|
||||||
g_Window = window;
|
g_Window = window;
|
||||||
|
g_Time = 0.0;
|
||||||
|
|
||||||
// Setup back-end capabilities flags
|
// Setup back-end capabilities flags
|
||||||
ImGuiIO& io = ImGui::GetIO();
|
ImGuiIO& io = ImGui::GetIO();
|
||||||
|
Loading…
Reference in New Issue
Block a user