Changeset 103680 in vbox
- Timestamp:
- Mar 5, 2024 12:31:30 PM (7 months ago)
- Location:
- trunk/src/VBox/Frontends/VirtualBox/src
- Files:
-
- 4 edited
-
globals/UIGuestOSType.cpp (modified) (4 diffs)
-
globals/UIGuestOSType.h (modified) (1 diff)
-
settings/editors/UINameAndSystemEditor.cpp (modified) (2 diffs)
-
widgets/UIGuestOSTypeSelectionButton.cpp (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/globals/UIGuestOSType.cpp
r103674 r103680 116 116 117 117 UIGuestOSTypeManager::UIGuestOSFamilyInfo 118 UIGuestOSTypeManager::getFamilies(bool fListAll, KPlatformArchitecture enmArch /* = KPlatformArchitecture_None */) const 118 UIGuestOSTypeManager::getFamilies(bool fListAll, 119 KPlatformArchitecture enmArch /* = KPlatformArchitecture_None */) const 119 120 { 120 121 /* Return all families by default: */ … … 135 136 136 137 QStringList 137 UIGuestOSTypeManager::getSubtype ListForFamilyId(const QString &strFamilyId,138 KPlatformArchitecture enmArch /* = KPlatformArchitecture_None */) const138 UIGuestOSTypeManager::getSubtypesForFamilyId(const QString &strFamilyId, 139 KPlatformArchitecture enmArch /* = KPlatformArchitecture_None */) const 139 140 { 140 141 /* Prepare list by arch type: */ … … 157 158 158 159 UIGuestOSTypeManager::UIGuestOSTypeInfo 159 UIGuestOSTypeManager::getType ListForFamilyId(const QString &strFamilyId,160 KPlatformArchitecture enmArch /* = KPlatformArchitecture_None */) const160 UIGuestOSTypeManager::getTypesForFamilyId(const QString &strFamilyId, 161 KPlatformArchitecture enmArch /* = KPlatformArchitecture_None */) const 161 162 { 162 163 UIGuestOSTypeInfo typeInfoList; 164 if (strFamilyId.isEmpty()) 165 return typeInfoList; 163 166 foreach (const UIGuestOSType &type, m_guestOSTypes) 164 167 { … … 176 179 177 180 UIGuestOSTypeManager::UIGuestOSTypeInfo 178 UIGuestOSTypeManager::getType ListForSubtype(const QString &strSubtype,179 KPlatformArchitecture enmArch /* = KPlatformArchitecture_None */) const181 UIGuestOSTypeManager::getTypesForSubtype(const QString &strSubtype, 182 KPlatformArchitecture enmArch /* = KPlatformArchitecture_None */) const 180 183 { 181 184 UIGuestOSTypeInfo typeInfoList; -
trunk/src/VBox/Frontends/VirtualBox/src/globals/UIGuestOSType.h
r103674 r103680 150 150 void reCacheGuestOSTypes(); 151 151 152 /** Returns a list of all families (id and description). */ 153 UIGuestOSFamilyInfo getFamilies(bool fListAll, KPlatformArchitecture enmArch = KPlatformArchitecture_None) const; 152 /** Returns a list of all families. */ 153 UIGuestOSFamilyInfo getFamilies(bool fListAll, 154 KPlatformArchitecture enmArch = KPlatformArchitecture_None) const; 154 155 /** Returns the list of subtypes for @p strFamilyId. This may be an empty list. */ 155 QStringList getSubtype ListForFamilyId(const QString &strFamilyId,156 KPlatformArchitecture enmArch = KPlatformArchitecture_None) const;156 QStringList getSubtypesForFamilyId(const QString &strFamilyId, 157 KPlatformArchitecture enmArch = KPlatformArchitecture_None) const; 157 158 /** Returns a list of OS types for the @p strFamilyId. */ 158 UIGuestOSTypeInfo getType ListForFamilyId(const QString &strFamilyId,159 KPlatformArchitecture enmArch = KPlatformArchitecture_None) const;159 UIGuestOSTypeInfo getTypesForFamilyId(const QString &strFamilyId, 160 KPlatformArchitecture enmArch = KPlatformArchitecture_None) const; 160 161 /** Returns a list of OS types for the @p strSubtype. */ 161 UIGuestOSTypeInfo getType ListForSubtype(const QString &strSubtype,162 KPlatformArchitecture enmArch = KPlatformArchitecture_None) const;162 UIGuestOSTypeInfo getTypesForSubtype(const QString &strSubtype, 163 KPlatformArchitecture enmArch = KPlatformArchitecture_None) const; 163 164 164 165 /** Returns whether specified @a strOSTypeId is of DOS type. */ -
trunk/src/VBox/Frontends/VirtualBox/src/settings/editors/UINameAndSystemEditor.cpp
r103674 r103680 342 342 const UIGuestOSTypeManager::UIGuestOSTypeInfo types 343 343 = m_strDistribution.isEmpty() 344 ? uiCommon().guestOSTypeManager().getType ListForFamilyId(m_strFamilyId, enmArch)345 : uiCommon().guestOSTypeManager().getType ListForSubtype(m_strDistribution, enmArch);344 ? uiCommon().guestOSTypeManager().getTypesForFamilyId(m_strFamilyId, enmArch) 345 : uiCommon().guestOSTypeManager().getTypesForSubtype(m_strDistribution, enmArch); 346 346 347 347 /* Save the most recently used item: */ … … 651 651 652 652 /* Acquire a list of suitable sub-types: */ 653 const QStringList distributions = uiCommon().guestOSTypeManager().getSubtype ListForFamilyId(m_strFamilyId, enmArch);653 const QStringList distributions = uiCommon().guestOSTypeManager().getSubtypesForFamilyId(m_strFamilyId, enmArch); 654 654 m_pLabelDistribution->setEnabled(!distributions.isEmpty()); 655 655 m_pComboDistribution->setEnabled(!distributions.isEmpty()); -
trunk/src/VBox/Frontends/VirtualBox/src/widgets/UIGuestOSTypeSelectionButton.cpp
r103674 r103680 114 114 const UIFamilyInfo &fi = familyList.at(i); 115 115 QMenu *pSubMenu = m_pMainMenu->addMenu(fi.m_strDescription); 116 QStringList subtypeList = uiCommon().guestOSTypeManager().getSubtype ListForFamilyId(fi.m_strId);116 QStringList subtypeList = uiCommon().guestOSTypeManager().getSubtypesForFamilyId(fi.m_strId); 117 117 118 118 if (subtypeList.isEmpty()) 119 createOSTypeMenu(uiCommon().guestOSTypeManager().getType ListForFamilyId(fi.m_strId), pSubMenu);119 createOSTypeMenu(uiCommon().guestOSTypeManager().getTypesForFamilyId(fi.m_strId), pSubMenu); 120 120 else 121 121 { 122 122 foreach (const QString &strSubtype, subtypeList) 123 createOSTypeMenu(uiCommon().guestOSTypeManager().getType ListForSubtype(strSubtype), pSubMenu->addMenu(strSubtype));123 createOSTypeMenu(uiCommon().guestOSTypeManager().getTypesForSubtype(strSubtype), pSubMenu->addMenu(strSubtype)); 124 124 } 125 125 }
Note:
See TracChangeset
for help on using the changeset viewer.

