Ticket #3620: Tracker.cpp.diff

File Tracker.cpp.diff, 920 bytes (added by jonas.kirilla, 15 years ago)

Tracker.cpp.diff

  • src/kits/tracker/Tracker.cpp

     
    241241TTracker::QuitRequested()
    242242{
    243243    // don't allow user quitting
    244     if (CurrentMessage() && CurrentMessage()->FindBool("shortcut"))
     244    if (CurrentMessage() && CurrentMessage()->FindBool("shortcut")) {
     245        // but allow quitting to hide fSettingsWindow
     246        int32 index = 0;
     247        BWindow *window = NULL;
     248        while ((window = WindowAt(index++)) != NULL) {
     249            if (window == fSettingsWindow) {
     250                if (fSettingsWindow->Lock()) {
     251                    if (!fSettingsWindow->IsHidden()
     252                        && fSettingsWindow->IsActive())
     253                        fSettingsWindow->Hide();
     254                    fSettingsWindow->Unlock();
     255                }
     256                break;
     257            }
     258        }
    245259        return false;
     260    }
    246261
    247262    gStatusWindow->AttemptToQuit();
    248263        // try quitting the copy/move/empty trash threads