From c0bf01a646f2d1b21ef28b0a898d74aa2c9fad91 Mon Sep 17 00:00:00 2001 From: JordanTheToaster Date: Sat, 8 Nov 2025 06:29:25 +0000 Subject: [PATCH] MacOS: Patch Tahoe unclickable buttons --- .../scripts/macos/build-dependencies.sh | 3 +++ .../workflows/scripts/macos/clickbutton.patch | 16 ++++++++++++++++ 2 files changed, 19 insertions(+) create mode 100644 .github/workflows/scripts/macos/clickbutton.patch diff --git a/.github/workflows/scripts/macos/build-dependencies.sh b/.github/workflows/scripts/macos/build-dependencies.sh index 84f4c14801..bd7678cf90 100755 --- a/.github/workflows/scripts/macos/build-dependencies.sh +++ b/.github/workflows/scripts/macos/build-dependencies.sh @@ -237,6 +237,9 @@ cd "qtbase-everywhere-src-$QT" # Patch Qt to support macOS 11 patch -p1 < "$SCRIPTDIR/qt-macos11compat.patch" +# Patch Qt to fix a bug with message boxes on Tahoe +patch -p1 < "$SCRIPTDIR/clickbutton.patch" + # since we don't have a direct reference to QtSvg, it doesn't deployed directly from the main binary # (only indirectly from iconengines), and the libqsvg.dylib imageformat plugin does not get deployed. # We could run macdeployqt twice, but that's even more janky than patching it. diff --git a/.github/workflows/scripts/macos/clickbutton.patch b/.github/workflows/scripts/macos/clickbutton.patch new file mode 100644 index 0000000000..441b341fb9 --- /dev/null +++ b/.github/workflows/scripts/macos/clickbutton.patch @@ -0,0 +1,16 @@ +--- a/src/plugins/platforms/cocoa/qcocoamessagedialog.mm ++++ b/src/plugins/platforms/cocoa/qcocoamessagedialog.mm +@@ -88,6 +88,11 @@ bool QCocoaMessageDialog::show(Qt::WindowModality windowModality) + qCWarning(lcQpaDialogs, "Cannot run window modal dialog without parent window"); + return false; + } ++ ++ // Tahoe has issues with window-modal alert buttons not responding to mouse ++ if (windowModality == Qt::WindowModal ++ && QOperatingSystemVersion::current() >= QOperatingSystemVersion::MacOSTahoe) ++ return false; + + // And without options we don't know what to show + if (!options()) + +# Source https://codereview.qt-project.org/c/qt/qtbase/+/689796 \ No newline at end of file