Changeset 106048 in vbox for trunk/src/VBox
- Timestamp:
- Sep 13, 2024 1:38:09 PM (3 months ago)
- Location:
- trunk/src/VBox/Frontends/VirtualBox/src/settings/editors
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/settings/editors/UIStorageSettingsEditor.cpp
r106047 r106048 2972 2972 , m_pLabelHDDetails(0) 2973 2973 , m_pFieldHDDetails(0) 2974 , m_pLabelHDLocation(0) 2975 , m_pFieldHDLocation(0) 2976 , m_pLabelHDUsage(0) 2977 , m_pFieldHDUsage(0) 2974 2978 , m_pLabelHDEncryption(0) 2975 2979 , m_pFieldHDEncryption(0) … … 2978 2982 , m_pLabelCDSize(0) 2979 2983 , m_pFieldCDSize(0) 2984 , m_pLabelCDLocation(0) 2985 , m_pFieldCDLocation(0) 2986 , m_pLabelCDUsage(0) 2987 , m_pFieldCDUsage(0) 2980 2988 , m_pLabelFDType(0) 2981 2989 , m_pFieldFDType(0) 2982 2990 , m_pLabelFDSize(0) 2983 2991 , m_pFieldFDSize(0) 2984 , m_pLabel Location(0)2985 , m_pField Location(0)2986 , m_pLabel Usage(0)2987 , m_pField Usage(0)2992 , m_pLabelFDLocation(0) 2993 , m_pFieldFDLocation(0) 2994 , m_pLabelFDUsage(0) 2995 , m_pFieldFDUsage(0) 2988 2996 { 2989 2997 prepare(); … … 3090 3098 m_pLabelHDDetails->setEnabled(fMachineInValidMode); 3091 3099 m_pFieldHDDetails->setEnabled(fMachineInValidMode); 3100 m_pLabelHDLocation->setEnabled(fMachineInValidMode); 3101 m_pFieldHDLocation->setEnabled(fMachineInValidMode); 3102 m_pLabelHDUsage->setEnabled(fMachineInValidMode); 3103 m_pFieldHDUsage->setEnabled(fMachineInValidMode); 3092 3104 m_pLabelHDEncryption->setEnabled(fMachineInValidMode); 3093 3105 m_pFieldHDEncryption->setEnabled(fMachineInValidMode); … … 3096 3108 m_pLabelCDSize->setEnabled(fMachineInValidMode); 3097 3109 m_pFieldCDSize->setEnabled(fMachineInValidMode); 3110 m_pLabelCDLocation->setEnabled(fMachineInValidMode); 3111 m_pFieldCDLocation->setEnabled(fMachineInValidMode); 3112 m_pLabelCDUsage->setEnabled(fMachineInValidMode); 3113 m_pFieldCDUsage->setEnabled(fMachineInValidMode); 3098 3114 m_pLabelFDType->setEnabled(fMachineInValidMode); 3099 3115 m_pFieldFDType->setEnabled(fMachineInValidMode); 3100 3116 m_pLabelFDSize->setEnabled(fMachineInValidMode); 3101 3117 m_pFieldFDSize->setEnabled(fMachineInValidMode); 3102 m_pLabel Location->setEnabled(fMachineInValidMode);3103 m_pField Location->setEnabled(fMachineInValidMode);3104 m_pLabel Usage->setEnabled(fMachineInValidMode);3105 m_pField Usage->setEnabled(fMachineInValidMode);3118 m_pLabelFDLocation->setEnabled(fMachineInValidMode); 3119 m_pFieldFDLocation->setEnabled(fMachineInValidMode); 3120 m_pLabelFDUsage->setEnabled(fMachineInValidMode); 3121 m_pFieldFDUsage->setEnabled(fMachineInValidMode); 3106 3122 3107 3123 /* Update remaining stuff: */ … … 3280 3296 m_pLabelHDActualSize->setText(tr("Actual size:")); 3281 3297 m_pLabelHDDetails->setText(tr("Storage details:")); 3298 m_pLabelHDLocation->setText(tr("Location:")); 3299 m_pLabelHDUsage->setText(tr("Attached to:")); 3282 3300 m_pLabelHDEncryption->setText(tr("Encryption key:")); 3283 3301 m_pLabelCDType->setText(tr("Type:")); 3284 3302 m_pLabelCDSize->setText(tr("Size:")); 3303 m_pLabelCDLocation->setText(tr("Location:")); 3304 m_pLabelCDUsage->setText(tr("Attached to:")); 3285 3305 m_pLabelFDType->setText(tr("Type:")); 3286 3306 m_pLabelFDSize->setText(tr("Size:")); 3287 m_pLabel Location->setText(tr("Location:"));3288 m_pLabel Usage->setText(tr("Attached to:"));3307 m_pLabelFDLocation->setText(tr("Location:")); 3308 m_pLabelFDUsage->setText(tr("Attached to:")); 3289 3309 3290 3310 /* Translate storage-view: */ … … 3736 3756 m_pLabelHDDetails->setVisible(enmDeviceType == KDeviceType_HardDisk); 3737 3757 m_pFieldHDDetails->setVisible(enmDeviceType == KDeviceType_HardDisk); 3758 m_pLabelHDLocation->setVisible(enmDeviceType == KDeviceType_HardDisk); 3759 m_pFieldHDLocation->setVisible(enmDeviceType == KDeviceType_HardDisk); 3760 m_pLabelHDUsage->setVisible(enmDeviceType == KDeviceType_HardDisk); 3761 m_pFieldHDUsage->setVisible(enmDeviceType == KDeviceType_HardDisk); 3738 3762 m_pLabelHDEncryption->setVisible(enmDeviceType == KDeviceType_HardDisk); 3739 3763 m_pFieldHDEncryption->setVisible(enmDeviceType == KDeviceType_HardDisk); … … 3742 3766 m_pLabelCDSize->setVisible(enmDeviceType == KDeviceType_DVD); 3743 3767 m_pFieldCDSize->setVisible(enmDeviceType == KDeviceType_DVD); 3768 m_pLabelCDLocation->setVisible(enmDeviceType == KDeviceType_DVD); 3769 m_pFieldCDLocation->setVisible(enmDeviceType == KDeviceType_DVD); 3770 m_pLabelCDUsage->setVisible(enmDeviceType == KDeviceType_DVD); 3771 m_pFieldCDUsage->setVisible(enmDeviceType == KDeviceType_DVD); 3744 3772 m_pLabelFDType->setVisible(enmDeviceType == KDeviceType_Floppy); 3745 3773 m_pFieldFDType->setVisible(enmDeviceType == KDeviceType_Floppy); 3746 3774 m_pLabelFDSize->setVisible(enmDeviceType == KDeviceType_Floppy); 3747 3775 m_pFieldFDSize->setVisible(enmDeviceType == KDeviceType_Floppy); 3776 m_pLabelFDLocation->setVisible(enmDeviceType == KDeviceType_Floppy); 3777 m_pFieldFDLocation->setVisible(enmDeviceType == KDeviceType_Floppy); 3778 m_pLabelFDUsage->setVisible(enmDeviceType == KDeviceType_Floppy); 3779 m_pFieldFDUsage->setVisible(enmDeviceType == KDeviceType_Floppy); 3748 3780 3749 3781 /* Getting other information: */ … … 3752 3784 m_pFieldHDActualSize->setText(compressText(pModel->data(index, StorageModel::R_AttSize).toString())); 3753 3785 m_pFieldHDDetails->setText(compressText(pModel->data(index, StorageModel::R_AttDetails).toString())); 3786 m_pFieldHDLocation->setText(compressText(pModel->data(index, StorageModel::R_AttLocation).toString())); 3787 m_pFieldHDUsage->setText(compressText(pModel->data(index, StorageModel::R_AttUsage).toString())); 3754 3788 m_pFieldHDEncryption->setText(compressText(pModel->data(index, StorageModel::R_AttEncryptionPasswordID).toString())); 3755 3789 m_pFieldCDType->setText(compressText(pModel->data(index, StorageModel::R_AttFormat).toString())); 3756 3790 m_pFieldCDSize->setText(compressText(pModel->data(index, StorageModel::R_AttSize).toString())); 3791 m_pFieldCDLocation->setText(compressText(pModel->data(index, StorageModel::R_AttLocation).toString())); 3792 m_pFieldCDUsage->setText(compressText(pModel->data(index, StorageModel::R_AttUsage).toString())); 3757 3793 m_pFieldFDType->setText(compressText(pModel->data(index, StorageModel::R_AttFormat).toString())); 3758 3794 m_pFieldFDSize->setText(compressText(pModel->data(index, StorageModel::R_AttSize).toString())); 3759 m_pField Location->setText(compressText(pModel->data(index, StorageModel::R_AttLocation).toString()));3760 m_pField Usage->setText(compressText(pModel->data(index, StorageModel::R_AttUsage).toString()));3795 m_pFieldFDLocation->setText(compressText(pModel->data(index, StorageModel::R_AttLocation).toString())); 3796 m_pFieldFDUsage->setText(compressText(pModel->data(index, StorageModel::R_AttUsage).toString())); 3761 3797 3762 3798 /* Showing attachment page: */ … … 4837 4873 m_pLayoutAttachment->setContentsMargins(10, 0, 0, 0); 4838 4874 m_pLayoutAttachment->setColumnStretch(2, 1); 4839 m_pLayoutAttachment->setRowStretch( 16, 1);4875 m_pLayoutAttachment->setRowStretch(20, 1); 4840 4876 4841 4877 /* Prepare separator for attachment case: */ … … 4991 5027 } 4992 5028 5029 /* Prepare HD location label: */ 5030 m_pLabelHDLocation = new QLabel(pWidgetAttachment); 5031 if (m_pLabelHDLocation) 5032 { 5033 m_pLabelHDLocation->setAlignment(Qt::AlignRight | Qt::AlignVCenter); 5034 m_pLayoutAttachment->addWidget(m_pLabelHDLocation, 9, 1); 5035 } 5036 /* Prepare HD location field: */ 5037 m_pFieldHDLocation = new QILabel(pWidgetAttachment); 5038 if (m_pFieldHDLocation) 5039 { 5040 m_pFieldHDLocation->setFullSizeSelection(true); 5041 m_pFieldHDLocation->setSizePolicy(QSizePolicy(QSizePolicy::Ignored, QSizePolicy::Minimum)); 5042 m_pLayoutAttachment->addWidget(m_pFieldHDLocation, 9, 2); 5043 } 5044 5045 /* Prepare HD usage label: */ 5046 m_pLabelHDUsage = new QLabel(pWidgetAttachment); 5047 if (m_pLabelHDUsage) 5048 { 5049 m_pLabelHDUsage->setAlignment(Qt::AlignRight | Qt::AlignVCenter); 5050 m_pLayoutAttachment->addWidget(m_pLabelHDUsage, 10, 1); 5051 } 5052 /* Prepare HD usage field: */ 5053 m_pFieldHDUsage = new QILabel(pWidgetAttachment); 5054 if (m_pFieldHDUsage) 5055 { 5056 m_pFieldHDUsage->setFullSizeSelection(true); 5057 m_pFieldHDUsage->setSizePolicy(QSizePolicy(QSizePolicy::Ignored, QSizePolicy::Minimum)); 5058 m_pLayoutAttachment->addWidget(m_pFieldHDUsage, 10, 2); 5059 } 5060 4993 5061 /* Prepare encryption label: */ 4994 5062 m_pLabelHDEncryption = new QLabel(pWidgetAttachment); … … 4996 5064 { 4997 5065 m_pLabelHDEncryption->setAlignment(Qt::AlignRight | Qt::AlignVCenter); 4998 m_pLayoutAttachment->addWidget(m_pLabelHDEncryption, 9, 1);5066 m_pLayoutAttachment->addWidget(m_pLabelHDEncryption, 11, 1); 4999 5067 } 5000 5068 /* Prepare encryption field: */ … … 5004 5072 m_pFieldHDEncryption->setFullSizeSelection(true); 5005 5073 m_pFieldHDEncryption->setSizePolicy(QSizePolicy(QSizePolicy::Ignored, QSizePolicy::Minimum)); 5006 m_pLayoutAttachment->addWidget(m_pFieldHDEncryption, 9, 2);5074 m_pLayoutAttachment->addWidget(m_pFieldHDEncryption, 11, 2); 5007 5075 } 5008 5076 … … 5012 5080 { 5013 5081 m_pLabelCDType->setAlignment(Qt::AlignRight | Qt::AlignVCenter); 5014 m_pLayoutAttachment->addWidget(m_pLabelCDType, 1 0, 1);5082 m_pLayoutAttachment->addWidget(m_pLabelCDType, 12, 1); 5015 5083 } 5016 5084 /* Prepare CD type field: */ … … 5020 5088 m_pFieldCDType->setFullSizeSelection(true); 5021 5089 m_pFieldCDType->setSizePolicy(QSizePolicy(QSizePolicy::Ignored, QSizePolicy::Minimum)); 5022 m_pLayoutAttachment->addWidget(m_pFieldCDType, 1 0, 2);5090 m_pLayoutAttachment->addWidget(m_pFieldCDType, 12, 2); 5023 5091 } 5024 5092 … … 5028 5096 { 5029 5097 m_pLabelCDSize->setAlignment(Qt::AlignRight | Qt::AlignVCenter); 5030 m_pLayoutAttachment->addWidget(m_pLabelCDSize, 1 1, 1);5098 m_pLayoutAttachment->addWidget(m_pLabelCDSize, 13, 1); 5031 5099 } 5032 5100 /* Prepare CD size field: */ … … 5036 5104 m_pFieldCDSize->setFullSizeSelection(true); 5037 5105 m_pFieldCDSize->setSizePolicy(QSizePolicy(QSizePolicy::Ignored, QSizePolicy::Minimum)); 5038 m_pLayoutAttachment->addWidget(m_pFieldCDSize, 11, 2); 5106 m_pLayoutAttachment->addWidget(m_pFieldCDSize, 13, 2); 5107 } 5108 5109 /* Prepare CD location label: */ 5110 m_pLabelCDLocation = new QLabel(pWidgetAttachment); 5111 if (m_pLabelCDLocation) 5112 { 5113 m_pLabelCDLocation->setAlignment(Qt::AlignRight | Qt::AlignVCenter); 5114 m_pLayoutAttachment->addWidget(m_pLabelCDLocation, 14, 1); 5115 } 5116 /* Prepare CD location field: */ 5117 m_pFieldCDLocation = new QILabel(pWidgetAttachment); 5118 if (m_pFieldCDLocation) 5119 { 5120 m_pFieldCDLocation->setFullSizeSelection(true); 5121 m_pFieldCDLocation->setSizePolicy(QSizePolicy(QSizePolicy::Ignored, QSizePolicy::Minimum)); 5122 m_pLayoutAttachment->addWidget(m_pFieldCDLocation, 14, 2); 5123 } 5124 5125 /* Prepare CD usage label: */ 5126 m_pLabelCDUsage = new QLabel(pWidgetAttachment); 5127 if (m_pLabelCDUsage) 5128 { 5129 m_pLabelCDUsage->setAlignment(Qt::AlignRight | Qt::AlignVCenter); 5130 m_pLayoutAttachment->addWidget(m_pLabelCDUsage, 15, 1); 5131 } 5132 /* Prepare CD usage field: */ 5133 m_pFieldCDUsage = new QILabel(pWidgetAttachment); 5134 if (m_pFieldCDUsage) 5135 { 5136 m_pFieldCDUsage->setFullSizeSelection(true); 5137 m_pFieldCDUsage->setSizePolicy(QSizePolicy(QSizePolicy::Ignored, QSizePolicy::Minimum)); 5138 m_pLayoutAttachment->addWidget(m_pFieldCDUsage, 15, 2); 5039 5139 } 5040 5140 … … 5044 5144 { 5045 5145 m_pLabelFDType->setAlignment(Qt::AlignRight | Qt::AlignVCenter); 5046 m_pLayoutAttachment->addWidget(m_pLabelFDType, 1 2, 1);5146 m_pLayoutAttachment->addWidget(m_pLabelFDType, 16, 1); 5047 5147 } 5048 5148 /* Prepare FD type field: */ … … 5052 5152 m_pFieldFDType->setFullSizeSelection(true); 5053 5153 m_pFieldFDType->setSizePolicy(QSizePolicy(QSizePolicy::Ignored, QSizePolicy::Minimum)); 5054 m_pLayoutAttachment->addWidget(m_pFieldFDType, 1 2, 2);5154 m_pLayoutAttachment->addWidget(m_pFieldFDType, 16, 2); 5055 5155 } 5056 5156 … … 5060 5160 { 5061 5161 m_pLabelFDSize->setAlignment(Qt::AlignRight | Qt::AlignVCenter); 5062 m_pLayoutAttachment->addWidget(m_pLabelFDSize, 1 3, 1);5162 m_pLayoutAttachment->addWidget(m_pLabelFDSize, 17, 1); 5063 5163 } 5064 5164 /* Prepare FD size field: */ … … 5068 5168 m_pFieldFDSize->setFullSizeSelection(true); 5069 5169 m_pFieldFDSize->setSizePolicy(QSizePolicy(QSizePolicy::Ignored, QSizePolicy::Minimum)); 5070 m_pLayoutAttachment->addWidget(m_pFieldFDSize, 1 3, 2);5071 } 5072 5073 /* Prepare location label: */5074 m_pLabel Location = new QLabel(pWidgetAttachment);5075 if (m_pLabel Location)5076 { 5077 m_pLabel Location->setAlignment(Qt::AlignRight | Qt::AlignVCenter);5078 m_pLayoutAttachment->addWidget(m_pLabel Location, 14, 1);5079 } 5080 /* Prepare location field: */5081 m_pField Location = new QILabel(pWidgetAttachment);5082 if (m_pField Location)5083 { 5084 m_pField Location->setFullSizeSelection(true);5085 m_pField Location->setSizePolicy(QSizePolicy(QSizePolicy::Ignored, QSizePolicy::Minimum));5086 m_pLayoutAttachment->addWidget(m_pField Location, 14, 2);5087 } 5088 5089 /* Prepare usage label: */5090 m_pLabel Usage = new QLabel(pWidgetAttachment);5091 if (m_pLabel Usage)5092 { 5093 m_pLabel Usage->setAlignment(Qt::AlignRight | Qt::AlignVCenter);5094 m_pLayoutAttachment->addWidget(m_pLabel Usage, 15, 1);5095 } 5096 /* Prepare usage field: */5097 m_pField Usage = new QILabel(pWidgetAttachment);5098 if (m_pField Usage)5099 { 5100 m_pField Usage->setFullSizeSelection(true);5101 m_pField Usage->setSizePolicy(QSizePolicy(QSizePolicy::Ignored, QSizePolicy::Minimum));5102 m_pLayoutAttachment->addWidget(m_pField Usage, 15, 2);5170 m_pLayoutAttachment->addWidget(m_pFieldFDSize, 17, 2); 5171 } 5172 5173 /* Prepare FD location label: */ 5174 m_pLabelFDLocation = new QLabel(pWidgetAttachment); 5175 if (m_pLabelFDLocation) 5176 { 5177 m_pLabelFDLocation->setAlignment(Qt::AlignRight | Qt::AlignVCenter); 5178 m_pLayoutAttachment->addWidget(m_pLabelFDLocation, 18, 1); 5179 } 5180 /* Prepare FD location field: */ 5181 m_pFieldFDLocation = new QILabel(pWidgetAttachment); 5182 if (m_pFieldFDLocation) 5183 { 5184 m_pFieldFDLocation->setFullSizeSelection(true); 5185 m_pFieldFDLocation->setSizePolicy(QSizePolicy(QSizePolicy::Ignored, QSizePolicy::Minimum)); 5186 m_pLayoutAttachment->addWidget(m_pFieldFDLocation, 18, 2); 5187 } 5188 5189 /* Prepare FD usage label: */ 5190 m_pLabelFDUsage = new QLabel(pWidgetAttachment); 5191 if (m_pLabelFDUsage) 5192 { 5193 m_pLabelFDUsage->setAlignment(Qt::AlignRight | Qt::AlignVCenter); 5194 m_pLayoutAttachment->addWidget(m_pLabelFDUsage, 19, 1); 5195 } 5196 /* Prepare FD usage field: */ 5197 m_pFieldFDUsage = new QILabel(pWidgetAttachment); 5198 if (m_pFieldFDUsage) 5199 { 5200 m_pFieldFDUsage->setFullSizeSelection(true); 5201 m_pFieldFDUsage->setSizePolicy(QSizePolicy(QSizePolicy::Ignored, QSizePolicy::Minimum)); 5202 m_pLayoutAttachment->addWidget(m_pFieldFDUsage, 19, 2); 5103 5203 } 5104 5204 -
trunk/src/VBox/Frontends/VirtualBox/src/settings/editors/UIStorageSettingsEditor.h
r106047 r106048 517 517 /** Holds the HD details field instance. */ 518 518 QILabel *m_pFieldHDDetails; 519 /** Holds the HD location label instance. */ 520 QLabel *m_pLabelHDLocation; 521 /** Holds the HD location field instance. */ 522 QILabel *m_pFieldHDLocation; 523 /** Holds the HD usage label instance. */ 524 QLabel *m_pLabelHDUsage; 525 /** Holds the HD usage field instance. */ 526 QILabel *m_pFieldHDUsage; 519 527 /** Holds the HD encryption label instance. */ 520 528 QLabel *m_pLabelHDEncryption; … … 529 537 /** Holds the CD size field instance. */ 530 538 QILabel *m_pFieldCDSize; 539 /** Holds the CD location label instance. */ 540 QLabel *m_pLabelCDLocation; 541 /** Holds the CD location field instance. */ 542 QILabel *m_pFieldCDLocation; 543 /** Holds the CD usage label instance. */ 544 QLabel *m_pLabelCDUsage; 545 /** Holds the CD usage field instance. */ 546 QILabel *m_pFieldCDUsage; 531 547 /** Holds the FD type label instance. */ 532 548 QLabel *m_pLabelFDType; … … 537 553 /** Holds the FD size field instance. */ 538 554 QILabel *m_pFieldFDSize; 539 /** Holds the location label instance. */540 QLabel *m_pLabel Location;541 /** Holds the location field instance. */542 QILabel *m_pField Location;543 /** Holds the usage label instance. */544 QLabel *m_pLabel Usage;545 /** Holds the usage field instance. */546 QILabel *m_pField Usage;555 /** Holds the FD location label instance. */ 556 QLabel *m_pLabelFDLocation; 557 /** Holds the FD location field instance. */ 558 QILabel *m_pFieldFDLocation; 559 /** Holds the FD usage label instance. */ 560 QLabel *m_pLabelFDUsage; 561 /** Holds the FD usage field instance. */ 562 QILabel *m_pFieldFDUsage; 547 563 /** @} */ 548 564 };
Note:
See TracChangeset
for help on using the changeset viewer.