VirtualBox

Changeset 84971 in vbox for trunk


Ignore:
Timestamp:
Jun 26, 2020 2:57:03 PM (5 years ago)
Author:
vboxsync
Message:

FE/Qt: bugref:9515. Some fixes

Location:
trunk/src/VBox/Frontends/VirtualBox/src
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VirtualBox/src/manager/UIVirtualBoxManager.cpp

    r84965 r84971  
    617617        unattendedInstallData.m_strPassword = comUnattendedInstaller.GetPassword();
    618618        unattendedInstallData.m_strHostname = comUnattendedInstaller.GetHostname();
     619        unattendedInstallData.m_fInstallGuestAdditions = comUnattendedInstaller.GetInstallGuestAdditions();
     620        unattendedInstallData.m_strGuestAdditionsISOPath = comUnattendedInstaller.GetAdditionsIsoPath();
    619621
    620622        pWizard->setDefaultUnattendedInstallData(unattendedInstallData);
  • trunk/src/VBox/Frontends/VirtualBox/src/wizards/newvm/UIWizardNewVM.cpp

    r84965 r84971  
    507507void UIWizardNewVM::setDefaultUnattendedInstallData(const UIUnattendedInstallData &unattendedInstallData)
    508508{
    509     m_unattendedInstallData = unattendedInstallData;
    510     UIWizardNewVMPageBasicInstallSetup *pPage = qobject_cast<UIWizardNewVMPageBasicInstallSetup *>(page(PageInstallSetup));
    511     if (pPage)
    512         pPage->setDefaultUnattendedInstallData(unattendedInstallData);
     509    setField("userName", unattendedInstallData.m_strUserName);
     510    setField("password", unattendedInstallData.m_strPassword);
     511    setField("hostname", unattendedInstallData.m_strHostname);
    513512}
    514513
  • trunk/src/VBox/Frontends/VirtualBox/src/wizards/newvm/UIWizardNewVM.h

    r84965 r84971  
    3636    QUuid m_uMachineUid;
    3737    QString m_strISOPath;
    38     QString m_strGAIOSPath;
    3938    bool m_fStartHeadless;
    4039    QString m_strUserName;
     
    4746    QString m_strDetectedOSHints;
    4847    QString m_strProductKey;
     48    bool m_fInstallGuestAdditions;
     49    QString m_strGuestAdditionsISOPath;
    4950};
    5051
  • trunk/src/VBox/Frontends/VirtualBox/src/wizards/newvm/UIWizardNewVMPageBasicInstallSetup.cpp

    r84969 r84971  
    4242}
    4343
     44void UIWizardNewVMPageInstallSetup::setUserName(const QString &strName)
     45{
     46    if (m_pUserNamePasswordEditor)
     47        return m_pUserNamePasswordEditor->setUserName(strName);
     48}
     49
    4450QString UIWizardNewVMPageInstallSetup::password() const
    4551{
     
    4955}
    5056
     57void UIWizardNewVMPageInstallSetup::setPassword(const QString &strPassword)
     58{
     59    if (m_pUserNamePasswordEditor)
     60        return m_pUserNamePasswordEditor->setPassword(strPassword);
     61}
     62
    5163QString UIWizardNewVMPageInstallSetup::hostname() const
    5264{
     
    5466        return m_pHostnameLineEdit->text();
    5567    return QString();
     68}
     69
     70void UIWizardNewVMPageInstallSetup::setHostname(const QString &strHostName)
     71{
     72    if (m_pHostnameLineEdit)
     73        return m_pHostnameLineEdit->setText(strHostName);
    5674}
    5775
     
    84102    registerField("password", this, "password");
    85103    registerField("hostname", this, "hostname");
    86 }
    87 
    88 void UIWizardNewVMPageBasicInstallSetup::setDefaultUnattendedInstallData(const UIUnattendedInstallData &unattendedInstallData)
    89 {
    90     /* Initialize the widget data: */
    91     if (m_pUserNamePasswordEditor)
    92     {
    93         m_pUserNamePasswordEditor->setUserName(unattendedInstallData.m_strUserName);
    94         m_pUserNamePasswordEditor->setPassword(unattendedInstallData.m_strPassword);
    95     }
    96     if (m_pHostnameLineEdit)
    97         m_pHostnameLineEdit->setText(unattendedInstallData.m_strHostname);
    98104}
    99105
  • trunk/src/VBox/Frontends/VirtualBox/src/wizards/newvm/UIWizardNewVMPageBasicInstallSetup.h

    r84969 r84971  
    4141    UIWizardNewVMPageInstallSetup();
    4242
    43     /** @name Property getters
     43    /** @name Property getters/setters
    4444      * @{ */
    4545        QString userName() const;
     46        void setUserName(const QString &strName);
    4647        QString password() const;
     48        void setPassword(const QString &strPassword);
    4749        QString hostname() const;
     50        void setHostname(const QString &strHostName);
    4851    /** @} */
    4952
     
    5962{
    6063    Q_OBJECT;
    61     Q_PROPERTY(QString userName READ userName);
    62     Q_PROPERTY(QString password READ password);
    63     Q_PROPERTY(QString hostname READ hostname);
     64    Q_PROPERTY(QString userName READ userName WRITE setUserName);
     65    Q_PROPERTY(QString password READ password WRITE setPassword);
     66    Q_PROPERTY(QString hostname READ hostname WRITE setHostname);
    6467
    6568public:
     
    6770    /* Constructor: */
    6871    UIWizardNewVMPageBasicInstallSetup();
    69     void setDefaultUnattendedInstallData(const UIUnattendedInstallData &unattendedInstallData);
    7072    virtual int nextId() const /* override */;
    7173
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette