Changeset 79205 in vbox
- Timestamp:
- Jun 18, 2019 10:04:17 AM (5 years ago)
- Location:
- trunk/src/VBox/Frontends/VirtualBox/src
- Files:
-
- 9 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/globals/VBoxGlobal.cpp
r79191 r79205 2574 2574 } 2575 2575 2576 #ifdef VBOX_GUI_WITH_NEW_MEDIA_EVENTS 2577 bool VBoxGlobal::isFullMediumEnumerationRequested() const 2578 { 2579 /* Redirect request to medium-enumerator: */ 2580 return m_pMediumEnumerator 2581 && m_pMediumEnumerator->isFullMediumEnumerationRequested(); 2582 } 2583 #endif 2584 2576 2585 UIMedium VBoxGlobal::medium(const QUuid &uMediumID) const 2577 2586 { -
trunk/src/VBox/Frontends/VirtualBox/src/globals/VBoxGlobal.h
r78723 r79205 484 484 /** Returns whether medium-enumeration is in progress. */ 485 485 bool isMediumEnumerationInProgress() const; 486 #ifdef VBOX_GUI_WITH_NEW_MEDIA_EVENTS 487 /** Returns whether full medium-enumeration is requested. */ 488 bool isFullMediumEnumerationRequested() const; 489 #endif 486 490 /** Returns enumerated medium with certain @a uMediumID. */ 487 491 UIMedium medium(const QUuid &uMediumID) const; -
trunk/src/VBox/Frontends/VirtualBox/src/medium/UIMediumEnumerator.cpp
r79152 r79205 89 89 UIMediumEnumerator::UIMediumEnumerator() 90 90 : m_fMediumEnumerationInProgress(false) 91 #ifdef VBOX_GUI_WITH_NEW_MEDIA_EVENTS 92 , m_fMediumEnumerationRequested(false) 93 #endif 91 94 { 92 95 /* Allow UIMedium to be used in inter-thread signals: */ … … 195 198 if (comMedia.isEmpty()) 196 199 { 200 #ifdef VBOX_GUI_WITH_NEW_MEDIA_EVENTS 201 m_fMediumEnumerationRequested = true; 202 #endif 197 203 addMediaToMap(vboxGlobal().virtualBox().GetHardDisks(), media); 198 204 addMediaToMap(vboxGlobal().host().GetDVDDrives(), media); … … 203 209 else 204 210 { 211 #ifdef VBOX_GUI_WITH_NEW_MEDIA_EVENTS 212 m_fMediumEnumerationRequested = false; 213 #endif 205 214 addMediaToMap(vboxGlobal().host().GetDVDDrives(), media); 206 215 addMediaToMap(vboxGlobal().virtualBox().GetDVDImages(), media); -
trunk/src/VBox/Frontends/VirtualBox/src/medium/UIMediumEnumerator.h
r79152 r79205 82 82 /** Returns whether consolidated medium-enumeration process is in progress. */ 83 83 bool isMediumEnumerationInProgress() const { return m_fMediumEnumerationInProgress; } 84 #ifdef VBOX_GUI_WITH_NEW_MEDIA_EVENTS 85 /** Returns whether full consolidated medium-enumeration process is requested. */ 86 bool isFullMediumEnumerationRequested() const { return m_fMediumEnumerationRequested; } 87 #endif 84 88 /** Makes a request to enumerate specified @a comMedia. 85 89 * @note Previous map will be replaced with the new one, values present in both … … 207 211 /** Holds whether consolidated medium-enumeration process is in progress. */ 208 212 bool m_fMediumEnumerationInProgress; 213 #ifdef VBOX_GUI_WITH_NEW_MEDIA_EVENTS 214 /** Holds whether full consolidated medium-enumeration process is requested. */ 215 bool m_fMediumEnumerationRequested; 216 #endif 209 217 210 218 /** Holds a set of current medium-enumeration tasks. */ -
trunk/src/VBox/Frontends/VirtualBox/src/medium/UIMediumManager.cpp
r79204 r79205 695 695 696 696 /* Start medium-enumeration (if necessary): */ 697 #ifndef VBOX_GUI_WITH_NEW_MEDIA_EVENTS 697 698 if (!vboxGlobal().isMediumEnumerationInProgress()) 699 #else 700 if (!vboxGlobal().isFullMediumEnumerationRequested()) 701 #endif 698 702 vboxGlobal().startMediumEnumeration(); 699 703 /* Emulate medium-enumeration otherwise: */ -
trunk/src/VBox/Frontends/VirtualBox/src/medium/UIMediumSelector.cpp
r78722 r79205 80 80 , m_strMachineGuestOSTypeId(strMachineGuestOSTypeId) 81 81 { 82 /* Start medium-enumeration (if necessary): */ 83 #ifndef VBOX_GUI_WITH_NEW_MEDIA_EVENTS 82 84 if (vboxGlobal().uiType() == VBoxGlobal::UIType_RuntimeUI) 85 #else 86 if (!vboxGlobal().isFullMediumEnumerationRequested()) 87 #endif 83 88 vboxGlobal().startMediumEnumeration(); 84 89 configure(); -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/information/UIVMInformationDialog.cpp
r78722 r79205 167 167 loadSettings(); 168 168 169 /* This is needed at least for some vm to show correct storage info. For the manager UI enumeration has been done already: */ 169 /* This is needed at least for some VM to show correct storage info. */ 170 #ifndef VBOX_GUI_WITH_NEW_MEDIA_EVENTS 170 171 if (vboxGlobal().uiType() == VBoxGlobal::UIType_RuntimeUI) 172 #else 173 if (!vboxGlobal().isFullMediumEnumerationRequested()) 174 #endif 171 175 vboxGlobal().startMediumEnumeration(); 172 176 } -
trunk/src/VBox/Frontends/VirtualBox/src/settings/machine/UIMachineSettingsStorage.cpp
r78722 r79205 3708 3708 UIIconPoolStorageSettings::create(); 3709 3709 3710 #ifdef VBOX_GUI_WITH_NEW_MEDIA_EVENTS 3711 /* Start medium-enumeration (only if necessary): */ 3712 if (!vboxGlobal().isFullMediumEnumerationRequested()) 3713 #endif 3710 3714 /* Enumerate Media. We need at least the MediaList filled, so this is the 3711 3715 * lasted point, where we can start. The rest of the media checking is done -
trunk/src/VBox/Frontends/VirtualBox/src/widgets/UIMediaComboBox.cpp
r78722 r79205 58 58 void UIMediaComboBox::repopulate() 59 59 { 60 /* Start medium-enumeration (if necessary): */ 61 #ifndef VBOX_GUI_WITH_NEW_MEDIA_EVENTS 60 62 if (!vboxGlobal().isMediumEnumerationInProgress()) 63 #else 64 if (!vboxGlobal().isFullMediumEnumerationRequested()) 65 #endif 61 66 vboxGlobal().startMediumEnumeration(); 62 67 else
Note:
See TracChangeset
for help on using the changeset viewer.