mirror of
				https://github.com/Drezil/imgui.git
				synced 2025-10-31 21:21:06 +01:00 
			
		
		
		
	Fix merge in Docking branch, remove ConfigDockingWithShift flag from DX11 example + misnamed function.
This commit is contained in:
		| @@ -139,7 +139,6 @@ int main(int, char**) | |||||||
|     //io.ConfigFlags |= ImGuiConfigFlags_ViewportsNoMerge; |     //io.ConfigFlags |= ImGuiConfigFlags_ViewportsNoMerge; | ||||||
|     io.ConfigFlags |= ImGuiConfigFlags_DpiEnableScaleFonts;     // FIXME-DPI: THIS CURRENTLY DOESN'T WORK AS EXPECTED. DON'T USE IN USER APP! |     io.ConfigFlags |= ImGuiConfigFlags_DpiEnableScaleFonts;     // FIXME-DPI: THIS CURRENTLY DOESN'T WORK AS EXPECTED. DON'T USE IN USER APP! | ||||||
|     io.ConfigFlags |= ImGuiConfigFlags_DpiEnableScaleViewports; // FIXME-DPI |     io.ConfigFlags |= ImGuiConfigFlags_DpiEnableScaleViewports; // FIXME-DPI | ||||||
|     io.ConfigDockingWithShift = true; |  | ||||||
|  |  | ||||||
|     // Setup Dear ImGui style |     // Setup Dear ImGui style | ||||||
|     ImGui::StyleColorsDark(); |     ImGui::StyleColorsDark(); | ||||||
|   | |||||||
| @@ -80,17 +80,14 @@ int main(int, char**) | |||||||
|     ImGui::CreateContext(); |     ImGui::CreateContext(); | ||||||
|     ImGuiIO& io = ImGui::GetIO(); (void)io; |     ImGuiIO& io = ImGui::GetIO(); (void)io; | ||||||
|     io.ConfigFlags |= ImGuiConfigFlags_NavEnableKeyboard;       // Enable Keyboard Controls |     io.ConfigFlags |= ImGuiConfigFlags_NavEnableKeyboard;       // Enable Keyboard Controls | ||||||
| <<<<<<< HEAD |  | ||||||
|     io.ConfigFlags |= ImGuiConfigFlags_DockingEnable;           // Enable Docking |     io.ConfigFlags |= ImGuiConfigFlags_DockingEnable;           // Enable Docking | ||||||
|     io.ConfigFlags |= ImGuiConfigFlags_ViewportsEnable;         // Enable Multi-Viewport / Platform Windows |     io.ConfigFlags |= ImGuiConfigFlags_ViewportsEnable;         // Enable Multi-Viewport / Platform Windows | ||||||
|     //io.ConfigFlags |= ImGuiConfigFlags_ViewportsNoTaskBarIcons; |     //io.ConfigFlags |= ImGuiConfigFlags_ViewportsNoTaskBarIcons; | ||||||
|     //io.ConfigFlags |= ImGuiConfigFlags_ViewportsNoMerge; |     //io.ConfigFlags |= ImGuiConfigFlags_ViewportsNoMerge; | ||||||
| ======= |  | ||||||
|  |  | ||||||
|     // Setup Dear ImGui style |     // Setup Dear ImGui style | ||||||
|     ImGui::StyleColorsDark(); |     ImGui::StyleColorsDark(); | ||||||
|     //ImGui::StyleColorsClassic(); |     //ImGui::StyleColorsClassic(); | ||||||
| >>>>>>> viewport |  | ||||||
|  |  | ||||||
|     // Setup Platform/Renderer bindings |     // Setup Platform/Renderer bindings | ||||||
|     ImGui_ImplWin32_Init(hwnd); |     ImGui_ImplWin32_Init(hwnd); | ||||||
|   | |||||||
| @@ -3734,11 +3734,11 @@ void ImGui::PopClipRect() | |||||||
|     window->ClipRect = window->DrawList->_ClipRectStack.back(); |     window->ClipRect = window->DrawList->_ClipRectStack.back(); | ||||||
| } | } | ||||||
|  |  | ||||||
| static ImGuiWindow* FindFromMostVisibleChildWindow(ImGuiWindow* window) | static ImGuiWindow* FindFrontMostVisibleChildWindow(ImGuiWindow* window) | ||||||
| { | { | ||||||
|     for (int n = window->DC.ChildWindows.Size - 1; n >= 0; n--) |     for (int n = window->DC.ChildWindows.Size - 1; n >= 0; n--) | ||||||
|         if (IsWindowActiveAndVisible(window->DC.ChildWindows[n])) |         if (IsWindowActiveAndVisible(window->DC.ChildWindows[n])) | ||||||
|             return FindFromMostVisibleChildWindow(window->DC.ChildWindows[n]); |             return FindFrontMostVisibleChildWindow(window->DC.ChildWindows[n]); | ||||||
|     return window; |     return window; | ||||||
| } | } | ||||||
|  |  | ||||||
| @@ -3792,7 +3792,7 @@ void ImGui::EndFrame() | |||||||
|     { |     { | ||||||
|         // Choose a draw list that will be front-most across all our children |         // Choose a draw list that will be front-most across all our children | ||||||
|         ImGuiWindow* window = g.NavWindowingTargetAnim; |         ImGuiWindow* window = g.NavWindowingTargetAnim; | ||||||
|         ImDrawList* draw_list = FindFromMostVisibleChildWindow(window->RootWindow)->DrawList; |         ImDrawList* draw_list = FindFrontMostVisibleChildWindow(window->RootWindow)->DrawList; | ||||||
|         draw_list->PushClipRectFullScreen(); |         draw_list->PushClipRectFullScreen(); | ||||||
|  |  | ||||||
|         // Docking: draw modal whitening background on other nodes of a same dock tree |         // Docking: draw modal whitening background on other nodes of a same dock tree | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user