mirror of
https://github.com/Drezil/imgui.git
synced 2025-07-04 12:08:47 +02:00
Viewports: Renamed UpdatePlatformWindows > PlatformWindowsUpdate, RenderPlatformWindowsDefault -> PlatformWindowsRender, DestroyPlatformWindows > PlatformWindowsDestroy (#1542)
This commit is contained in:
@ -160,8 +160,8 @@ int main(int, char**)
|
||||
if (io.ConfigFlags & ImGuiConfigFlags_ViewportsEnable)
|
||||
{
|
||||
GLFWwindow* backup_current_context = glfwGetCurrentContext();
|
||||
ImGui::UpdatePlatformWindows();
|
||||
ImGui::RenderPlatformWindowsDefault();
|
||||
ImGui::PlatformWindowsUpdate();
|
||||
ImGui::PlatformWindowsRender();
|
||||
glfwMakeContextCurrent(backup_current_context);
|
||||
}
|
||||
|
||||
|
@ -205,8 +205,8 @@ int main(int, char**)
|
||||
if (io.ConfigFlags & ImGuiConfigFlags_ViewportsEnable)
|
||||
{
|
||||
GLFWwindow* backup_current_context = glfwGetCurrentContext();
|
||||
ImGui::UpdatePlatformWindows();
|
||||
ImGui::RenderPlatformWindowsDefault();
|
||||
ImGui::PlatformWindowsUpdate();
|
||||
ImGui::PlatformWindowsRender();
|
||||
glfwMakeContextCurrent(backup_current_context);
|
||||
}
|
||||
|
||||
|
@ -525,8 +525,8 @@ int main(int, char**)
|
||||
// Update and Render additional Platform Windows
|
||||
if (io.ConfigFlags & ImGuiConfigFlags_ViewportsEnable)
|
||||
{
|
||||
ImGui::UpdatePlatformWindows();
|
||||
ImGui::RenderPlatformWindowsDefault();
|
||||
ImGui::PlatformWindowsUpdate();
|
||||
ImGui::PlatformWindowsRender();
|
||||
}
|
||||
|
||||
FramePresent(wd);
|
||||
|
@ -166,8 +166,8 @@ int main(int, char**)
|
||||
// Update and Render additional Platform Windows
|
||||
if (io.ConfigFlags & ImGuiConfigFlags_ViewportsEnable)
|
||||
{
|
||||
ImGui::UpdatePlatformWindows();
|
||||
ImGui::RenderPlatformWindowsDefault();
|
||||
ImGui::PlatformWindowsUpdate();
|
||||
ImGui::PlatformWindowsRender();
|
||||
}
|
||||
|
||||
g_pSwapChain->Present(1, 0); // Present with vsync
|
||||
|
@ -158,8 +158,8 @@ int main(int, char**)
|
||||
{
|
||||
SDL_Window* backup_current_window = SDL_GL_GetCurrentWindow();
|
||||
SDL_GLContext backup_current_context = SDL_GL_GetCurrentContext();
|
||||
ImGui::UpdatePlatformWindows();
|
||||
ImGui::RenderPlatformWindowsDefault();
|
||||
ImGui::PlatformWindowsUpdate();
|
||||
ImGui::PlatformWindowsRender();
|
||||
SDL_GL_MakeCurrent(backup_current_window, backup_current_context);
|
||||
}
|
||||
|
||||
|
@ -207,8 +207,8 @@ int main(int, char**)
|
||||
{
|
||||
SDL_Window* backup_current_window = SDL_GL_GetCurrentWindow();
|
||||
SDL_GLContext backup_current_context = SDL_GL_GetCurrentContext();
|
||||
ImGui::UpdatePlatformWindows();
|
||||
ImGui::RenderPlatformWindowsDefault();
|
||||
ImGui::PlatformWindowsUpdate();
|
||||
ImGui::PlatformWindowsRender();
|
||||
SDL_GL_MakeCurrent(backup_current_window, backup_current_context);
|
||||
}
|
||||
|
||||
|
@ -522,8 +522,8 @@ int main(int, char**)
|
||||
// Update and Render additional Platform Windows
|
||||
if (io.ConfigFlags & ImGuiConfigFlags_ViewportsEnable)
|
||||
{
|
||||
ImGui::UpdatePlatformWindows();
|
||||
ImGui::RenderPlatformWindowsDefault();
|
||||
ImGui::PlatformWindowsUpdate();
|
||||
ImGui::PlatformWindowsRender();
|
||||
}
|
||||
|
||||
FramePresent(wd);
|
||||
|
@ -159,8 +159,8 @@ int main(int, char**)
|
||||
// Update and Render additional Platform Windows
|
||||
if (io.ConfigFlags & ImGuiConfigFlags_ViewportsEnable)
|
||||
{
|
||||
ImGui::UpdatePlatformWindows();
|
||||
ImGui::RenderPlatformWindowsDefault();
|
||||
ImGui::PlatformWindowsUpdate();
|
||||
ImGui::PlatformWindowsRender();
|
||||
}
|
||||
|
||||
g_pSwapChain->Present(1, 0); // Present with vsync
|
||||
|
@ -166,8 +166,8 @@ int main(int, char**)
|
||||
// Update and Render additional Platform Windows
|
||||
if (io.ConfigFlags & ImGuiConfigFlags_ViewportsEnable)
|
||||
{
|
||||
ImGui::UpdatePlatformWindows();
|
||||
ImGui::RenderPlatformWindowsDefault();
|
||||
ImGui::PlatformWindowsUpdate();
|
||||
ImGui::PlatformWindowsRender();
|
||||
}
|
||||
|
||||
g_pSwapChain->Present(1, 0); // Present with vsync
|
||||
|
@ -210,8 +210,8 @@ int main(int, char**)
|
||||
// Update and Render additional Platform Windows
|
||||
if (io.ConfigFlags & ImGuiConfigFlags_ViewportsEnable)
|
||||
{
|
||||
ImGui::UpdatePlatformWindows();
|
||||
ImGui::RenderPlatformWindowsDefault(NULL, (void*)g_pd3dCommandList);
|
||||
ImGui::PlatformWindowsUpdate();
|
||||
ImGui::PlatformWindowsRender(NULL, (void*)g_pd3dCommandList);
|
||||
}
|
||||
|
||||
g_pSwapChain->Present(1, 0); // Present with vsync
|
||||
|
@ -165,8 +165,8 @@ int main(int, char**)
|
||||
// Update and Render additional Platform Windows
|
||||
if (io.ConfigFlags & ImGuiConfigFlags_ViewportsEnable)
|
||||
{
|
||||
ImGui::UpdatePlatformWindows();
|
||||
ImGui::RenderPlatformWindowsDefault();
|
||||
ImGui::PlatformWindowsUpdate();
|
||||
ImGui::PlatformWindowsRender();
|
||||
}
|
||||
|
||||
HRESULT result = g_pd3dDevice->Present(NULL, NULL, NULL, NULL);
|
||||
|
@ -655,6 +655,6 @@ void ImGui_ImplDX10_InitPlatformInterface()
|
||||
|
||||
void ImGui_ImplDX10_ShutdownPlatformInterface()
|
||||
{
|
||||
ImGui::DestroyPlatformWindows();
|
||||
ImGui::PlatformWindowsDestroy();
|
||||
}
|
||||
|
||||
|
@ -671,5 +671,5 @@ static void ImGui_ImplDX11_InitPlatformInterface()
|
||||
|
||||
static void ImGui_ImplDX11_ShutdownPlatformInterface()
|
||||
{
|
||||
ImGui::DestroyPlatformWindows();
|
||||
ImGui::PlatformWindowsDestroy();
|
||||
}
|
||||
|
@ -947,5 +947,5 @@ void ImGui_ImplDX12_InitPlatformInterface()
|
||||
|
||||
void ImGui_ImplDX12_ShutdownPlatformInterface()
|
||||
{
|
||||
ImGui::DestroyPlatformWindows();
|
||||
ImGui::PlatformWindowsDestroy();
|
||||
}
|
||||
|
@ -423,7 +423,7 @@ static void ImGui_ImplDX9_InitPlatformInterface()
|
||||
|
||||
static void ImGui_ImplDX9_ShutdownPlatformInterface()
|
||||
{
|
||||
ImGui::DestroyPlatformWindows();
|
||||
ImGui::PlatformWindowsDestroy();
|
||||
}
|
||||
|
||||
static void ImGui_ImplDX9_CreateDeviceObjectsForPlatformWindows()
|
||||
|
@ -598,7 +598,7 @@ static LRESULT CALLBACK WndProcNoInputs(HWND hWnd, UINT msg, WPARAM wParam, LPAR
|
||||
// Let mouse pass-through the window. This will allow the back-end to set io.MouseHoveredViewport properly (which is OPTIONAL).
|
||||
// The ImGuiViewportFlags_NoInputs flag is set while dragging a viewport, as want to detect the window behind the one we are dragging.
|
||||
// If you cannot easily access those viewport flags from your windowing/event code: you may manually synchronize its state e.g. in
|
||||
// your main loop after calling UpdatePlatformWindows(). Iterate all viewports/platform windows and pass the flag to your windowing system.
|
||||
// your main loop after calling PlatformWindowsUpdate(). Iterate all viewports/platform windows and pass the flag to your windowing system.
|
||||
ImGuiViewport* viewport = (ImGuiViewport*)::GetPropA(hWnd, "IMGUI_VIEWPORT");
|
||||
if (viewport->Flags & ImGuiViewportFlags_NoInputs)
|
||||
return HTTRANSPARENT;
|
||||
|
@ -283,5 +283,5 @@ static void ImGui_ImplOpenGL2_InitPlatformInterface()
|
||||
|
||||
static void ImGui_ImplOpenGL2_ShutdownPlatformInterface()
|
||||
{
|
||||
ImGui::DestroyPlatformWindows();
|
||||
ImGui::PlatformWindowsDestroy();
|
||||
}
|
||||
|
@ -712,5 +712,5 @@ static void ImGui_ImplOpenGL3_InitPlatformInterface()
|
||||
|
||||
static void ImGui_ImplOpenGL3_ShutdownPlatformInterface()
|
||||
{
|
||||
ImGui::DestroyPlatformWindows();
|
||||
ImGui::PlatformWindowsDestroy();
|
||||
}
|
||||
|
@ -1445,5 +1445,5 @@ void ImGui_ImplVulkan_InitPlatformInterface()
|
||||
|
||||
void ImGui_ImplVulkan_ShutdownPlatformInterface()
|
||||
{
|
||||
ImGui::DestroyPlatformWindows();
|
||||
ImGui::PlatformWindowsDestroy();
|
||||
}
|
||||
|
@ -798,7 +798,7 @@ static LRESULT CALLBACK ImGui_ImplWin32_WndProcHandler_PlatformWindow(HWND hWnd,
|
||||
// Let mouse pass-through the window. This will allow the back-end to set io.MouseHoveredViewport properly (which is OPTIONAL).
|
||||
// The ImGuiViewportFlags_NoInputs flag is set while dragging a viewport, as want to detect the window behind the one we are dragging.
|
||||
// If you cannot easily access those viewport flags from your windowing/event code: you may manually synchronize its state e.g. in
|
||||
// your main loop after calling UpdatePlatformWindows(). Iterate all viewports/platform windows and pass the flag to your windowing system.
|
||||
// your main loop after calling PlatformWindowsUpdate(). Iterate all viewports/platform windows and pass the flag to your windowing system.
|
||||
if (viewport->Flags & ImGuiViewportFlags_NoInputs)
|
||||
return HTTRANSPARENT;
|
||||
break;
|
||||
|
Reference in New Issue
Block a user