Changeset 90039 in vbox for trunk/src/VBox/Frontends
- Timestamp:
- Jul 5, 2021 7:39:38 PM (4 years ago)
- svn:sync-xref-src-repo-rev:
- 145533
- Location:
- trunk/src/VBox/Frontends/VirtualBox/src
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/widgets/UIUserNamePasswordEditor.h
r90037 r90039 44 44 void sigUserNameChanged(const QString &strUserName); 45 45 void sigPasswordChanged(const QString &strPassword); 46 47 46 48 47 public: -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/newvm/UIWizardNewVM.cpp
r90037 r90039 754 754 } 755 755 756 const QString &UIWizardNewVM::guestAdditionsISOPath() const 757 { 758 return m_strGuestAdditionsISOPath; 759 } 760 761 void UIWizardNewVM::setGuestAdditionsISOPath(const QString &strGAISOPath) 762 { 763 m_strGuestAdditionsISOPath = strGAISOPath; 764 } 765 766 const QString &UIWizardNewVM::hostname() const 767 { 768 return m_strHostname; 769 } 770 771 void UIWizardNewVM::setHostname(const QString &strHostname) 772 { 773 m_strHostname = strHostname; 774 } 775 776 const QString &UIWizardNewVM::productKey() const 777 { 778 return m_strProductKey; 779 } 780 781 void UIWizardNewVM::setProductKey(const QString &productKey) 782 { 783 m_strProductKey = productKey; 784 } 785 756 786 const UIUnattendedInstallData &UIWizardNewVM::unattendedInstallData() const 757 787 { 758 788 m_unattendedInstallData.m_strISOPath = m_strISOFilePath; 759 // m_unattendedInstallData.m_strUserName = getStringFieldValue("userName"); 760 // m_unattendedInstallData.m_strHostname = getStringFieldValue("hostname"); 761 // m_unattendedInstallData.m_strPassword = getStringFieldValue("password"); 789 m_unattendedInstallData.m_strUserName = m_strUserName; 790 m_unattendedInstallData.m_strPassword = m_strPassword; 791 m_unattendedInstallData.m_strHostname = m_strHostname; 792 762 793 m_unattendedInstallData.m_strDetectedOSTypeId = m_strDetectedOSTypeId; 763 794 // // m_unattendedInstallData.m_strDetectedOSVersion = getStringFieldValue("detectedOSVersion"); … … 765 796 // // m_unattendedInstallData.m_strDetectedOSLanguages = getStringFieldValue("detectedOSLanguages"); 766 797 // // m_unattendedInstallData.m_strDetectedOSHints = getStringFieldValue("detectedOSHints"); 767 // m_unattendedInstallData.m_strProductKey = getStringFieldValue("productKey");768 // m_unattendedInstallData.m_strGuestAdditionsISOPath = getStringFieldValue("guestAdditionsISOPath");798 m_unattendedInstallData.m_strProductKey = m_strProductKey; 799 m_unattendedInstallData.m_strGuestAdditionsISOPath = m_strGuestAdditionsISOPath; 769 800 770 801 // m_unattendedInstallData.m_fUnattendedEnabled = getBoolFieldValue("isUnattendedEnabled"); 771 802 // m_unattendedInstallData.m_fStartHeadless = getBoolFieldValue("startHeadless"); 772 // m_unattendedInstallData.m_fInstallGuestAdditions = getBoolFieldValue("installGuestAdditions"); 773 803 m_unattendedInstallData.m_fInstallGuestAdditions = m_fInstallGuestAdditions; 774 804 // m_unattendedInstallData.m_uMachineUid = createdMachineId(); 775 805 -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/newvm/UIWizardNewVM.h
r90037 r90039 120 120 void setPassword(const QString &strPassword); 121 121 122 const QString &guestAdditionsISOPath() const; 123 void setGuestAdditionsISOPath(const QString &strGAISOPath); 124 125 const QString &hostname() const; 126 void setHostname(const QString &strHostname); 127 128 const QString &productKey() const; 129 void setProductKey(const QString &productKey); 130 122 131 protected: 123 132 … … 187 196 QString m_strUserName; 188 197 QString m_strPassword; 198 QString m_strGuestAdditionsISOPath; 199 QString m_strHostname; 200 QString m_strProductKey; 189 201 }; 190 202 -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/newvm/UIWizardNewVMUnattendedPageBasic.cpp
r90037 r90039 39 39 #include "CSystemProperties.h" 40 40 #include "CUnattended.h" 41 42 // UIWizardNewVMUnattendedPage::UIWizardNewVMUnattendedPage()43 44 // {45 // }46 47 // QString UIWizardNewVMUnattendedPage::userName() const48 // {49 // if (m_pUserNamePasswordEditor)50 // return m_pUserNamePasswordEditor->userName();51 // return QString();52 // }53 54 // void UIWizardNewVMUnattendedPage::setUserName(const QString &strName)55 // {56 // if (m_pUserNamePasswordEditor)57 // m_pUserNamePasswordEditor->setUserName(strName);58 // }59 60 // QString UIWizardNewVMUnattendedPage::password() const61 // {62 // if (m_pUserNamePasswordEditor)63 // return m_pUserNamePasswordEditor->password();64 // return QString();65 // }66 67 // void UIWizardNewVMUnattendedPage::setPassword(const QString &strPassword)68 // {69 // if (m_pUserNamePasswordEditor)70 // return m_pUserNamePasswordEditor->setPassword(strPassword);71 // }72 73 // QString UIWizardNewVMUnattendedPage::hostname() const74 // {75 // if (m_pHostnameLineEdit)76 // return m_pHostnameLineEdit->text();77 // return QString();78 // }79 80 // void UIWizardNewVMUnattendedPage::setHostname(const QString &strHostName)81 // {82 // if (m_pHostnameLineEdit)83 // return m_pHostnameLineEdit->setText(strHostName);84 // }85 86 87 88 // QString UIWizardNewVMUnattendedPage::guestAdditionsISOPath() const89 // {90 // if (!m_pGAISOFilePathSelector)91 // return QString();92 // return m_pGAISOFilePathSelector->path();93 // }94 95 // void UIWizardNewVMUnattendedPage::setGuestAdditionsISOPath(const QString &strISOPath)96 // {97 // if (m_pGAISOFilePathSelector)98 // m_pGAISOFilePathSelector->setPath(strISOPath);99 // }100 41 101 42 // QString UIWizardNewVMUnattendedPage::productKey() const … … 166 107 void UIWizardNewVMUnattendedPageBasic::createConnections() 167 108 { 168 // if (m_pUserNamePasswordEditor) 169 // connect(m_pUserNamePasswordEditor, &UIUserNamePasswordEditor::sigSomeTextChanged, 170 // this, &UIWizardNewVMUnattendedPageBasic::completeChanged); 109 if (m_pUserNamePasswordEditor) 110 { 111 connect(m_pUserNamePasswordEditor, &UIUserNamePasswordEditor::sigPasswordChanged, 112 this, &UIWizardNewVMUnattendedPageBasic::sltPasswordChanged); 113 connect(m_pUserNamePasswordEditor, &UIUserNamePasswordEditor::sigUserNameChanged, 114 this, &UIWizardNewVMUnattendedPageBasic::sltUserNameChanged); 115 } 116 171 117 if (m_pGAISOFilePathSelector) 172 118 connect(m_pGAISOFilePathSelector, &UIFilePathSelector::pathChanged, … … 175 121 connect(m_pGAInstallationISOContainer, &QGroupBox::toggled, 176 122 this, &UIWizardNewVMUnattendedPageBasic::sltInstallGACheckBoxToggle); 123 if (m_pHostnameLineEdit) 124 connect(m_pHostnameLineEdit, &QLineEdit::textChanged, 125 this, &UIWizardNewVMUnattendedPageBasic::sltHostnameChanged); 126 if (m_pProductKeyLineEdit) 127 connect(m_pProductKeyLineEdit, &QLineEdit::textChanged, 128 this, &UIWizardNewVMUnattendedPageBasic::sltProductKeyChanged); 129 177 130 } 178 131 … … 250 203 void UIWizardNewVMUnattendedPageBasic::sltGAISOPathChanged(const QString &strPath) 251 204 { 252 Q_UNUSED(strPath); 205 if (m_pWizard) 206 m_pWizard->setGuestAdditionsISOPath(strPath); 253 207 emit completeChanged(); 254 208 } 255 209 210 void UIWizardNewVMUnattendedPageBasic::sltPasswordChanged(const QString &strPassword) 211 { 212 if (m_pWizard) 213 m_pWizard->setPassword(strPassword); 214 emit completeChanged(); 215 } 216 217 void UIWizardNewVMUnattendedPageBasic::sltUserNameChanged(const QString &strUserName) 218 { 219 if (m_pWizard) 220 m_pWizard->setUserName(strUserName); 221 emit completeChanged(); 222 } 223 256 224 bool UIWizardNewVMUnattendedPageBasic::isProductKeyWidgetEnabled() const 257 225 { … … 259 227 return false; 260 228 return true; 229 } 230 231 void UIWizardNewVMUnattendedPageBasic::sltHostnameChanged(const QString &strHostname) 232 { 233 if (m_pWizard) 234 m_pWizard->setHostname(strHostname); 235 } 236 237 void UIWizardNewVMUnattendedPageBasic::sltProductKeyChanged(const QString &strProductKey) 238 { 239 if (m_pWizard) 240 m_pWizard->setProductKey(strProductKey); 261 241 } 262 242 -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/newvm/UIWizardNewVMUnattendedPageBasic.h
r90037 r90039 87 87 void sltInstallGACheckBoxToggle(bool fChecked); 88 88 void sltGAISOPathChanged(const QString &strPath); 89 // void sltPasswordChanged(const QString &strPassword); 90 // void sltUserNameChanged(const QString &strUserName); 89 void sltPasswordChanged(const QString &strPassword); 90 void sltUserNameChanged(const QString &strUserName); 91 void sltHostnameChanged(const QString &strHostname); 92 void sltProductKeyChanged(const QString &strProductKey); 91 93 92 94 private:
Note:
See TracChangeset
for help on using the changeset viewer.