Changeset 83202 in vbox for trunk/src/VBox/Frontends
- Timestamp:
- Mar 4, 2020 4:32:34 PM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/globals/UIDetailsGenerator.cpp
r83191 r83202 149 149 /* Domain: */ 150 150 if (fOptions & UIExtraDataMetaDefs::DetailsElementOptionTypeGeneral_Location) 151 table << UITextTableLine(QApplication::translate("UIDetails", "Domain", "details (general)"), 152 guiCloudMachine.domain()); 151 { 152 const QString strDomain = guiCloudMachine.domain(); 153 const QString strResult = !strDomain.isEmpty() 154 ? strDomain 155 : QApplication::translate("UIDetails", "Checking ...", "details"); 156 table << UITextTableLine(QApplication::translate("UIDetails", "Domain", "details (general)"), strResult); 157 } 153 158 154 159 return table; … … 294 299 295 300 /* Instance Shape: */ 296 table << UITextTableLine(QApplication::translate("UIDetails", "Shape", "details (system)"), 297 guiCloudMachine.instanceShape()); 301 { 302 const QString strShape = guiCloudMachine.instanceShape(); 303 const QString strResult = !strShape.isEmpty() 304 ? strShape 305 : QApplication::translate("UIDetails", "Checking ...", "details"); 306 table << UITextTableLine(QApplication::translate("UIDetails", "Shape", "details (system)"), strResult); 307 } 298 308 299 309 /* Base memory: */ 300 310 if (fOptions & UIExtraDataMetaDefs::DetailsElementOptionTypeSystem_RAM) 301 table << UITextTableLine(QApplication::translate("UIDetails", "Base Memory", "details (system)"), 302 QApplication::translate("UIDetails", "%1 MB").arg(guiCloudMachine.memorySize())); 311 { 312 const int iMemorySize = guiCloudMachine.memorySize(); 313 const QString strResult = iMemorySize > 0 314 ? QApplication::translate("UIDetails", "%1 MB").arg(iMemorySize) 315 : QApplication::translate("UIDetails", "Checking ...", "details"); 316 table << UITextTableLine(QApplication::translate("UIDetails", "Base Memory", "details (system)"), strResult); 317 } 303 318 304 319 /* Processors: */ 305 320 if (fOptions & UIExtraDataMetaDefs::DetailsElementOptionTypeSystem_CPUCount) 306 table << UITextTableLine(QApplication::translate("UIDetails", "Processors", "details (system)"), 307 QString::number(guiCloudMachine.cpuCount())); 321 { 322 const int cCpuCount = guiCloudMachine.cpuCount(); 323 const QString strResult = cCpuCount > 0 324 ? QString::number(cCpuCount) 325 : QApplication::translate("UIDetails", "Checking ...", "details"); 326 table << UITextTableLine(QApplication::translate("UIDetails", "Processors", "details (system)"), strResult); 327 } 308 328 309 329 /* Booting firmware: */ 310 330 if (fOptions & UIExtraDataMetaDefs::DetailsElementOptionTypeSystem_Firmware) 311 table << UITextTableLine(QApplication::translate("UIDetails", "Booting Firmware", "details (system)"), 312 guiCloudMachine.bootingFirmware()); 331 { 332 const QString strBottingFirmware = guiCloudMachine.bootingFirmware(); 333 const QString strResult = !strBottingFirmware.isEmpty() 334 ? strBottingFirmware 335 : QApplication::translate("UIDetails", "Checking ...", "details"); 336 table << UITextTableLine(QApplication::translate("UIDetails", "Booting Firmware", "details (system)"), strResult); 337 } 313 338 314 339 return table; … … 559 584 const QString strResult = !strImageName.isEmpty() && !strImageSize.isEmpty() 560 585 ? QString("%1 (%2)").arg(strImageName, strImageSize) 561 : Q String();586 : QApplication::translate("UIDetails", "Checking ...", "details"); 562 587 table << UITextTableLine(QApplication::translate("UIDetails", "Image", "details (storage)"), strResult); 563 588 }
Note:
See TracChangeset
for help on using the changeset viewer.