fix: revert the parent window remained interactive after the modal window was opened (#48977)

This commit is contained in:
BILL SHEN
2025-11-20 01:24:12 +08:00
committed by GitHub
parent 5b5b24775e
commit 8f9637fde4

View File

@@ -553,7 +553,7 @@ bool NativeWindowViews::IsFocused() const {
}
void NativeWindowViews::Show() {
if (is_modal() && NativeWindow::parent())
if (is_modal() && NativeWindow::parent() && !widget()->IsVisible())
static_cast<NativeWindowViews*>(parent())->IncrementChildModals();
widget()->native_widget_private()->Show(GetRestoredState(), gfx::Rect());