VirtualBox

Changeset 29526 in vbox


Ignore:
Timestamp:
May 17, 2010 10:59:21 AM (15 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
61666
Message:

FE/Qt: New running VM core: More strict using of closing() signal in appropriate places.

Location:
trunk/src/VBox/Frontends/VirtualBox/src
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VirtualBox/src/VBoxMediaManagerDlg.cpp

    r28800 r29526  
    505505        mModelessDialog = new VBoxMediaManagerDlg (0, Qt::Window);
    506506        mModelessDialog->centerAccording (aCenterWidget);
    507         connect (vboxGlobal().mainWindow(), SIGNAL (closing()), mModelessDialog, SLOT (close()));
    508507        mModelessDialog->setAttribute (Qt::WA_DeleteOnClose);
    509508        mModelessDialog->setup (VBoxDefs::MediumType_All, false /* aDoSelect */, aRefresh);
     509
     510        /* Setup 'closing' connection if main window is VBoxSelectorWnd: */
     511        if (vboxGlobal().mainWindow() && vboxGlobal().mainWindow()->inherits("VBoxSelectorWnd"))
     512            connect(vboxGlobal().mainWindow(), SIGNAL(closing()), mModelessDialog, SLOT(close()));
    510513
    511514        /* listen to events that may change the media status and refresh
  • trunk/src/VBox/Frontends/VirtualBox/src/VBoxVMInformationDlg.cpp

    r28800 r29526  
    4949        id->centerAccording (pMachineWindow->machineWindow());
    5050        // TODO_NEW_CORE: this seems not necessary, cause we set WA_DeleteOnClose.
    51         connect (vboxGlobal().mainWindow(), SIGNAL (closing()), id, SLOT (close()));
    5251        id->setAttribute (Qt::WA_DeleteOnClose);
    5352        mSelfArray [machine.GetName()] = id;
     
    146145        VBoxVMInformationDlg *id = new VBoxVMInformationDlg (aConsole, aSession, Qt::Window);
    147146        id->centerAccording (aConsole);
    148         connect (vboxGlobal().mainWindow(), SIGNAL (closing()), id, SLOT (close()));
    149147        id->setAttribute (Qt::WA_DeleteOnClose);
    150148        mSelfArray [machine.GetName()] = id;
  • trunk/src/VBox/Frontends/VirtualBox/src/wizards/registration/UIRegistrationWzd.cpp

    r28800 r29526  
    418418#endif /* Q_WS_MAC */
    419419
    420     /* Setup connections */
    421     connect(vboxGlobal().mainWindow(), SIGNAL(closing()), this, SLOT(reject()));
     420    /* Setup 'closing' connection if main window is VBoxSelectorWnd: */
     421    if (vboxGlobal().mainWindow() && vboxGlobal().mainWindow()->inherits("VBoxSelectorWnd"))
     422        connect(vboxGlobal().mainWindow(), SIGNAL(closing()), this, SLOT(reject()));
    422423}
    423424
Note: See TracChangeset for help on using the changeset viewer.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette