Changeset 66354 in vbox
- Timestamp:
- Mar 30, 2017 10:50:51 AM (8 years ago)
- Location:
- trunk/src/VBox/Frontends/VirtualBox/src/settings/global
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/settings/global/UIGlobalSettingsDisplay.cpp
r66343 r66354 98 98 99 99 /* Load old data from cache: */ 100 if ( (oldData.m_strMaxGuestResolution.isEmpty()) ||101 (oldData.m_strMaxGuestResolution == "auto"))100 if ( (oldData.m_strMaxGuestResolution.isEmpty()) 101 || (oldData.m_strMaxGuestResolution == "auto")) 102 102 { 103 103 /* Switch combo-box item: */ … … 114 114 m_pMaxResolutionCombo->setCurrentIndex(m_pMaxResolutionCombo->findData("fixed")); 115 115 /* Trying to parse text into 2 sections by ',' symbol: */ 116 int iWidth = oldData.m_strMaxGuestResolution.section(',', 0, 0).toInt();117 int iHeight = oldData.m_strMaxGuestResolution.section(',', 1, 1).toInt();116 const int iWidth = oldData.m_strMaxGuestResolution.section(',', 0, 0).toInt(); 117 const int iHeight = oldData.m_strMaxGuestResolution.section(',', 1, 1).toInt(); 118 118 /* And set values if they are present: */ 119 119 m_pResolutionWidthSpin->setValue(iWidth); … … 134 134 newData.m_strMaxGuestResolution = QString(); 135 135 } 136 else if ( m_pMaxResolutionCombo->itemData(m_pMaxResolutionCombo->currentIndex()).toString() == "any" ||137 m_pResolutionWidthSpin->value() == 0 || m_pResolutionHeightSpin->value() == 0)136 else if ( m_pMaxResolutionCombo->itemData(m_pMaxResolutionCombo->currentIndex()).toString() == "any" 137 || m_pResolutionWidthSpin->value() == 0 || m_pResolutionHeightSpin->value() == 0) 138 138 { 139 139 /* Else if resolution current combo item is "any" -
trunk/src/VBox/Frontends/VirtualBox/src/settings/global/UIGlobalSettingsExtension.cpp
r66343 r66354 281 281 282 282 /* Gather old data: */ 283 const CExtPack Manager &manager = vboxGlobal().virtualBox().GetExtensionPackManager();284 const CExtPackVector &packages = manager.GetInstalledExtPacks();285 for (int i = 0; i < packages.size(); ++i)283 const CExtPackVector &packages = vboxGlobal().virtualBox(). 284 GetExtensionPackManager().GetInstalledExtPacks(); 285 foreach (const CExtPack &package, packages) 286 286 { 287 287 UIDataSettingsGlobalExtensionItem item; 288 loadData(package s[i], item);288 loadData(package, item); 289 289 oldData.m_items << item; 290 290 } … … 303 303 304 304 /* Load old data from cache: */ 305 for (int i = 0; i < oldData.m_items.size(); ++i)306 new UIExtensionPackageItem(m_pPackagesTree, oldData.m_items.at(i));305 foreach (const UIDataSettingsGlobalExtensionItem &item, oldData.m_items) 306 new UIExtensionPackageItem(m_pPackagesTree, item); 307 307 /* If at least one item present: */ 308 308 if (m_pPackagesTree->topLevelItemCount()) -
trunk/src/VBox/Frontends/VirtualBox/src/settings/global/UIGlobalSettingsInput.cpp
r66343 r66354 951 951 { 952 952 /* Save host-combo shortcut from cache: */ 953 UIDataShortcutRow fakeHostComboItem(0, UIHostCombo::hostComboCacheKey(), QString(), QString(), QString());953 const UIDataShortcutRow fakeHostComboItem(0, UIHostCombo::hostComboCacheKey(), QString(), QString(), QString()); 954 954 const int iHostComboItemBase = UIFunctorFindShortcut(UIFunctorFindShortcut::Base)(m_pCache->base().shortcuts(), fakeHostComboItem); 955 955 const int iHostComboItemData = UIFunctorFindShortcut(UIFunctorFindShortcut::Base)(m_pCache->data().shortcuts(), fakeHostComboItem); -
trunk/src/VBox/Frontends/VirtualBox/src/settings/global/UIGlobalSettingsUpdate.cpp
r66343 r66354 92 92 93 93 /* Gather old data: */ 94 VBoxUpdateData updateData(gEDataManager->applicationUpdateData());94 const VBoxUpdateData updateData(gEDataManager->applicationUpdateData()); 95 95 oldData.m_fCheckEnabled = !updateData.isNoNeedToCheck(); 96 96 oldData.m_periodIndex = updateData.periodIndex(); … … 148 148 { 149 149 /* Gather corresponding values from internal variables: */ 150 VBoxUpdateData newData(m_pCache->data().m_periodIndex, m_pCache->data().m_branchIndex);150 const VBoxUpdateData newData(m_pCache->data().m_periodIndex, m_pCache->data().m_branchIndex); 151 151 gEDataManager->setApplicationUpdateData(newData.data()); 152 152 }
Note:
See TracChangeset
for help on using the changeset viewer.