From 29ec793147054ea4beb1ad4adeebbbe1fe07b260 Mon Sep 17 00:00:00 2001 From: Richard Moe Gustavsen Date: Mon, 8 Mar 2010 11:18:43 +0100 Subject: Carbon: usage of menu bars can cause exceptions to be thrown The reason is that a function in the Qt menu bar code assumes that windows on screen are NSWindows (which is true for the cocoa-port). But when using carbon, this will fail. This simple patch will fix this. Reviewed-by: msorvig --- src/gui/widgets/qmenu_mac.mm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gui/widgets/qmenu_mac.mm b/src/gui/widgets/qmenu_mac.mm index 2570cb5..43722a1 100644 --- a/src/gui/widgets/qmenu_mac.mm +++ b/src/gui/widgets/qmenu_mac.mm @@ -1935,7 +1935,7 @@ static bool qt_mac_should_disable_menu(QMenuBar *menuBar) if (w->isVisible() && w->windowModality() == Qt::ApplicationModal) { for (int i=0; iisVisible()) { // INVARIANT: we found another visible window // on screen other than our modalWidget. We therefore // disable the menu bar to follow normal modality logic: -- cgit v0.12