mirror of https://github.com/BOINC/boinc.git
MGR: Fix a Mac-only bug which showed Event Log if About BOINC is selected from task bar menu when BOINC is hidden
svn path=/trunk/boinc/; revision=25281
This commit is contained in:
parent
be8e6ca82c
commit
d8bff2cb64
|
@ -1814,3 +1814,11 @@ Charlie 17 Feb 2012
|
|||
|
||||
client/
|
||||
coproc_detect.cpp
|
||||
|
||||
Charlie 18 Feb 2012
|
||||
- MGR: Fix a Mac-only bug which showed Event Log if About BOINC is selected
|
||||
from task bar menu when BOINC is hidden.
|
||||
|
||||
clientgui/
|
||||
BOINCGUIApp.cpp
|
||||
BOINCTaskBar.cpp
|
||||
|
|
|
@ -789,18 +789,19 @@ int CBOINCGUIApp::IdleTrackerDetach() {
|
|||
|
||||
|
||||
void CBOINCGUIApp::OnActivateApp(wxActivateEvent& event) {
|
||||
#ifdef __WXMAC__
|
||||
// Make sure any modal dialog (such as Attach Wizard) ends up in front.
|
||||
if (IsModalDialogDisplayed()) {
|
||||
event.Skip();
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
|
||||
if (event.GetActive()) {
|
||||
if (m_pEventLog && !m_pEventLog->IsIconized()) {
|
||||
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();
|
||||
}
|
||||
|
|
|
@ -248,9 +248,17 @@ void CTaskBarIcon::OnSuspendResumeGPU(wxCommandEvent& WXUNUSED(event)) {
|
|||
}
|
||||
|
||||
void CTaskBarIcon::OnAbout(wxCommandEvent& WXUNUSED(event)) {
|
||||
bool bWasVisible;
|
||||
bool bWasVisible = wxGetApp().IsApplicationVisible();
|
||||
#ifdef __WXMAC__
|
||||
bool bEventLogWasShown = false;
|
||||
|
||||
CDlgEventLog* eventLog = wxGetApp().GetEventLog();
|
||||
if (eventLog) {
|
||||
bEventLogWasShown = eventLog->IsShown();
|
||||
if (bEventLogWasShown && !bWasVisible) eventLog->Show(false);
|
||||
}
|
||||
#endif
|
||||
|
||||
bWasVisible = wxGetApp().IsApplicationVisible();
|
||||
wxGetApp().ShowApplication(true);
|
||||
|
||||
ResetTaskBar();
|
||||
|
@ -261,6 +269,10 @@ void CTaskBarIcon::OnAbout(wxCommandEvent& WXUNUSED(event)) {
|
|||
if (!bWasVisible) {
|
||||
wxGetApp().ShowApplication(false);
|
||||
}
|
||||
|
||||
#ifdef __WXMAC__
|
||||
if (bEventLogWasShown) eventLog->Show(true);
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue