From 9da40e98b3847156bd284b360d1866a12fa741e4 Mon Sep 17 00:00:00 2001 From: Charlie Fenton Date: Sat, 11 Feb 2012 08:44:48 +0000 Subject: [PATCH] MGR: On Mac, ensure any modal dialog remains in front when Manager is activated svn path=/trunk/boinc/; revision=25240 --- checkin_notes | 8 ++++++++ clientgui/BOINCGUIApp.cpp | 7 +++++++ 2 files changed, 15 insertions(+) diff --git a/checkin_notes b/checkin_notes index 4379704162..0cd9fb4d97 100644 --- a/checkin_notes +++ b/checkin_notes @@ -1600,3 +1600,11 @@ Charlie 10 Feb 2012 client/ coproc_detect.cpp + +Charlie 11 Feb 2012 + - MGR: Fix a bug which pushed modal dialogs (Attach Wizard) to rear when + Manager process was brought to front from behind (Mac only.) This + bug was probably introduced in Z-order tweak of 23 Jan 2012. + + clientgui/ + BOINCGUIApp.cpp diff --git a/clientgui/BOINCGUIApp.cpp b/clientgui/BOINCGUIApp.cpp index 1f8c739379..a22e32c334 100644 --- a/clientgui/BOINCGUIApp.cpp +++ b/clientgui/BOINCGUIApp.cpp @@ -794,6 +794,13 @@ void CBOINCGUIApp::OnActivateApp(wxActivateEvent& event) { m_pEventLog->Raise(); } m_pFrame->Raise(); + +#ifdef __WXMAC__ + // Make sure any modal dialog (such as Attach Wizard) ends up in front. + if (IsModalDialogDisplayed()) { + wxDynamicCast(wxWindow::FindWindowById(ID_ANYDIALOG), wxDialog)->Raise(); + } +#endif } event.Skip(); }