diff --git a/src/ui/material/draw_helpers.h b/src/ui/material/draw_helpers.h index eb27652..3524548 100644 --- a/src/ui/material/draw_helpers.h +++ b/src/ui/material/draw_helpers.h @@ -1476,9 +1476,13 @@ inline bool BeginOverlayDialog(const OverlayDialogSpec& spec) ImGui::PushStyleVar(ImGuiStyleVar_WindowPadding, floating ? ImVec2(28, 20) : ImVec2(28, 24)); ImGui::PushStyleColor(ImGuiCol_ChildBg, ImVec4(0, 0, 0, 0)); // transparent (glass/blur behind) ImGuiChildFlags cflags = ImGuiChildFlags_AlwaysUseWindowPadding | (fixedHeight ? 0 : ImGuiChildFlags_AutoResizeY); + // NoScrollWithMouse (not just NoScrollbar): a modal is a fixed frame — the wheel must never drift + // the WHOLE card. If content marginally overflows a fixed card, the wheel would otherwise scroll + // the entire dialog (title + footer and all). Inner scroll regions (lists, notes) still scroll on + // their own; auto-height cards resize to content so they never overflow anyway. bool childVisible = ImGui::BeginChild(childId.c_str(), ImVec2(cardWidth, fixedHeight ? (cardBottomY - cardY) : 0.0f), - cflags, ImGuiWindowFlags_NoScrollbar); + cflags, ImGuiWindowFlags_NoScrollbar | ImGuiWindowFlags_NoScrollWithMouse); // Floating (portfolio-style) cards: the padding applies to this content child only, so pop it // now (nested children mustn't inherit it), and center button labels. Net style-var count stays // at 2 (ChildRounding + ButtonTextAlign) so EndOverlayDialog's PopStyleVar(2) is unchanged. diff --git a/src/ui/windows/daemon_download_dialog.h b/src/ui/windows/daemon_download_dialog.h index 5c8cdbc..0c3d3d4 100644 --- a/src/ui/windows/daemon_download_dialog.h +++ b/src/ui/windows/daemon_download_dialog.h @@ -226,7 +226,12 @@ private: ImFont* capF = Type().caption(); const bool showFooter = (p.state == St::ReleaseList); - const float footerH = showFooter ? (ImGui::GetFrameHeight() + Layout::spacingSm() * 2.0f + 1.0f) : 0.0f; + // Budget the whole footer block — the Spacing + Separator + Spacing + button row and every + // inter-item gap — so the two-pane body leaves exact room and nothing overflows the card. + const float footerH = showFooter + ? (ImGui::GetFrameHeightWithSpacing() + ImGui::GetStyle().ItemSpacing.y * 3.0f + + Layout::spacingSm() * 2.0f + 1.0f) + : 0.0f; const float bodyH = std::max(120.0f * dp, ImGui::GetContentRegionAvail().y - footerH); const float contentW = ImGui::GetContentRegionAvail().x; const float gap = Layout::spacingLg();