Enabled imgui viewports
This commit is contained in:
@@ -155,8 +155,20 @@ namespace Nuake
|
||||
|
||||
void Window::EndDraw()
|
||||
{
|
||||
ImGui::EndFrame();
|
||||
ImGui::Render();
|
||||
|
||||
ImGui_ImplOpenGL3_RenderDrawData(ImGui::GetDrawData());
|
||||
|
||||
if (ImGui::GetIO().ConfigFlags & ImGuiConfigFlags_ViewportsEnable)
|
||||
{
|
||||
GLFWwindow* backup_current_context = glfwGetCurrentContext();
|
||||
ImGui::UpdatePlatformWindows();
|
||||
ImGui::RenderPlatformWindowsDefault();
|
||||
glfwMakeContextCurrent(backup_current_context);
|
||||
}
|
||||
|
||||
|
||||
glfwSwapBuffers(m_Window);
|
||||
glfwPollEvents();
|
||||
}
|
||||
@@ -263,6 +275,7 @@ namespace Nuake
|
||||
io.Fonts->AddFontFromFileTTF("resources/Fonts/Poppins-Regular.ttf", 16.0);
|
||||
|
||||
io.ConfigFlags |= ImGuiConfigFlags_DockingEnable;
|
||||
io.ConfigFlags |= ImGuiConfigFlags_ViewportsEnable;
|
||||
ImGui::StyleColorsDark();
|
||||
|
||||
ImGuiStyle& s = ImGui::GetStyle();
|
||||
|
||||
Reference in New Issue
Block a user