Changeset 73663 in vbox for trunk/src/VBox/Frontends/VirtualBox
- Timestamp:
- Aug 14, 2018 4:28:27 PM (6 years ago)
- Location:
- trunk/src/VBox/Frontends/VirtualBox/src
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/widgets/UIApplianceEditorWidget.cpp
r73326 r73663 404 404 case Qt::CheckStateRole: 405 405 { 406 if (iColumn == ApplianceViewSection_ConfigValue && 407 (m_enmVSDType == KVirtualSystemDescriptionType_Floppy || 408 m_enmVSDType == KVirtualSystemDescriptionType_CDROM || 409 m_enmVSDType == KVirtualSystemDescriptionType_USBController || 410 m_enmVSDType == KVirtualSystemDescriptionType_SoundCard || 411 m_enmVSDType == KVirtualSystemDescriptionType_NetworkAdapter || 412 m_enmVSDType == KVirtualSystemDescriptionType_CloudOCIPublicIP)) 413 { 414 m_checkState = static_cast<Qt::CheckState>(value.toInt()); 415 fDone = true; 406 if (iColumn == ApplianceViewSection_ConfigValue) 407 { 408 switch (m_enmVSDType) 409 { 410 /* These hardware items can be disabled: */ 411 case KVirtualSystemDescriptionType_Floppy: 412 case KVirtualSystemDescriptionType_CDROM: 413 case KVirtualSystemDescriptionType_USBController: 414 case KVirtualSystemDescriptionType_SoundCard: 415 case KVirtualSystemDescriptionType_NetworkAdapter: 416 { 417 m_checkState = static_cast<Qt::CheckState>(value.toInt()); 418 fDone = true; 419 break; 420 } 421 /* These option items can be enabled: */ 422 case KVirtualSystemDescriptionType_CloudOCIPublicIP: 423 { 424 if (value.toInt() == Qt::Unchecked) 425 m_strConfigValue = "false"; 426 else if (value.toInt() == Qt::Checked) 427 m_strConfigValue = "true"; 428 fDone = true; 429 break; 430 } 431 default: 432 break; 433 } 416 434 } 417 435 break; … … 499 517 value = strTmp; break; 500 518 } 501 case KVirtualSystemDescriptionType_OS: value = vboxGlobal().vmGuestOSTypeDescription(m_strConfigValue); break; 502 case KVirtualSystemDescriptionType_Memory: value = m_strConfigValue + " " + VBoxGlobal::tr("MB", "size suffix MBytes=1024 KBytes"); break; 503 case KVirtualSystemDescriptionType_SoundCard: value = gpConverter->toString(static_cast<KAudioControllerType>(m_strConfigValue.toInt())); break; 504 case KVirtualSystemDescriptionType_NetworkAdapter: value = gpConverter->toString(static_cast<KNetworkAdapterType>(m_strConfigValue.toInt())); break; 505 default: value = m_strConfigValue; break; 519 case KVirtualSystemDescriptionType_OS: value = vboxGlobal().vmGuestOSTypeDescription(m_strConfigValue); break; 520 case KVirtualSystemDescriptionType_Memory: value = m_strConfigValue + " " + VBoxGlobal::tr("MB", "size suffix MBytes=1024 KBytes"); break; 521 case KVirtualSystemDescriptionType_SoundCard: value = gpConverter->toString(static_cast<KAudioControllerType>(m_strConfigValue.toInt())); break; 522 case KVirtualSystemDescriptionType_NetworkAdapter: value = gpConverter->toString(static_cast<KNetworkAdapterType>(m_strConfigValue.toInt())); break; 523 case KVirtualSystemDescriptionType_CloudOCIPublicIP: break; 524 default: value = m_strConfigValue; break; 506 525 } 507 526 } … … 584 603 case Qt::CheckStateRole: 585 604 { 586 if (iColumn == ApplianceViewSection_ConfigValue && 587 (m_enmVSDType == KVirtualSystemDescriptionType_Floppy || 588 m_enmVSDType == KVirtualSystemDescriptionType_CDROM || 589 m_enmVSDType == KVirtualSystemDescriptionType_USBController || 590 m_enmVSDType == KVirtualSystemDescriptionType_SoundCard || 591 m_enmVSDType == KVirtualSystemDescriptionType_NetworkAdapter || 592 m_enmVSDType == KVirtualSystemDescriptionType_CloudOCIPublicIP)) 593 value = m_checkState; 605 if (iColumn == ApplianceViewSection_ConfigValue) 606 { 607 switch (m_enmVSDType) 608 { 609 /* These hardware items can be disabled: */ 610 case KVirtualSystemDescriptionType_Floppy: 611 case KVirtualSystemDescriptionType_CDROM: 612 case KVirtualSystemDescriptionType_USBController: 613 case KVirtualSystemDescriptionType_SoundCard: 614 case KVirtualSystemDescriptionType_NetworkAdapter: 615 { 616 value = m_checkState; 617 break; 618 } 619 /* These option items can be enabled: */ 620 case KVirtualSystemDescriptionType_CloudOCIPublicIP: 621 { 622 if (m_strConfigValue == "true") 623 value = Qt::Checked; 624 else 625 value = Qt::Unchecked; 626 break; 627 } 628 default: 629 break; 630 } 631 } 594 632 break; 595 633 } -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/exportappliance/UIWizardExportAppPageBasic3.cpp
r73657 r73663 271 271 { 272 272 case ParameterKind_Bool: 273 strValue = QString( );273 strValue = QString("true"); 274 274 break; 275 275 case ParameterKind_Double:
Note:
See TracChangeset
for help on using the changeset viewer.