From b95b567b750e00e07cdfe911df522099062d3ec6 Mon Sep 17 00:00:00 2001 From: indigo Date: Sat, 4 Jul 2026 23:09:05 +0800 Subject: [PATCH] Require Shift to dock windows io.ConfigDockingWithShift: plain title-bar/tab drags just move a window; holding Shift shows the dock-position overlay and docks. Co-Authored-By: Claude Fable 5 --- src/ui/ImGuiContext.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/ui/ImGuiContext.cpp b/src/ui/ImGuiContext.cpp index 8836696..a5b8a06 100644 --- a/src/ui/ImGuiContext.cpp +++ b/src/ui/ImGuiContext.cpp @@ -94,6 +94,10 @@ bool ImGuiContext::Initialize(const std::string& windowTitle, int width, int hei // With NavEnableKeyboard set, io.WantCaptureKeyboard becomes true whenever any // ImGui window is focused, which would block all viewport hotkeys (F, A, etc.). io.ConfigFlags |= ImGuiConfigFlags_DockingEnable; + // Dock only while Shift is held during a title-bar/tab drag (the dock + // position overlay appears then); a plain drag just moves the window, + // so casual rearranging can't accidentally re-dock panels. + io.ConfigDockingWithShift = true; // Store imgui.ini in %APPDATA%\UsdLayerManager\ so it doesn't litter the CWD. if (const char* appData = getenv("APPDATA")) {