Changeset 85067 in vbox for trunk/src/VBox/Frontends
- Timestamp:
- Jul 6, 2020 12:49:55 PM (4 years ago)
- Location:
- trunk/src/VBox/Frontends/VirtualBox/src/wizards/newvm
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/wizards/newvm/UIWizardNewVMPageBasic2.cpp
r85066 r85067 119 119 } 120 120 121 voidUIWizardNewVMPage2::createUserNameHostNameWidgets()121 QWidget *UIWizardNewVMPage2::createUserNameHostNameWidgets() 122 122 { 123 123 if (!m_pToolBox) 124 return ;124 return 0; 125 125 QWidget *pContainer = new QWidget; 126 126 QGridLayout *pGridLayout = new QGridLayout(pContainer); … … 132 132 pGridLayout->addWidget(m_pHostnameLabel, 3, 0, 1, 1, Qt::AlignRight); 133 133 pGridLayout->addWidget(m_pHostnameLineEdit, 3, 1, 1, 3); 134 m_pToolBox->insertItem(ToolBoxItems_UserNameHostname, pContainer, UIIconPool::iconSet(":/cloud_profile_manager_16px.png"), QString());135 } 136 137 voidUIWizardNewVMPage2::createGAInstallWidgets()134 return pContainer; 135 } 136 137 QWidget *UIWizardNewVMPage2::createGAInstallWidgets() 138 138 { 139 139 if (!m_pToolBox) 140 return ;140 return 0; 141 141 QWidget *pContainer = new QWidget; 142 142 QGridLayout *pContainerLayout = new QGridLayout(pContainer); … … 160 160 pContainerLayout->addWidget(m_pISOPathLabel, 1, 1, 1, 1); 161 161 pContainerLayout->addWidget(m_pISOFilePathSelector, 1, 2, 1, 4); 162 163 m_pToolBox->insertItem(ToolBoxItems_GAInstall, pContainer, UIIconPool::iconSet(":/cloud_profile_manager_16px.png"), QString()); 164 } 165 166 void UIWizardNewVMPage2::createProductKeyWidgets() 162 return pContainer; 163 } 164 165 QWidget *UIWizardNewVMPage2::createProductKeyWidgets() 167 166 { 168 167 if (!m_pToolBox) 169 return ;168 return 0; 170 169 QWidget *pContainer = new QWidget; 171 170 QGridLayout *pGridLayout = new QGridLayout(pContainer); … … 176 175 pGridLayout->addWidget(m_pProductKeyLabel, 0, 0, 1, 1, Qt::AlignRight); 177 176 pGridLayout->addWidget(m_pProductKeyLineEdit, 0, 1, 1, 3); 178 m_pToolBox->insertItem(ToolBoxItems_ProductKey, pContainer, UIIconPool::iconSet(":/cloud_profile_manager_16px.png"), QString());177 return pContainer; 179 178 } 180 179 … … 210 209 } 211 210 212 createUserNameHostNameWidgets(); 213 createGAInstallWidgets(); 214 createProductKeyWidgets(); 211 m_pToolBox->insertItem(ToolBoxItems_UserNameHostname, createUserNameHostNameWidgets(), 212 UIIconPool::iconSet(":/cloud_profile_manager_16px.png"), QString()); 213 m_pToolBox->insertItem(ToolBoxItems_GAInstall, createGAInstallWidgets(), 214 UIIconPool::iconSet(":/cloud_profile_manager_16px.png"), QString()); 215 m_pToolBox->insertItem(ToolBoxItems_ProductKey, createProductKeyWidgets(), 216 UIIconPool::iconSet(":/cloud_profile_manager_16px.png"), QString()); 215 217 216 218 registerField("userName", this, "userName"); -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/newvm/UIWizardNewVMPageBasic2.h
r85063 r85067 67 67 }; 68 68 69 voidcreateUserNameHostNameWidgets();70 voidcreateGAInstallWidgets();71 voidcreateProductKeyWidgets();69 QWidget *createUserNameHostNameWidgets(); 70 QWidget *createGAInstallWidgets(); 71 QWidget *createProductKeyWidgets(); 72 72 73 73 bool checkGAISOFile() const; -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/newvm/UIWizardNewVMPageBasic3.cpp
r85066 r85067 154 154 } 155 155 156 voidUIWizardNewVMPage3::createDiskWidgets()156 QWidget *UIWizardNewVMPage3::createDiskWidgets() 157 157 { 158 158 QWidget *pDiskContainer = new QWidget; … … 181 181 pDiskLayout->addWidget(m_pDiskSelector, 3, 1); 182 182 pDiskLayout->addWidget(m_pVMMButton, 3, 2); 183 184 if (m_pToolBox) 185 m_pToolBox->insertItem(ToolBoxItems_Disk, pDiskContainer, UIIconPool::iconSet(":/cloud_profile_manager_16px.png"), QString()); 186 } 187 188 void UIWizardNewVMPage3::createHardwareWidgets() 183 return pDiskContainer; 184 } 185 186 QWidget *UIWizardNewVMPage3::createHardwareWidgets() 189 187 { 190 188 QWidget *pHardwareContainer = new QWidget; … … 195 193 pHardwareLayout->addWidget(m_pBaseMemoryEditor, 0, 0, 1, 4); 196 194 pHardwareLayout->addWidget(m_pVirtualCPUEditor, 1, 0, 1, 4); 197 198 if (m_pToolBox) 199 m_pToolBox->insertItem(ToolBoxItems_Hardware, pHardwareContainer, 200 UIIconPool::iconSet(":/cloud_profile_manager_16px.png"), QString()); 195 return pHardwareContainer; 201 196 } 202 197 … … 204 199 { 205 200 prepare(); 206 /* Register classes: */207 201 qRegisterMetaType<CMedium>(); 208 /* Register fields: */209 202 registerField("virtualDisk", this, "virtualDisk"); 210 203 registerField("virtualDiskId", this, "virtualDiskId"); … … 223 216 pMainLayout->addWidget(m_pLabel); 224 217 pMainLayout->addWidget(m_pToolBox); 225 createDiskWidgets(); 226 createHardwareWidgets(); 218 219 m_pToolBox->insertItem(ToolBoxItems_Disk, createDiskWidgets(), 220 UIIconPool::iconSet(":/cloud_profile_manager_16px.png"), QString()); 221 m_pToolBox->insertItem(ToolBoxItems_Hardware, createHardwareWidgets(), 222 UIIconPool::iconSet(":/cloud_profile_manager_16px.png"), QString()); 227 223 228 224 pMainLayout->addStretch(); -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/newvm/UIWizardNewVMPageBasic3.h
r85064 r85067 62 62 bool getWithNewVirtualDiskWizard(); 63 63 64 /** Stuff for 'virtualDisk' field. */65 CMedium virtualDisk() const { return m_virtualDisk; }66 void setVirtualDisk(const CMedium &virtualDisk) { m_virtualDisk = virtualDisk; }67 64 68 /** Stuff for 'virtualDiskId' field. */ 69 QUuid virtualDiskId() const { return m_uVirtualDiskId; } 70 void setVirtualDiskId(const QUuid &uVirtualDiskId) { m_uVirtualDiskId = uVirtualDiskId; } 65 /** @name Property getters/setters 66 * @{ */ 67 CMedium virtualDisk() const { return m_virtualDisk; } 68 void setVirtualDisk(const CMedium &virtualDisk) { m_virtualDisk = virtualDisk; } 69 QUuid virtualDiskId() const { return m_uVirtualDiskId; } 70 void setVirtualDiskId(const QUuid &uVirtualDiskId) { m_uVirtualDiskId = uVirtualDiskId; } 71 QString virtualDiskName() const { return m_strVirtualDiskName; } 72 void setVirtualDiskName(const QString &strVirtualDiskName) { m_strVirtualDiskName = strVirtualDiskName; } 73 QString virtualDiskLocation() const { return m_strVirtualDiskLocation; } 74 void setVirtualDiskLocation(const QString &strVirtualDiskLocation) { m_strVirtualDiskLocation = strVirtualDiskLocation; } 75 int baseMemory() const; 76 int VCPUCount() const; 77 /** @} */ 71 78 72 /** Stuff for 'virtualDiskName' field. */ 73 QString virtualDiskName() const { return m_strVirtualDiskName; } 74 void setVirtualDiskName(const QString &strVirtualDiskName) { m_strVirtualDiskName = strVirtualDiskName; } 75 76 /** Stuff for 'virtualDiskLocation' field. */ 77 QString virtualDiskLocation() const { return m_strVirtualDiskLocation; } 78 void setVirtualDiskLocation(const QString &strVirtualDiskLocation) { m_strVirtualDiskLocation = strVirtualDiskLocation; } 79 80 int baseMemory() const; 81 int VCPUCount() const; 82 83 void createDiskWidgets(); 84 void createHardwareWidgets(); 79 QWidget *createDiskWidgets(); 80 QWidget *createHardwareWidgets(); 85 81 86 82 /** Helpers. */ … … 90 86 bool m_fRecommendedNoDisk; 91 87 92 /** Variables. */ 93 CMedium m_virtualDisk; 94 QUuid m_uVirtualDiskId; 95 QString m_strVirtualDiskName; 96 QString m_strVirtualDiskLocation; 88 /** @name Variables 89 * @{ */ 90 CMedium m_virtualDisk; 91 QUuid m_uVirtualDiskId; 92 QString m_strVirtualDiskName; 93 QString m_strVirtualDiskLocation; 94 /** @} */ 97 95 98 96 /** @name Widgets
Note:
See TracChangeset
for help on using the changeset viewer.