VirtualBox

Changeset 90756 in vbox


Ignore:
Timestamp:
Aug 20, 2021 8:45:19 AM (3 years ago)
Author:
vboxsync
Message:

FE/Qt: bugref:9996. Adding the path and size location editor to the clone vd wizard.

Location:
trunk/src/VBox/Frontends/VirtualBox/src/wizards/clonevd
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VirtualBox/src/wizards/clonevd/UIWizardCloneVDPageBasic3.cpp

    r90748 r90756  
    1717
    1818/* Qt includes: */
    19 #include <QDir>
    2019#include <QVBoxLayout>
    21 #include <QHBoxLayout>
    22 #include <QLineEdit>
    2320
    2421/* GUI includes: */
    2522#include "UIWizardCloneVDPageBasic3.h"
     23#include "UIWizardDiskEditors.h"
    2624#include "UIWizardCloneVD.h"
    2725#include "UICommon.h"
     
    167165
    168166UIWizardCloneVDPageBasic3::UIWizardCloneVDPageBasic3()
     167    : m_pMediumSizePathGroupBox(0)
    169168{
    170169    prepare();
    171     // /* Create widgets: */
    172     // QVBoxLayout *pMainLayout = new QVBoxLayout(this);
    173     // {
    174     //     m_pLabel = new QIRichTextLabel(this);
    175     //     QHBoxLayout *pLocationLayout = new QHBoxLayout;
    176     //     {
    177     //         m_pDestinationDiskEditor = new QLineEdit(this);
    178     //         m_pDestinationDiskOpenButton = new QIToolButton(this);
    179     //         {
    180     //             m_pDestinationDiskOpenButton->setAutoRaise(true);
    181     //             m_pDestinationDiskOpenButton->setIcon(UIIconPool::iconSet(":/select_file_16px.png", "select_file_disabled_16px.png"));
    182     //         }
    183     //         pLocationLayout->addWidget(m_pDestinationDiskEditor);
    184     //         pLocationLayout->addWidget(m_pDestinationDiskOpenButton);
    185     //     }
    186     //     pMainLayout->addWidget(m_pLabel);
    187     //     pMainLayout->addLayout(pLocationLayout);
    188     //     pMainLayout->addStretch();
    189     // }
    190 
    191     // /* Setup page connections: */
     170}
     171
     172void UIWizardCloneVDPageBasic3::prepare()
     173{
     174    QVBoxLayout *pMainLayout = new QVBoxLayout(this);
     175
     176    m_pMediumSizePathGroupBox = new UIMediumSizeAndPathGroupBox(false /* expert mode */, 0);
     177    if (m_pMediumSizePathGroupBox)
     178        pMainLayout->addWidget(m_pMediumSizePathGroupBox);
     179
     180    pMainLayout->addStretch();
     181
    192182    // connect(m_pDestinationDiskEditor, &QLineEdit::textChanged,    this, &UIWizardCloneVDPageBasic3::completeChanged);
    193183    // connect(m_pDestinationDiskOpenButton, &QIToolButton::clicked, this, &UIWizardCloneVDPageBasic3::sltSelectLocationButtonClicked);
    194 }
    195 
    196 void UIWizardCloneVDPageBasic3::prepare()
    197 {
    198     QVBoxLayout *pMainLayout = new QVBoxLayout(this);
    199     Q_UNUSED(pMainLayout);
     184
     185    retranslateUi();
    200186}
    201187
     
    209195{
    210196    /* Translate page: */
    211     setTitle(UIWizardCloneVD::tr("New disk image to create"));
    212 
    213     // /* Translate widgets: */
    214     // m_pLabel->setText(UIWizardCloneVD::tr("Please type the name of the new virtual disk image file into the box below or "
    215     //                                       "click on the folder icon to select a different folder to create the file in."));
    216     // m_pDestinationDiskOpenButton->setToolTip(UIWizardCloneVD::tr("Choose a location for new virtual disk image file..."));
     197    setTitle(UIWizardCloneVD::tr("Location and size of the disk image"));
    217198}
    218199
  • trunk/src/VBox/Frontends/VirtualBox/src/wizards/clonevd/UIWizardCloneVDPageBasic3.h

    r90748 r90756  
    3232
    3333/* Forward declarations: */
    34 class CMediumFormat;
    35 class QLineEdit;
    36 class QIToolButton;
    3734class QIRichTextLabel;
    38 
     35class UIMediumSizeAndPathGroupBox;
    3936
    4037// /** 4th page of the Clone Virtual Disk Image wizard (base part): */
     
    108105    virtual bool validatePage() /* override */;
    109106
    110     /** Holds the description label instance. */
    111     QIRichTextLabel *m_pLabel;
     107    UIMediumSizeAndPathGroupBox *m_pMediumSizePathGroupBox;
    112108};
    113109
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