Changeset 26079 in vbox
- Timestamp:
- Jan 27, 2010 4:41:49 PM (15 years ago)
- Location:
- trunk/src/VBox/Frontends/VirtualBox
- Files:
-
- 1 added
- 13 edited
- 13 copied
- 20 moved
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/Makefile.kmk
r25527 r26079 5 5 6 6 # 7 # Copyright (C) 2006-20 09Sun Microsystems, Inc.7 # Copyright (C) 2006-2010 Sun Microsystems, Inc. 8 8 # 9 9 # This file is part of VirtualBox Open Source Edition (OSE), as … … 220 220 ./src/wizards/exportappliance \ 221 221 ./src/wizards/importappliance \ 222 ./src/wizards/registration \ 222 223 ./src/widgets \ 223 224 ./src/X11 \ … … 284 285 src/VBoxGlobalSettings.h \ 285 286 src/VBoxMediaManagerDlg.h \ 286 src/VBoxRegistrationDlg.h \287 287 src/VBoxSelectorWnd.h \ 288 288 src/VBoxSnapshotDetailsDlg.h \ … … 296 296 src/globals/VBoxProblemReporter.h \ 297 297 src/globals/VBoxUtils.h \ 298 src/extensions/QIAbstractWizard.h \299 298 src/extensions/QIAdvancedSlider.h \ 300 299 src/extensions/QIArrowButtonPress.h \ … … 318 317 src/extensions/QITreeWidget.h \ 319 318 src/extensions/QIWidgetValidator.h \ 319 src/extensions/QIWizard.h \ 320 320 src/settings/VBoxSettingsDialog.h \ 321 321 src/settings/VBoxSettingsDialogSpecific.h \ … … 340 340 src/settings/vm/VBoxVMSettingsSF.h \ 341 341 src/settings/vm/VBoxVMSettingsSFDetails.h \ 342 src/wizards/newvm/VBoxNewVMWzd.h \ 343 src/wizards/newhd/VBoxNewHDWzd.h \ 344 src/wizards/firstrun/VBoxVMFirstRunWzd.h \ 345 src/wizards/exportappliance/VBoxExportApplianceWzd.h \ 346 src/wizards/importappliance/VBoxImportApplianceWzd.h \ 342 src/wizards/newvm/UINewVMWzd.h \ 343 src/wizards/newhd/UINewHDWzd.h \ 344 src/wizards/firstrun/UIFirstRunWzd.h \ 345 src/wizards/exportappliance/UIExportApplianceWzd.h \ 346 src/wizards/importappliance/UIImportApplianceWzd.h \ 347 src/wizards/registration/UIRegistrationWzd.h \ 347 348 src/widgets/VBoxApplianceEditorWgt.h \ 348 349 src/widgets/VBoxBootTable.h \ … … 364 365 src/VBoxSelectorWnd.cpp \ 365 366 src/VBoxConsoleWnd.cpp \ 366 src/VBoxMediaManagerDlg.cpp 367 src/VBoxMediaManagerDlg.cpp \ 368 src/wizards/registration/UIRegistrationWzd.cpp 367 369 ifdef VBOX_WITH_XPCOM 368 370 VirtualBox_QT_MOCSRCS += \ … … 385 387 src/VBoxMediaManagerDlg.cpp \ 386 388 src/VBoxMedium.cpp \ 387 src/VBoxRegistrationDlg.cpp \388 389 src/VBoxSelectorWnd.cpp \ 389 390 src/VBoxSnapshotDetailsDlg.cpp \ … … 398 399 src/globals/VBoxGlobal.cpp \ 399 400 src/globals/VBoxProblemReporter.cpp \ 400 src/extensions/QIAbstractWizard.cpp \401 401 src/extensions/QIAdvancedSlider.cpp \ 402 402 src/extensions/QIArrowButtonPress.cpp \ … … 420 420 src/extensions/QITreeWidget.cpp \ 421 421 src/extensions/QIWidgetValidator.cpp \ 422 src/extensions/QIWizard.cpp \ 422 423 src/settings/VBoxSettingsDialog.cpp \ 423 424 src/settings/VBoxSettingsDialogSpecific.cpp \ … … 441 442 src/settings/vm/VBoxVMSettingsSF.cpp \ 442 443 src/settings/vm/VBoxVMSettingsSFDetails.cpp \ 443 src/wizards/newvm/VBoxNewVMWzd.cpp \ 444 src/wizards/newhd/VBoxNewHDWzd.cpp \ 445 src/wizards/firstrun/VBoxVMFirstRunWzd.cpp \ 446 src/wizards/exportappliance/VBoxExportApplianceWzd.cpp \ 447 src/wizards/importappliance/VBoxImportApplianceWzd.cpp \ 444 src/wizards/newvm/UINewVMWzd.cpp \ 445 src/wizards/newhd/UINewHDWzd.cpp \ 446 src/wizards/firstrun/UIFirstRunWzd.cpp \ 447 src/wizards/exportappliance/UIExportApplianceWzd.cpp \ 448 src/wizards/importappliance/UIImportApplianceWzd.cpp \ 449 src/wizards/registration/UIRegistrationWzd.cpp \ 448 450 src/widgets/VBoxApplianceEditorWgt.cpp \ 449 451 src/widgets/VBoxBootTable.cpp \ -
trunk/src/VBox/Frontends/VirtualBox/VBoxUI.pro
r25171 r26079 7 7 8 8 # 9 # Copyright (C) 2006-20 07Sun Microsystems, Inc.9 # Copyright (C) 2006-2010 Sun Microsystems, Inc. 10 10 # 11 11 # This file is part of VirtualBox Open Source Edition (OSE), as … … 31 31 src/VBoxSnapshotDetailsDlg.ui \ 32 32 src/VBoxSnapshotsWgt.ui \ 33 src/VBoxRegistrationDlg.ui \34 33 src/VBoxTakeSnapshotDlg.ui \ 35 34 src/VBoxUpdateDlg.ui \ … … 54 53 src/settings/global/VBoxGLSettingsNetwork.ui \ 55 54 src/settings/global/VBoxGLSettingsNetworkDetails.ui \ 56 src/wizards/newvm/VBoxNewVMWzd.ui \ 57 src/wizards/newhd/VBoxNewHDWzd.ui \ 58 src/wizards/firstrun/VBoxVMFirstRunWzd.ui \ 59 src/wizards/exportappliance/VBoxExportApplianceWzd.ui \ 60 src/wizards/importappliance/VBoxImportApplianceWzd.ui \ 55 src/wizards/newvm/UINewVMWzdPage1.ui \ 56 src/wizards/newvm/UINewVMWzdPage2.ui \ 57 src/wizards/newvm/UINewVMWzdPage3.ui \ 58 src/wizards/newvm/UINewVMWzdPage4.ui \ 59 src/wizards/newvm/UINewVMWzdPage5.ui \ 60 src/wizards/newhd/UINewHDWzdPage1.ui \ 61 src/wizards/newhd/UINewHDWzdPage2.ui \ 62 src/wizards/newhd/UINewHDWzdPage3.ui \ 63 src/wizards/newhd/UINewHDWzdPage4.ui \ 64 src/wizards/firstrun/UIFirstRunWzdPage1.ui \ 65 src/wizards/firstrun/UIFirstRunWzdPage2.ui \ 66 src/wizards/firstrun/UIFirstRunWzdPage3.ui \ 67 src/wizards/exportappliance/UIExportApplianceWzdPage1.ui \ 68 src/wizards/exportappliance/UIExportApplianceWzdPage2.ui \ 69 src/wizards/exportappliance/UIExportApplianceWzdPage3.ui \ 70 src/wizards/exportappliance/UIExportApplianceWzdPage4.ui \ 71 src/wizards/importappliance/UIImportApplianceWzdPage1.ui \ 72 src/wizards/importappliance/UIImportApplianceWzdPage2.ui \ 73 src/wizards/registration/UIRegistrationWzdPage1.ui \ 61 74 src/widgets/VBoxApplianceEditorWgt.ui 62 75 -
trunk/src/VBox/Frontends/VirtualBox/src/VBoxConsoleWnd.cpp
r25526 r26079 6 6 7 7 /* 8 * Copyright (C) 2006-20 09Sun Microsystems, Inc.8 * Copyright (C) 2006-2010 Sun Microsystems, Inc. 9 9 * 10 10 * This file is part of VirtualBox Open Source Edition (OSE), as … … 57 57 #include "VBoxProblemReporter.h" 58 58 #include "VBoxTakeSnapshotDlg.h" 59 #include " VBoxVMFirstRunWzd.h"59 #include "UIFirstRunWzd.h" 60 60 #include "VBoxVMSettingsNetwork.h" 61 61 #include "VBoxVMSettingsSF.h" … … 1797 1797 if (mIsFirstTimeStarted) 1798 1798 { 1799 VBoxVMFirstRunWzd wzd (machine, this);1799 UIFirstRunWzd wzd (this, machine); 1800 1800 wzd.exec(); 1801 1801 -
trunk/src/VBox/Frontends/VirtualBox/src/VBoxMediaManagerDlg.cpp
r25526 r26079 6 6 7 7 /* 8 * Copyright (C) 2006-20 09Sun Microsystems, Inc.8 * Copyright (C) 2006-2010 Sun Microsystems, Inc. 9 9 * 10 10 * This file is part of VirtualBox Open Source Edition (OSE), as … … 40 40 #include "VBoxGlobal.h" 41 41 #include "VBoxMediaManagerDlg.h" 42 #include " VBoxNewHDWzd.h"42 #include "UINewHDWzd.h" 43 43 #include "VBoxProblemReporter.h" 44 44 #include "VBoxToolBar.h" … … 930 930 AssertReturnVoid (currentTreeWidgetType() == VBoxDefs::MediumType_HardDisk); 931 931 932 VBoxNewHDWzd dlg (this);932 UINewHDWzd dlg (this); 933 933 934 934 if (dlg.exec() == QDialog::Accepted) -
trunk/src/VBox/Frontends/VirtualBox/src/VBoxSelectorWnd.cpp
r25526 r26079 6 6 7 7 /* 8 * Copyright (C) 2006-20 09Sun Microsystems, Inc.8 * Copyright (C) 2006-2010 Sun Microsystems, Inc. 9 9 * 10 10 * This file is part of VirtualBox Open Source Edition (OSE), as … … 31 31 32 32 #include "VBoxSnapshotsWgt.h" 33 #include " VBoxNewVMWzd.h"33 #include "UINewVMWzd.h" 34 34 #include "VBoxMediaManagerDlg.h" 35 #include " VBoxImportApplianceWzd.h"36 #include " VBoxExportApplianceWzd.h"35 #include "UIImportApplianceWzd.h" 36 #include "UIExportApplianceWzd.h" 37 37 #include "VBoxSettingsDialogSpecific.h" 38 38 #include "VBoxVMLogViewer.h" … … 770 770 void VBoxSelectorWnd::fileImportAppliance() 771 771 { 772 VBoxImportApplianceWzd wzd (this);772 UIImportApplianceWzd wzd (this); 773 773 774 774 wzd.exec(); … … 783 783 name = item->name(); 784 784 785 VBoxExportApplianceWzd wzd (this, name);785 UIExportApplianceWzd wzd (this, name); 786 786 787 787 wzd.exec(); … … 820 820 void VBoxSelectorWnd::vmNew() 821 821 { 822 VBoxNewVMWzd wzd (this);822 UINewVMWzd wzd (this); 823 823 if (wzd.exec() == QDialog::Accepted) 824 824 { -
trunk/src/VBox/Frontends/VirtualBox/src/VBoxUpdateDlg.cpp
r25526 r26079 6 6 7 7 /* 8 * Copyright (C) 2006-20 08Sun Microsystems, Inc.8 * Copyright (C) 2006-2010 Sun Microsystems, Inc. 9 9 * 10 10 * This file is part of VirtualBox Open Source Edition (OSE), as … … 22 22 23 23 #ifdef VBOX_WITH_PRECOMPILED_HEADERS 24 # include "precomp.h" 25 #else /* !VBOX_WITH_PRECOMPILED_HEADERS */ 26 /* Common includes */ 24 #include "precomp.h" 25 #else /* !VBOX_WITH_PRECOMPILED_HEADERS */ 26 /* Global includes */ 27 #include <QTimer> 28 /* Local includes */ 27 29 #include "QIHttp.h" 28 30 #include "VBoxGlobal.h" 29 31 #include "VBoxProblemReporter.h" 30 32 #include "VBoxUpdateDlg.h" 31 32 /* Qt includes */33 #include <QTimer>34 33 #endif /* !VBOX_WITH_PRECOMPILED_HEADERS */ 35 36 34 37 35 /* VBoxVersion stuff */ … … 71 69 }; 72 70 73 74 71 /* VBoxUpdateData stuff */ 75 72 QList <UpdateDay> VBoxUpdateData::mDayList = QList <UpdateDay>(); … … 193 190 mDate = date.isValid() ? date : QDate::currentDate(); 194 191 } 195 192 196 193 /* Parse 'branch' value */ 197 194 if (parser.size() > 2) … … 237 234 } 238 235 239 240 236 /* VBoxUpdateDlg stuff */ 241 237 bool VBoxUpdateDlg::isNecessary() … … 248 244 249 245 VBoxUpdateDlg::VBoxUpdateDlg (VBoxUpdateDlg **aSelf, bool aForceRun, QWidget *aParent) 250 : QIWithRetranslateUI <Q IAbstractWizard> (aParent)246 : QIWithRetranslateUI <QDialog> (aParent) 251 247 , mSelf (aSelf) 252 248 , mUrl ("http://update.virtualbox.org/query.php") … … 264 260 ":/refresh_32px.png", ":/refresh_16px.png")); 265 261 266 /* Initialize wizard hdr */267 initializeWizardHdr();268 269 262 /* Setup other connections */ 270 263 connect (mBtnCheck, SIGNAL (clicked()), this, SLOT (search())); 271 272 /* Initialize wizard hdr */273 initializeWizardFtr();274 264 275 265 /* Setup initial condition */ … … 339 329 newData.data()); 340 330 341 Q IAbstractWizard::accept();331 QDialog::accept(); 342 332 } 343 333 … … 356 346 /* Compose query */ 357 347 QUrl url (mUrl); 358 url.addQueryItem ("platform", vboxGlobal().virtualBox().GetPackageType()); 348 url.addQueryItem ("platform", vboxGlobal().virtualBox().GetPackageType()); 359 349 /* Branding: Check whether we have a local branding file which tells us our version suffix "FOO" 360 350 (e.g. 3.06.54321_FOO) to identify this installation */ 361 351 if (vboxGlobal().brandingIsActive()) 362 { 352 { 363 353 url.addQueryItem ("version", QString ("%1_%2_%3").arg (vboxGlobal().virtualBox().GetVersion()) 364 354 .arg (vboxGlobal().virtualBox().GetRevision()) … … 454 444 } 455 445 456 void VBoxUpdateDlg::onPageShow()457 {458 if (mPageStack->currentWidget() == mPageUpdate)459 mBtnCheck->setFocus();460 else461 mBtnFinish->setFocus();462 }463 464 446 void VBoxUpdateDlg::abortRequest (const QString &aReason) 465 447 { -
trunk/src/VBox/Frontends/VirtualBox/src/VBoxUpdateDlg.h
r25171 r26079 6 6 7 7 /* 8 * Copyright (C) 2006-20 08Sun Microsystems, Inc.8 * Copyright (C) 2006-2010 Sun Microsystems, Inc. 9 9 * 10 10 * This file is part of VirtualBox Open Source Edition (OSE), as … … 24 24 #define __VBoxUpdateDlg_h__ 25 25 26 #include "QIAbstractWizard.h" 26 /* Global includes */ 27 #include <QUrl> 28 #include <QDate> 29 30 /* Local includes */ 27 31 #include "QIWithRetranslateUI.h" 28 32 #include "VBoxUpdateDlg.gen.h" 29 33 30 /* Qt includes */ 31 #include <QUrl> 32 #include <QDate> 33 34 /* Global forwards */ 34 35 class QIHttp; 35 36 … … 111 112 }; 112 113 113 class VBoxUpdateDlg : public QIWithRetranslateUI <Q IAbstractWizard>,114 class VBoxUpdateDlg : public QIWithRetranslateUI <QDialog>, 114 115 public Ui::VBoxUpdateDlg 115 116 { … … 135 136 void accept(); 136 137 void searchResponse (bool aError); 137 void onPageShow();138 138 139 139 private: -
trunk/src/VBox/Frontends/VirtualBox/src/extensions/QIAdvancedSlider.h
r25177 r26079 6 6 7 7 /* 8 * Copyright (C) 2009 Sun Microsystems, Inc.8 * Copyright (C) 2009-2010 Sun Microsystems, Inc. 9 9 * 10 10 * This file is part of VirtualBox Open Source Edition (OSE), as … … 32 32 { 33 33 Q_OBJECT; 34 Q_PROPERTY(int value READ value WRITE setValue); 34 35 35 36 public: -
trunk/src/VBox/Frontends/VirtualBox/src/extensions/QIWizard.cpp
r25432 r26079 2 2 * 3 3 * VBox frontends: Qt4 GUI ("VirtualBox"): 4 * QI AbstractWizard class implementation4 * QIWizard class implementation 5 5 */ 6 6 7 7 /* 8 * Copyright (C) 200 6-2008Sun Microsystems, Inc.8 * Copyright (C) 2009-2010 Sun Microsystems, Inc. 9 9 * 10 10 * This file is part of VirtualBox Open Source Edition (OSE), as … … 21 21 */ 22 22 23 #include "QIAbstractWizard.h" 23 /* Global includes */ 24 #include <QLayout> 25 #include <QTextEdit> 26 27 /* Local includes */ 28 #include "QIWizard.h" 24 29 #include "QILabel.h" 25 30 26 /* Qt includes */ 27 #include <QStackedWidget> 28 #include <QPushButton> 29 #include <QScrollBar> 30 #include <VBoxGlobal.h> 31 /* System includes */ 32 #include <math.h> 31 33 32 QITextEdit::QITextEdit (QWidget *aParent) 33 : QTextEdit (aParent) 34 { 35 /* Disable the background painting of the editor widget. */ 36 viewport()->setAutoFillBackground (false); 37 /* Make editor readonly by default. */ 38 setReadOnly (true); 39 } 40 41 QSize QITextEdit::sizeHint() const 42 { 43 /* If there is an updated sizeHint() present - using it. */ 44 return mOwnSizeHint.isValid() ? mOwnSizeHint : QTextEdit::sizeHint(); 45 } 46 47 QSize QITextEdit::minimumSizeHint() const 48 { 49 /* Viewer should not influent layout if there is no text. */ 50 return QSize (0, 0); 51 } 52 53 void QITextEdit::updateSizeHint() 54 { 55 if (document()) 56 { 57 int w = (int)document()->size().width(); 58 int h = (int)document()->size().height() + 2; 59 if (horizontalScrollBar()->isVisible()) 60 h += horizontalScrollBar()->height(); 61 mOwnSizeHint = QSize (w, h); 62 } 63 updateGeometry(); 64 } 65 66 void QITextEdit::setText (const QString &aText) 67 { 68 QTextEdit::setText (aText); 69 updateSizeHint(); 70 } 71 72 73 QIAbstractWizard::QIAbstractWizard (QWidget *aParent, 74 Qt::WindowFlags aFlags) 75 : QDialog (aParent, aFlags) 76 , mStackedWidget (0) 77 , mFinishButton (0) 34 QIWizard::QIWizard(QWidget *pParent) : QIWithRetranslateUI<QWizard>(pParent) 78 35 { 79 36 } 80 37 81 void QI AbstractWizard::initializeWizardHdr()38 void QIWizard::resizeToGoldenRatio() 82 39 { 83 /* Search for widget stack of inherited dialog. 84 * Please note what widget stack should have objectName() 85 * equal "mPageStack". */ 86 mStackedWidget = findChild<QStackedWidget*> ("mPageStack"); 87 Assert (mStackedWidget); 88 connect (mStackedWidget, SIGNAL (currentChanged (int)), 89 this, SLOT (onPageShow())); 90 mStackedWidget->setCurrentIndex (0); 40 /* Random initial QILabel width() to be adjusted! */ 41 int iLabelsWidth = 400; 42 resizeAccordingLabelWidth(iLabelsWidth); 91 43 92 /* Assigning all next buttons of inherited dialog. 93 * Please note what all next buttons should have objectName() 94 * matching mBtnNext<number> rule. */ 95 for (int i = 0; i < mStackedWidget->count() - 1; ++ i) 44 /* Label delta for 'golden ratio' calculation. */ 45 int iLabelDelta = width() - iLabelsWidth; 46 47 /* Calculating nearest 'golden ratio' width. */ 48 int iGoldRatioWidth = sqrt(1.61 * width() * height()); 49 int iNewLabelWidth = iGoldRatioWidth - iLabelDelta; 50 resizeAccordingLabelWidth(iNewLabelWidth); 51 } 52 53 void QIWizard::assignWatermark(const QString &strWatermark) 54 { 55 /* Create initial watermark. */ 56 QPixmap pixWaterMark(strWatermark); 57 58 /* Convert watermark to image which 59 * allows to manage pixel data directly. */ 60 QImage imgWatermark = pixWaterMark.toImage(); 61 62 /* Create final image on the basis of incoming, applying the rules. */ 63 QImage imgWatermarkNew(imgWatermark.width(), qMax(imgWatermark.height(), height()), imgWatermark.format()); 64 for (int y = 0; y < imgWatermarkNew.height(); ++ y) 96 65 { 97 QWidget *page = mStackedWidget->widget (i); 98 QList<QPushButton*> list = 99 page->findChildren<QPushButton*> (QRegExp ("mBtnNext\\d*")); 100 Assert (list.count() <= 1); 101 if (list.count() == 1) 66 for (int x = 0; x < imgWatermarkNew.width(); ++ x) 102 67 { 103 connect (list [0], SIGNAL (clicked()), this, SLOT (showNextPage())); 104 mNextButtons << list [0]; 68 /* Border rule 1 - draw border for ClassicStyle */ 69 if (wizardStyle() == QWizard::ClassicStyle && 70 (x == 0 || y == 0 || x == imgWatermarkNew.width() - 1 || y == imgWatermarkNew.height() - 1)) 71 imgWatermarkNew.setPixel(x, y, qRgb(0, 0, 0)); 72 /* Border rule 2 - draw border for ModernStyle */ 73 else if (wizardStyle() == QWizard::ModernStyle && x == imgWatermarkNew.width() - 1) 74 imgWatermarkNew.setPixel(x, y, qRgb(0, 0, 0)); 75 /* Horizontal extension rule - use last used color */ 76 else if (x >= imgWatermark.width() && y < imgWatermark.height()) 77 imgWatermarkNew.setPixel(x, y, imgWatermark.pixel(imgWatermark.width() - 1, y)); 78 /* Vertical extension rule - use last used color */ 79 else if (y >= imgWatermark.height() && x < imgWatermark.width()) 80 imgWatermarkNew.setPixel(x, y, imgWatermark.pixel(x, imgWatermark.height() - 1)); 81 /* Common extension rule - use last used color */ 82 else if (x >= imgWatermark.width() && y >= imgWatermark.height()) 83 imgWatermarkNew.setPixel(x, y, imgWatermark.pixel(imgWatermark.width() - 1, imgWatermark.height() - 1)); 84 /* Else just copy color */ 85 else 86 imgWatermarkNew.setPixel(x, y, imgWatermark.pixel(x, y)); 105 87 } 106 88 } 107 89 108 /* Assigning all back buttons of inherited dialog. 109 * Please note what all back buttons should have objectName() 110 * matching mBtnBack<number> rule. */ 111 for (int i = 0; i < mStackedWidget->count(); ++ i) 90 /* Convert processed image to pixmap and assign it to wizard's watermark. */ 91 QPixmap pixWatermarkNew = QPixmap::fromImage(imgWatermarkNew); 92 setPixmap(QWizard::WatermarkPixmap, pixWatermarkNew); 93 } 94 95 void QIWizard::resizeAccordingLabelWidth(int iLabelsWidth) 96 { 97 /* Update QILabels size-hints */ 98 QList<QILabel*> labels = findChildren<QILabel*>(); 99 foreach (QILabel *pLabel, labels) 112 100 { 113 QWidget *page = mStackedWidget->widget (i); 114 QList<QPushButton*> list = 115 page->findChildren<QPushButton*> (QRegExp ("mBtnBack\\d*")); 116 Assert (list.count() <= 1); 117 if (list.count() == 1) 118 { 119 connect (list [0], SIGNAL (clicked()), this, SLOT (showBackPage())); 120 mBackButtons << list [0]; 121 } 101 pLabel->useSizeHintForWidth(iLabelsWidth); 102 pLabel->updateGeometry(); 122 103 } 123 104 124 /* Assigning all cancel buttons of inherited dialog. 125 * Please note what all cancel buttons should have objectName() 126 * matching mBtnCancel<number> rule. */ 127 for (int i = 0; i < mStackedWidget->count(); ++ i) 105 /* Unfortunately QWizard hides some of useful API in private part, 106 * BUT it also have few layouting bugs which could be easy fixed 107 * by that API, so we will use QWizard::restart() method 108 * to call the same functionality indirectly... 109 * Early call restart() which is usually goes on show()! */ 110 restart(); 111 112 /* Now we have correct size-hints calculated for all the pages. 113 * We have to make sure all the pages uses maximum size-hint 114 * of all the available. */ 115 QSize maxOfSizeHints; 116 QList<QIWizardPage*> pages = findChildren<QIWizardPage*>(); 117 /* Search for the maximum available size-hint */ 118 foreach (QIWizardPage *pPage, pages) 128 119 { 129 QWidget *page = mStackedWidget->widget (i); 130 QList<QPushButton*> list = 131 page->findChildren<QPushButton*> (QRegExp ("mBtnCancel\\d*")); 132 Assert (list.count() <= 1); 133 if (list.count() == 1) 134 { 135 connect (list [0], SIGNAL (clicked()), this, SLOT (reject())); 136 mCancelButtons << list [0]; 137 } 120 maxOfSizeHints.rwidth() = pPage->sizeHint().width() > maxOfSizeHints.width() ? 121 pPage->sizeHint().width() : maxOfSizeHints.width(); 122 maxOfSizeHints.rheight() = pPage->sizeHint().height() > maxOfSizeHints.height() ? 123 pPage->sizeHint().height() : maxOfSizeHints.height(); 124 } 125 /* Use that size-hint for all the pages */ 126 foreach (QIWizardPage *pPage, pages) 127 { 128 pPage->setMinimumSizeHint(maxOfSizeHints); 129 pPage->updateGeometry(); 138 130 } 139 131 140 /* Assigning finish button of inherited dialog. 141 * Please note what finish button should have objectName() 142 * matching mBtnFinish. */ 143 mFinishButton = findChild<QPushButton*> ("mBtnFinish"); 144 Assert (mFinishButton); 145 connect (mFinishButton, SIGNAL (clicked()), this, SLOT (accept())); 132 /* Reactivate layouts tree */ 133 QList<QLayout*> layouts = findChildren<QLayout*>(); 134 foreach (QLayout *pLayout, layouts) 135 pLayout->activate(); 146 136 147 /* Decorating all wizard logo images of inherited dialog. 148 * Please note what all logo images should have objectName() 149 * matching mLogo<subname> rule. */ 150 QList<QLabel*> logoImages = 151 findChildren<QLabel*> (QRegExp ("mLogo.+")); 152 Assert (logoImages.count()); 153 for (int i = 0; i < logoImages.count(); ++ i) 154 VBoxGlobal::adoptLabelPixmap (logoImages [i]); 137 /* Unfortunately QWizard hides some of useful API in private part, 138 * BUT it also have few layouting bugs which could be easy fixed 139 * by that API, so we will use QWizard::restart() method 140 * to call the same functionality indirectly... 141 * And now we call restart() after layout update procedure! */ 142 restart(); 155 143 156 #ifdef Q_WS_MAC 157 /* On the Mac we need at least a size of 14 points. */ 158 QList<QLabel*> pageHeaders = 159 findChildren<QLabel*> (QRegExp ("m.+Hdr")); 160 for (int i = 0; i < pageHeaders.count(); ++i) 161 { 162 QLabel *lb = pageHeaders [i]; 163 QFont f = lb->font(); 164 f.setPointSize (14); 165 lb->setFont (f); 166 } 167 #endif /* Q_WS_MAC */ 144 /* Resize to minimum possible size */ 145 resize(minimumSizeHint()); 168 146 } 169 147 170 void QIAbstractWizard::initializeWizardFtr()148 QIWizardPage::QIWizardPage() 171 149 { 172 /* Update sizeHint() of all text labels of inherited dialog.173 * Please note what all text labels should have objectName()174 * matching mText<subname> rule. */175 QList<QILabel*> textLabels =176 findChildren<QILabel*> (QRegExp ("mText.+"));177 for (int i = 0; i < textLabels.count(); ++ i)178 textLabels [i]->useSizeHintForWidth (400);179 180 /* Update sizeHint() of summary viewer of inherited dialog.181 * Please note what summary viewer should have objectName()182 * matching mTeSummary. */183 QITextEdit *teSummary = findChild<QITextEdit*> ("mTeSummary");184 if (teSummary)185 {186 teSummary->setMinimumWidth (400);187 teSummary->updateSizeHint();188 }189 150 } 190 151 191 Q PushButton* QIAbstractWizard::nextButton (QWidget *aOfPage)152 QSize QIWizardPage::minimumSizeHint() const 192 153 { 193 return getButton (aOfPage ? aOfPage : mStackedWidget->currentWidget(), 194 "mBtnNext\\d*"); 154 return m_MinimumSizeHint.isValid() ? m_MinimumSizeHint : QWizardPage::minimumSizeHint(); 195 155 } 196 156 197 QPushButton* QIAbstractWizard::backButton (QWidget *aOfPage)157 void QIWizardPage::setMinimumSizeHint(const QSize &minimumSizeHint) 198 158 { 199 return getButton (aOfPage ? aOfPage : mStackedWidget->currentWidget(), 200 "mBtnBack\\d*"); 159 m_MinimumSizeHint = minimumSizeHint; 201 160 } 202 161 203 QPushButton* QIAbstractWizard::cancelButton (QWidget *aOfPage)162 void QIWizardPage::setSummaryFieldLinesNumber(QTextEdit *pSummaryField, int iNumber) 204 163 { 205 return getButton (aOfPage ? aOfPage : mStackedWidget->currentWidget(), 206 "mBtnCancel\\d*"); 164 /* Set the minimum height for the <pSummaryField> to <iNumber> lines of text including text margins */ 165 int lineHeight = pSummaryField->fontMetrics().height(); 166 int textMargin = 4; /* QTextDocument::documentMargin() returns '4' but available only since Qt 4.5 */ 167 pSummaryField->setFixedHeight(lineHeight * iNumber + textMargin * 2); 207 168 } 208 209 QPushButton* QIAbstractWizard::finishButton()210 {211 return getButton (mStackedWidget->widget (mStackedWidget->count() - 1),212 "mBtnFinish");213 }214 215 void QIAbstractWizard::showEvent (QShowEvent *aEvent)216 {217 QDialog::showEvent (aEvent);218 219 resize (minimumSize());220 221 onPageShow();222 223 VBoxGlobal::centerWidget (this, parentWidget());224 }225 226 void QIAbstractWizard::showNextPage()227 {228 /* Switch to the next page */229 mStackedWidget->setCurrentIndex (nextButtonIndex (nextButton()) + 1);230 }231 232 void QIAbstractWizard::showBackPage()233 {234 /* Switch to the previous page */235 mStackedWidget->setCurrentIndex (backButtonIndex (backButton()) - 1);236 }237 238 int QIAbstractWizard::nextButtonIndex (QPushButton *aNextButton)239 {240 return mNextButtons.indexOf (aNextButton);241 }242 243 int QIAbstractWizard::backButtonIndex (QPushButton *aBackButton)244 {245 return mBackButtons.indexOf (aBackButton);246 }247 248 QPushButton* QIAbstractWizard::getButton (QWidget *aOfPage,249 const QString &aRegExp)250 {251 Assert (aOfPage && !aRegExp.isNull());252 QList<QPushButton*> buttonsList =253 aOfPage->findChildren<QPushButton*> (QRegExp (aRegExp));254 Assert (buttonsList.count() == 1);255 return buttonsList [0];256 }257 -
trunk/src/VBox/Frontends/VirtualBox/src/extensions/QIWizard.h
r25432 r26079 2 2 * 3 3 * VBox frontends: Qt4 GUI ("VirtualBox"): 4 * QI AbstractWizard class declaration4 * QIWizard class declaration 5 5 */ 6 6 7 7 /* 8 * Copyright (C) 200 6-2008Sun Microsystems, Inc.8 * Copyright (C) 2009-2010 Sun Microsystems, Inc. 9 9 * 10 10 * This file is part of VirtualBox Open Source Edition (OSE), as … … 21 21 */ 22 22 23 #ifndef __QI AbstractWizard_h__24 #define __QI AbstractWizard_h__23 #ifndef __QIWizard_h__ 24 #define __QIWizard_h__ 25 25 26 /* Qt includes */ 27 #include <QTextEdit> 28 #include <QLabel> 29 #include <QDialog> 26 /* Global includes */ 27 #include <QWizard> 30 28 31 class QStackedWidget; 29 /* Local includes */ 30 #include "QIWithRetranslateUI.h" 32 31 33 /** 34 * QTextEdit reimplementation used as summary viewer in different wizards: 35 * 1. Enforces parent layout to ignore viewer if there is no text. 36 * 2. Updates sizeHint() & geometry after setting new text for getting 37 * more compact layout. 38 * 3. Tries to take into account horizontal scrollbar if present to avoid 39 * vertical scrollbar appearing. 40 * 4. Makes the paper color similar to the background color. 41 */ 42 class QITextEdit : public QTextEdit 32 /* Global forwards */ 33 class QTextEdit; 34 35 class QIWizard : public QIWithRetranslateUI<QWizard> 43 36 { 44 37 Q_OBJECT; … … 46 39 public: 47 40 48 QI TextEdit (QWidget *aParent);41 QIWizard(QWidget *pParent); 49 42 50 QSize sizeHint() const; 51 QSize minimumSizeHint() const; 52 void updateSizeHint(); 43 protected: 53 44 54 public slots: 55 56 void setText (const QString &aText); 45 void resizeToGoldenRatio(); 46 void assignWatermark(const QString &strWaterMark); 57 47 58 48 private: 59 49 60 QSize mOwnSizeHint;50 void resizeAccordingLabelWidth(int iLabelWidth); 61 51 }; 62 52 63 /** 64 * QLabel reimplementation used as text viewers in different wizards: 65 * 1. Updates sizeHint() on request to feat some minimum width 66 * for getting more compact layout. 67 * 2. Tries to take into account horizontal scrollbar if present to avoid 68 * vertical scrollbar appearing. 69 * 70 * --> uses now global QILabel 71 */ 72 73 /** 74 * QDialog reimplementation used as abstract interface in different wizards: 75 * 1. Performs most of initializations for inherited wizards including 76 * next, back, cancel, finish buttons, icons and text labels. 77 * 2. Handles show event common for all wizards. 78 */ 79 class QIAbstractWizard : public QDialog 53 class QIWizardPage : public QIWithRetranslateUI<QWizardPage> 80 54 { 81 55 Q_OBJECT; … … 83 57 public: 84 58 85 QIAbstractWizard (QWidget *aParent = 0, Qt::WindowFlags aFlags = 0); 59 QIWizardPage(); 60 61 QSize minimumSizeHint() const; 62 void setMinimumSizeHint(const QSize &minimumSizeHint); 86 63 87 64 protected: 88 65 89 void initializeWizardHdr(); 90 void initializeWizardFtr(); 91 92 QPushButton* nextButton (QWidget *aOfPage = 0); 93 QPushButton* backButton (QWidget *aOfPage = 0); 94 QPushButton* cancelButton (QWidget *aOfPage = 0); 95 QPushButton* finishButton(); 96 97 void showEvent (QShowEvent *aEvent); 98 99 protected slots: 100 101 virtual void showNextPage(); 102 virtual void showBackPage(); 103 virtual void onPageShow() = 0; 66 static void setSummaryFieldLinesNumber(QTextEdit *pSummaryField, int iNumber); 104 67 105 68 private: 106 69 107 int nextButtonIndex (QPushButton *aNextButton); 108 int backButtonIndex (QPushButton *aBackButton); 109 QPushButton* getButton (QWidget *aOfPage, const QString &aRegExp); 110 111 QStackedWidget *mStackedWidget; 112 QList<QPushButton*> mNextButtons; 113 QList<QPushButton*> mBackButtons; 114 QList<QPushButton*> mCancelButtons; 115 QPushButton *mFinishButton; 70 QSize m_MinimumSizeHint; 116 71 }; 117 72 118 #endif // __QIAbstractWizard_h__ 119 73 #endif // __QIWizard_h__ -
trunk/src/VBox/Frontends/VirtualBox/src/globals/VBoxGlobal.cpp
r26068 r26079 6 6 7 7 /* 8 * Copyright (C) 200 8-2009Sun Microsystems, Inc.8 * Copyright (C) 2006-2010 Sun Microsystems, Inc. 9 9 * 10 10 * This file is part of VirtualBox Open Source Edition (OSE), as … … 34 34 35 35 #ifdef VBOX_WITH_REGISTRATION 36 #include " VBoxRegistrationDlg.h"36 #include "UIRegistrationWzd.h" 37 37 #endif 38 38 #include "VBoxUpdateDlg.h" … … 2866 2866 } 2867 2867 2868 /**2869 * Sets the QLabel background and frame colors according tho the pixmap2870 * contents. The bottom right pixel of the label pixmap defines the2871 * background color of the label, the top right pixel defines the color of2872 * the one-pixel frame around it. This function also sets the alignment of2873 * the pixmap to AlignVTop (to correspond to the color choosing logic).2874 *2875 * This method is useful to provide nice scaling of pixmal labels without2876 * scaling pixmaps themselves. To see th eeffect, the size policy of the2877 * label in the corresponding direction (vertical, for now) should be set to2878 * something like MinimumExpanding.2879 *2880 * @todo Parametrize corners to select pixels from and set the alignment2881 * accordingly.2882 */2883 /* static */2884 void VBoxGlobal::adoptLabelPixmap (QLabel *aLabel)2885 {2886 AssertReturnVoid (aLabel);2887 2888 aLabel->setAlignment (Qt::AlignTop);2889 aLabel->setFrameShape (QFrame::Box);2890 aLabel->setFrameShadow (QFrame::Plain);2891 2892 const QPixmap *pix = aLabel->pixmap();2893 QImage img = pix->toImage();2894 QRgb rgbBack = img.pixel (img.width() - 1, img.height() - 1);2895 QRgb rgbFrame = img.pixel (img.width() - 1, 0);2896 2897 QPalette pal = aLabel->palette();2898 pal.setColor (QPalette::Window, rgbBack);2899 pal.setColor (QPalette::WindowText, rgbFrame);2900 aLabel->setPalette (pal);2901 }2902 2903 2868 const char *gVBoxLangSubDir = "/nls"; 2904 2869 const char *gVBoxLangFileBase = "VirtualBox_"; … … 4330 4295 { 4331 4296 #ifdef VBOX_WITH_REGISTRATION 4332 if (!aForce && ! VBoxRegistrationDlg::hasToBeShown())4297 if (!aForce && !UIRegistrationWzd::hasToBeShown()) 4333 4298 return; 4334 4299 … … 4354 4319 { 4355 4320 /* We've got the "mutex", create a new registration dialog */ 4356 VBoxRegistrationDlg *dlg = 4357 new VBoxRegistrationDlg (&mRegDlg, mMainWindow); 4321 UIRegistrationWzd *dlg = new UIRegistrationWzd (&mRegDlg); 4358 4322 dlg->setAttribute (Qt::WA_DeleteOnClose); 4359 4323 Assert (dlg == mRegDlg); -
trunk/src/VBox/Frontends/VirtualBox/src/globals/VBoxGlobal.h
r26068 r26079 6 6 7 7 /* 8 * Copyright (C) 2006-20 09Sun Microsystems, Inc.8 * Copyright (C) 2006-2010 Sun Microsystems, Inc. 9 9 * 10 10 * This file is part of VirtualBox Open Source Edition (OSE), as … … 274 274 class VBoxSelectorWnd; 275 275 class VBoxConsoleWnd; 276 class VBoxRegistrationDlg;276 class UIRegistrationWzd; 277 277 class VBoxUpdateDlg; 278 278 … … 728 728 729 729 static bool isDOSType (const QString &aOSTypeId); 730 731 static void adoptLabelPixmap (QLabel *);732 730 733 731 static QString languageId(); … … 902 900 903 901 #ifdef VBOX_WITH_REGISTRATION 904 VBoxRegistrationDlg*mRegDlg;902 UIRegistrationWzd *mRegDlg; 905 903 #endif 906 904 VBoxUpdateDlg *mUpdDlg; -
trunk/src/VBox/Frontends/VirtualBox/src/settings/vm/VBoxVMSettingsHD.cpp
r25589 r26079 6 6 7 7 /* 8 * Copyright (C) 2006-20 09Sun Microsystems, Inc.8 * Copyright (C) 2006-2010 Sun Microsystems, Inc. 9 9 * 10 10 * This file is part of VirtualBox Open Source Edition (OSE), as … … 37 37 #include "VBoxToolBar.h" 38 38 #include "VBoxMediaManagerDlg.h" 39 #include " VBoxNewHDWzd.h"39 #include "UINewHDWzd.h" 40 40 41 41 /* String Tags */ … … 2534 2534 { 2535 2535 /* Run New HD Wizard */ 2536 VBoxNewHDWzd dlg (this);2536 UINewHDWzd dlg (this); 2537 2537 2538 2538 return dlg.exec() == QDialog::Accepted ? dlg.hardDisk().GetId() : QString(); -
trunk/src/VBox/Frontends/VirtualBox/src/widgets/VBoxOSTypeSelectorWidget.cpp
r25178 r26079 6 6 7 7 /* 8 * Copyright (C) 2008 Sun Microsystems, Inc.8 * Copyright (C) 2008-2010 Sun Microsystems, Inc. 9 9 * 10 10 * This file is part of VirtualBox Open Source Edition (OSE), as … … 39 39 , mCbFamily (new QComboBox (this)) 40 40 , mCbType (new QComboBox (this)) 41 , mPolished (false)42 41 , mLayoutPosition (-1) 43 { 42 , mLayoutActivated (false) 43 { 44 /* Register CGuestOSType type */ 45 qRegisterMetaType<CGuestOSType>(); 46 44 47 /* Setup widgets */ 45 48 mTxFamilyName->setAlignment (Qt::AlignRight); … … 121 124 } 122 125 126 void VBoxOSTypeSelectorWidget::activateLayout() 127 { 128 if (mLayoutActivated) 129 return; 130 131 mLayoutActivated = true; 132 133 /* Layouting widgets */ 134 QVBoxLayout *layout1 = new QVBoxLayout(); 135 layout1->setSpacing (0); 136 layout1->addWidget (mPxTypeIcon); 137 layout1->addStretch(); 138 139 QGridLayout *layout2 = layout() ? static_cast <QGridLayout*> (layout()) : 140 new QGridLayout (this); 141 layout2->setMargin (0); 142 int row = mLayoutPosition == -1 ? layout2->rowCount() : mLayoutPosition; 143 layout2->addWidget (mTxFamilyName, row, 0); 144 layout2->addWidget (mCbFamily, row, 1); 145 layout2->addWidget (mTxTypeName, row + 1, 0); 146 layout2->addWidget (mCbType, row + 1, 1); 147 layout2->addLayout (layout1, row, 2, 2, 1); 148 } 149 123 150 void VBoxOSTypeSelectorWidget::retranslateUi() 124 151 { … … 134 161 void VBoxOSTypeSelectorWidget::showEvent (QShowEvent *aEvent) 135 162 { 136 if (!mPolished) 137 { 138 /* Finally polishing just before first show event */ 139 mPolished = true; 140 141 /* Layouting widgets */ 142 QVBoxLayout *layout1 = new QVBoxLayout(); 143 layout1->setSpacing (0); 144 layout1->addWidget (mPxTypeIcon); 145 layout1->addStretch(); 146 147 QGridLayout *layout2 = layout() ? static_cast <QGridLayout*> (layout()) : 148 new QGridLayout (this); 149 layout2->setMargin (0); 150 int row = mLayoutPosition == -1 ? layout2->rowCount() : mLayoutPosition; 151 layout2->addWidget (mTxFamilyName, row, 0); 152 layout2->addWidget (mCbFamily, row, 1); 153 layout2->addWidget (mTxTypeName, row + 1, 0); 154 layout2->addWidget (mCbType, row + 1, 1); 155 layout2->addLayout (layout1, row, 2, 2, 1); 156 } 163 activateLayout(); /* if not yet */ 157 164 QIWithRetranslateUI <QWidget>::showEvent (aEvent); 158 165 } -
trunk/src/VBox/Frontends/VirtualBox/src/widgets/VBoxOSTypeSelectorWidget.h
r25178 r26079 6 6 7 7 /* 8 * Copyright (C) 2008 Sun Microsystems, Inc.8 * Copyright (C) 2008-2010 Sun Microsystems, Inc. 9 9 * 10 10 * This file is part of VirtualBox Open Source Edition (OSE), as … … 30 30 31 31 class QComboBox; 32 class CGuestOSType;33 32 class QLabel; 33 34 Q_DECLARE_METATYPE (CGuestOSType); 34 35 35 36 class VBoxOSTypeSelectorWidget : public QIWithRetranslateUI <QWidget> 36 37 { 37 38 Q_OBJECT; 39 Q_PROPERTY(CGuestOSType type READ type WRITE setType); 38 40 39 41 public: … … 45 47 46 48 void setLayoutPosition (int aPos); 49 void activateLayout(); 47 50 48 51 signals: … … 71 74 QMap <QString, QString> mCurrentIds; 72 75 73 bool mPolished;74 76 int mLayoutPosition; 77 bool mLayoutActivated; 75 78 }; 76 79 -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/exportappliance/UIExportApplianceWzd.cpp
r25432 r26079 2 2 * 3 3 * VBox frontends: Qt4 GUI ("VirtualBox"): 4 * VBoxExportApplianceclass implementation4 * UIExportApplianceWzd class implementation 5 5 */ 6 6 7 7 /* 8 * Copyright (C) 2009 Sun Microsystems, Inc.8 * Copyright (C) 2009-2010 Sun Microsystems, Inc. 9 9 * 10 10 * This file is part of VirtualBox Open Source Edition (OSE), as … … 21 21 */ 22 22 23 #include "VBoxExportApplianceWzd.h" 23 /* Global includes */ 24 #include <QDir> 25 26 /* Local includes */ 27 #include "UIExportApplianceWzd.h" 24 28 #include "VBoxGlobal.h" 25 #include "QIWidgetValidator.h"26 29 #include "VBoxProblemReporter.h" 27 30 28 /* Qt includes */ 29 #include <QDir> 30 31 class VMListWidgetItems: public QListWidgetItem 31 class VMListWidgetItems : public QListWidgetItem 32 32 { 33 33 public: 34 VMListWidgetItems (QPixmap &aIcon, QString &aText, QListWidget *aParent) 35 : QListWidgetItem (aIcon, aText, aParent) {} 34 35 VMListWidgetItems(QPixmap &pixIcon, QString &strText, QListWidget *pParent) 36 : QListWidgetItem(pixIcon, strText, pParent) 37 { 38 } 36 39 37 40 /* Sort like in the VM selector of the main window */ 38 bool operator< (const QListWidgetItem &aOther) const39 { 40 return text().toLower() < aOther.text().toLower();41 bool operator<(const QListWidgetItem &other) const 42 { 43 return text().toLower() < other.text().toLower(); 41 44 } 42 45 }; 43 46 44 //////////////////////////////////////////////////////////////////////////////// 45 // VBoxExportApplianceWzd 46 47 VBoxExportApplianceWzd::VBoxExportApplianceWzd (QWidget *aParent /* = NULL */, const QString& aSelectName /* = QString::null */) 48 : QIWithRetranslateUI<QIAbstractWizard> (aParent) 49 { 50 /* Apply UI decorations */ 51 Ui::VBoxExportApplianceWzd::setupUi (this); 52 53 /* Initialize wizard hdr */ 54 initializeWizardHdr(); 55 56 /* Configure the VM selector widget */ 57 mVMListWidget->setAlternatingRowColors (true); 58 mVMListWidget->setSelectionMode (QAbstractItemView::ExtendedSelection); 59 60 /* Validator for the VM selector page */ 61 mWValVMSelector = new QIWidgetValidator (mVMSelectPage, this); 62 connect (mWValVMSelector, SIGNAL (validityChanged (const QIWidgetValidator *)), 63 this, SLOT (enableNext (const QIWidgetValidator *))); 64 connect (mWValVMSelector, SIGNAL (isValidRequested (QIWidgetValidator *)), 65 this, SLOT (revalidate (QIWidgetValidator *))); 66 connect (mVMListWidget, SIGNAL (itemSelectionChanged()), 67 mWValVMSelector, SLOT (revalidate())); 68 69 /* Fill the VM selector list */ 70 addListViewVMItems (aSelectName); 71 mWValVMSelector->revalidate(); 47 UIExportApplianceWzd::UIExportApplianceWzd(QWidget *pParent, const QString &strSelectName) : QIWizard(pParent) 48 { 49 /* Create & add pages */ 50 addPage(new UIExportApplianceWzdPage1); 51 addPage(new UIExportApplianceWzdPage2); 52 addPage(new UIExportApplianceWzdPage3); 53 addPage(new UIExportApplianceWzdPage4); 54 55 /* Set 'selectedVMName' field for wizard page 1 */ 56 setField("selectedVMName", strSelectName); 57 58 /* Translate */ 59 retranslateUi(); 60 61 /* Resize to 'golden ratio' */ 62 resizeToGoldenRatio(); 63 64 /* Assign watermark */ 65 assignWatermark(":/vmw_ovf_import.png"); 66 67 /* Setup connections */ 68 connect(this, SIGNAL(currentIdChanged(int)), this, SLOT(sltCurrentIdChanged(int))); 69 AssertMsg(!field("applianceWidget").value<ExportAppliancePointer>().isNull(), 70 ("Appliance Widget Pointer is not set!\n")); 71 connect(this, SIGNAL(customButtonClicked(int)), 72 field("applianceWidget").value<ExportAppliancePointer>(), SLOT(restoreDefaults())); 73 } 74 75 void UIExportApplianceWzd::retranslateUi() 76 { 77 /* Wizard title */ 78 setWindowTitle(tr("Appliance Export Wizard")); 79 80 /* Extra buttons */ 81 setButtonText(QWizard::CustomButton1, tr("Restore Defaults")); 82 } 83 84 void UIExportApplianceWzd::sltCurrentIdChanged(int iId) 85 { 86 setOption(QWizard::HaveCustomButton1, iId == 1 /* Page #2 */); 87 } 88 89 UIExportApplianceWzdPage1::UIExportApplianceWzdPage1() 90 { 91 /* Decorate page */ 92 Ui::UIExportApplianceWzdPage1::setupUi(this); 93 94 /* Register 'selectedVMName', 'machineNames', 'machineIDs' fields! */ 95 registerField("selectedVMName", this, "selectedVMName"); 96 registerField("machineNames", this, "machineNames"); 97 registerField("machineIDs", this, "machineIDs"); 98 99 /* Configure 'VM Selector' settings */ 100 m_pVMSelector->setAlternatingRowColors(true); 101 m_pVMSelector->setSelectionMode(QAbstractItemView::ExtendedSelection); 102 103 /* Configure 'VM Selector' connections */ 104 connect(m_pVMSelector, SIGNAL(itemSelectionChanged()), this, SLOT(sltSelectedVMChanged())); 105 106 /* Fill 'VM Selector' */ 107 populateVMSelectorItems(); 108 109 /* Translate */ 110 retranslateUi(); 111 } 112 113 void UIExportApplianceWzdPage1::retranslateUi() 114 { 115 /* Translate uic generated strings */ 116 Ui::UIExportApplianceWzdPage1::retranslateUi(this); 117 118 /* Wizard page 1 title */ 119 setTitle(tr("Welcome to the Appliance Export Wizard!")); 120 } 121 122 void UIExportApplianceWzdPage1::initializePage() 123 { 124 /* Translate */ 125 retranslateUi(); 126 127 /* Choose initially selected item (if passed) */ 128 QList<QListWidgetItem*> list = m_pVMSelector->findItems(m_strSelectedVMName, Qt::MatchExactly); 129 if (list.size() > 0) 130 m_pVMSelector->setCurrentItem(list.first()); 131 } 132 133 void UIExportApplianceWzdPage1::cleanupPage() 134 { 135 /* Do NOT call superclass method, it will clean defailt (initially set) field - 'selectedVMName'! */ 136 } 137 138 bool UIExportApplianceWzdPage1::isComplete() const 139 { 140 /* There should be at least one vm selected! */ 141 return m_pVMSelector->selectedItems().size() > 0; 142 } 143 144 void UIExportApplianceWzdPage1::sltSelectedVMChanged() 145 { 146 /* Clear lists initially */ 147 m_MachineNames.clear(); 148 m_MachineIDs.clear(); 149 /* Iterate over all the selected items */ 150 foreach (QListWidgetItem *item, m_pVMSelector->selectedItems()) 151 { 152 m_MachineNames << item->text(); 153 m_MachineIDs << item->data(Qt::UserRole).toString(); 154 } 155 /* Revalidate page */ 156 emit completeChanged(); 157 } 158 159 void UIExportApplianceWzdPage1::populateVMSelectorItems() 160 { 161 /* Add all VM items into 'VM Selector' */ 162 foreach (const CMachine &m, vboxGlobal().virtualBox().GetMachines()) 163 { 164 QPixmap pixIcon; 165 QString strName; 166 QString strUuid; 167 bool bEnabled; 168 if (m.GetAccessible()) 169 { 170 pixIcon = vboxGlobal().vmGuestOSTypeIcon(m.GetOSTypeId()).scaled(16, 16, Qt::IgnoreAspectRatio, Qt::SmoothTransformation); 171 strName = m.GetName(); 172 strUuid = m.GetId(); 173 bEnabled = m.GetSessionState() == KSessionState_Closed; 174 } 175 else 176 { 177 QString settingsFile = m.GetSettingsFilePath(); 178 QFileInfo fi(settingsFile); 179 strName = fi.completeSuffix().toLower() == "xml" ? fi.completeBaseName() : fi.fileName(); 180 pixIcon = QPixmap(":/os_other.png").scaled(16, 16, Qt::IgnoreAspectRatio, Qt::SmoothTransformation); 181 bEnabled = false; 182 } 183 QListWidgetItem *item = new VMListWidgetItems(pixIcon, strName, m_pVMSelector); 184 item->setData(Qt::UserRole, strUuid); 185 if (!bEnabled) 186 item->setFlags(0); 187 m_pVMSelector->addItem(item); 188 } 189 m_pVMSelector->sortItems(); 190 } 191 192 UIExportApplianceWzdPage2::UIExportApplianceWzdPage2() 193 { 194 /* Decorate page */ 195 Ui::UIExportApplianceWzdPage2::setupUi(this); 196 197 /* Register ExportAppliancePointer class */ 198 qRegisterMetaType<ExportAppliancePointer>(); 199 200 /* Register 'applianceWidget' field! */ 201 registerField("applianceWidget", this, "applianceWidget"); 202 m_pApplianceWidget = m_pSettingsCnt; 203 204 /* Translate */ 205 retranslateUi(); 206 } 207 208 void UIExportApplianceWzdPage2::retranslateUi() 209 { 210 /* Translate uic generated strings */ 211 Ui::UIExportApplianceWzdPage2::retranslateUi(this); 212 213 /* Wizard page 2 title */ 214 setTitle(tr("Appliance Export Settings")); 215 } 216 217 void UIExportApplianceWzdPage2::initializePage() 218 { 219 /* Translate */ 220 retranslateUi(); 221 222 /* We propose a filename the first time the second page is displayed */ 223 prepareSettingsWidget(); 224 } 225 226 void UIExportApplianceWzdPage2::cleanupPage() 227 { 228 /* Do NOT call superclass method, it will clean defailt (initially set) field - 'applianceWidget'! */ 229 } 230 231 int UIExportApplianceWzdPage2::nextId() const 232 { 233 /* Skip next (3rd, storage-type) page for now! */ 234 return wizard()->page(QIWizardPage::nextId())->nextId(); 235 } 236 237 bool UIExportApplianceWzdPage2::prepareSettingsWidget() 238 { 239 CVirtualBox vbox = vboxGlobal().virtualBox(); 240 CAppliance *appliance = m_pSettingsCnt->init(); 241 bool fResult = appliance->isOk(); 242 if (fResult) 243 { 244 /* Iterate over all the selected machine ids */ 245 QStringList uuids = field("machineIDs").toStringList(); 246 foreach (const QString &uuid, uuids) 247 { 248 /* Get the machine with the uuid */ 249 CMachine m = vbox.GetMachine(uuid); 250 fResult = m.isOk(); 251 if (fResult) 252 { 253 /* Add the export description to our appliance object */ 254 CVirtualSystemDescription vsd = m.Export(*appliance); 255 fResult = m.isOk(); 256 if (!fResult) 257 { 258 vboxProblem().cannotExportAppliance(m, appliance, this); 259 return false; 260 } 261 /* Now add some new fields the user may change */ 262 vsd.AddDescription(KVirtualSystemDescriptionType_Product, "", ""); 263 vsd.AddDescription(KVirtualSystemDescriptionType_ProductUrl, "", ""); 264 vsd.AddDescription(KVirtualSystemDescriptionType_Vendor, "", ""); 265 vsd.AddDescription(KVirtualSystemDescriptionType_VendorUrl, "", ""); 266 vsd.AddDescription(KVirtualSystemDescriptionType_Version, "", ""); 267 vsd.AddDescription(KVirtualSystemDescriptionType_License, "", ""); 268 } 269 else 270 break; 271 } 272 /* Make sure the settings widget get the new descriptions */ 273 m_pSettingsCnt->populate(); 274 } 275 if (!fResult) 276 vboxProblem().cannotExportAppliance(appliance, this); 277 return fResult; 278 } 279 280 UIExportApplianceWzdPage3::UIExportApplianceWzdPage3() 281 { 282 /* Decorate page */ 283 Ui::UIExportApplianceWzdPage3::setupUi(this); 284 285 /* Register StorageType class */ 286 qRegisterMetaType<StorageType>(); 287 288 /* Register 'storageType' field! */ 289 registerField("storageType", this, "storageType"); 290 291 /* Setup connections */ 292 connect (m_pTypeLocalFilesystem, SIGNAL(clicked()), this, SLOT(sltStorageTypeChanged())); 293 connect (m_pTypeSunCloud, SIGNAL(clicked()), this, SLOT(sltStorageTypeChanged())); 294 connect (m_pTypeSimpleStorageSystem, SIGNAL(clicked()), this, SLOT(sltStorageTypeChanged())); 295 296 #if 0 297 /* Load storage-type from GUI extra data */ 298 bool ok; 299 StorageType storageType = 300 StorageType(vboxGlobal().virtualBox().GetExtraData(VBoxDefs::GUI_Export_StorageType).toInt(&ok)); 301 if (ok) 302 { 303 switch (storageType) 304 { 305 case Filesystem: 306 m_pTypeLocalFilesystem->setChecked(true); 307 m_pTypeLocalFilesystem->setFocus(); 308 break; 309 case SunCloud: 310 m_pTypeSunCloud->setChecked(true); 311 m_pTypeSunCloud->setFocus(); 312 break; 313 case S3: 314 m_pTypeSimpleStorageSystem->setChecked(true); 315 m_pTypeSimpleStorageSystem->setFocus(); 316 break; 317 } 318 } 319 #else 320 /* Just select first of types */ 321 m_pTypeLocalFilesystem->click(); 322 #endif 323 324 /* Translate */ 325 retranslateUi(); 326 } 327 328 void UIExportApplianceWzdPage3::retranslateUi() 329 { 330 /* Translate uic generated strings */ 331 Ui::UIExportApplianceWzdPage3::retranslateUi(this); 332 333 /* Wizard page 3 title */ 334 setTitle(tr("Appliance Export Settings")); 335 } 336 337 void UIExportApplianceWzdPage3::initializePage() 338 { 339 /* Translate */ 340 retranslateUi(); 341 342 /* Revert to initial choice */ 343 m_pTypeLocalFilesystem->click(); 344 } 345 346 void UIExportApplianceWzdPage3::sltStorageTypeChanged() 347 { 348 /* Update selected storage-type */ 349 if (m_pTypeLocalFilesystem->isChecked()) 350 m_StorageType = Filesystem; 351 else if (m_pTypeSunCloud->isChecked()) 352 m_StorageType = SunCloud; 353 else if (m_pTypeSimpleStorageSystem->isChecked()) 354 m_StorageType = S3; 355 else 356 m_StorageType = Filesystem; 357 /* Revalidate page */ 358 emit completeChanged(); 359 } 360 361 UIExportApplianceWzdPage4::UIExportApplianceWzdPage4() 362 { 363 /* Decorate page */ 364 Ui::UIExportApplianceWzdPage4::setupUi(this); 72 365 73 366 /* Configure the file selector */ 74 mFileSelector->setMode (VBoxFilePathSelectorWidget::Mode_File_Save); 75 mFileSelector->setEditable (true); 76 mFileSelector->setButtonPosition (VBoxEmptyFileSelector::RightPosition); 77 mFileSelector->setFileDialogTitle (tr ("Select a file to export into")); 78 mFileSelector->setFileFilters (tr ("Open Virtualization Format (%1)").arg ("*.ovf")); 79 mFileSelector->setDefaultSaveExt ("ovf"); 80 setTabOrder (mLeBucket, mFileSelector); 81 82 /* Connect the restore button with the settings widget */ 83 connect (mBtnRestore, SIGNAL (clicked()), 84 mExportSettingsWgt, SLOT (restoreDefaults())); 85 86 /* Validator for the file selector page */ 87 mWValFileSelector = new QIWidgetValidator (mTargetOptionsPage, this); 88 connect (mWValFileSelector, SIGNAL (validityChanged (const QIWidgetValidator *)), 89 this, SLOT (enableNext (const QIWidgetValidator *))); 90 connect (mWValFileSelector, SIGNAL (isValidRequested (QIWidgetValidator *)), 91 this, SLOT (revalidate (QIWidgetValidator *))); 92 connect (mFileSelector, SIGNAL (pathChanged (const QString &)), 93 mWValFileSelector, SLOT (revalidate())); 94 connect (mLeUsername, SIGNAL (textChanged (const QString &)), 95 mWValFileSelector, SLOT (revalidate())); 96 connect (mLePassword, SIGNAL (textChanged (const QString &)), 97 mWValFileSelector, SLOT (revalidate())); 98 connect (mLeHostname, SIGNAL (textChanged (const QString &)), 99 mWValFileSelector, SLOT (revalidate())); 100 connect (mLeBucket, SIGNAL (textChanged (const QString &)), 101 mWValFileSelector, SLOT (revalidate())); 102 103 // mLeUsername->setText (vboxGlobal().virtualBox().GetExtraData (VBoxDefs::GUI_Export_Username)); 104 // mLeHostname->setText (vboxGlobal().virtualBox().GetExtraData (VBoxDefs::GUI_Export_Hostname)); 105 // mLeBucket->setText (vboxGlobal().virtualBox().GetExtraData (VBoxDefs::GUI_Export_Bucket)); 106 107 mWValFileSelector->revalidate(); 108 109 /* Initialize wizard ftr */ 110 initializeWizardFtr(); 111 112 retranslateUi(); 113 114 /* Type selection is disabled for now */ 115 connect (mBtnNext2, SIGNAL (clicked(bool)), 116 mBtnNext3, SLOT (click())); 117 connect (mBtnBack4, SIGNAL (clicked(bool)), 118 mBtnBack3, SLOT (click())); 119 120 // bool ok; 121 // StorageType type = StorageType (vboxGlobal().virtualBox().GetExtraData (VBoxDefs::GUI_Export_StorageType).toInt(&ok)); 122 // if (ok) 123 // setCurrentStorageType (type); 124 } 125 126 void VBoxExportApplianceWzd::retranslateUi() 367 m_pFileSelector->setMode(VBoxFilePathSelectorWidget::Mode_File_Save); 368 m_pFileSelector->setEditable(true); 369 m_pFileSelector->setButtonPosition(VBoxEmptyFileSelector::RightPosition); 370 m_pFileSelector->setDefaultSaveExt("ovf"); 371 372 /* Complete validators for the file selector page */ 373 connect(m_pLeUsername, SIGNAL(textChanged(const QString &)), this, SIGNAL(completeChanged())); 374 connect(m_pLePassword, SIGNAL(textChanged(const QString &)), this, SIGNAL(completeChanged())); 375 connect(m_pLeHostname, SIGNAL(textChanged(const QString &)), this, SIGNAL(completeChanged())); 376 connect(m_pLeBucket, SIGNAL(textChanged(const QString &)), this, SIGNAL(completeChanged())); 377 connect(m_pFileSelector, SIGNAL(pathChanged(const QString &)), this, SIGNAL(completeChanged())); 378 379 #if 0 380 /* Load default attributes from GUI extra data */ 381 m_pLeUsername->setText(vboxGlobal().virtualBox().GetExtraData(VBoxDefs::GUI_Export_Username)); 382 m_pLeHostname->setText(vboxGlobal().virtualBox().GetExtraData(VBoxDefs::GUI_Export_Hostname)); 383 m_pLeBucket->setText(vboxGlobal().virtualBox().GetExtraData(VBoxDefs::GUI_Export_Bucket)); 384 #endif 385 386 /* Translate */ 387 retranslateUi(); 388 } 389 390 void UIExportApplianceWzdPage4::retranslateUi() 127 391 { 128 392 /* Translate uic generated strings */ 129 Ui::VBoxExportApplianceWzd::retranslateUi (this); 130 131 mDefaultApplianceName = tr("Appliance"); 132 133 mExportToFileSystemDesc = tr("Please choose a filename to export the OVF to."); 134 mExportToSunCloudDesc = tr("Please complete the additional fields like the username, password and the bucket, and provide a filename for the OVF target."); 135 mExportToS3Desc = tr("Please complete the additional fields like the username, password, hostname and the bucket, and provide a filename for the OVF target."); 136 137 switch (currentStorageType()) 138 { 139 case Filesystem: mTextTargetOptions->setText (mExportToFileSystemDesc); break; 140 case SunCloud: mTextTargetOptions->setText (mExportToSunCloudDesc); break; 141 case S3: mTextTargetOptions->setText (mExportToS3Desc); break; 142 } 143 } 144 145 void VBoxExportApplianceWzd::revalidate (QIWidgetValidator *aWval) 146 { 147 /* Do individual validations for pages */ 148 bool valid = aWval->isOtherValid(); 149 150 if (aWval == mWValVMSelector) 151 valid = mVMListWidget->selectedItems().size() > 0; 152 153 if (aWval == mWValFileSelector) 154 { 155 valid = mFileSelector->path().toLower().endsWith (".ovf"); 156 if (currentStorageType() == SunCloud) 157 { 158 valid &= !mLeUsername->text().isEmpty() && 159 !mLePassword->text().isEmpty() && 160 !mLeBucket->text().isEmpty(); 161 } 162 else if (currentStorageType() == S3) 163 { 164 valid &= !mLeUsername->text().isEmpty() && 165 !mLePassword->text().isEmpty() && 166 !mLeHostname->text().isEmpty() && 167 !mLeBucket->text().isEmpty(); 168 } 169 } 170 171 aWval->setOtherValid (valid); 172 } 173 174 void VBoxExportApplianceWzd::enableNext (const QIWidgetValidator *aWval) 175 { 176 if (aWval == mWValFileSelector) 177 finishButton()->setEnabled (aWval->isValid()); 178 else 179 nextButton (aWval->widget())->setEnabled (aWval->isValid()); 180 } 181 182 void VBoxExportApplianceWzd::accept() 183 { 184 CAppliance *appliance = mExportSettingsWgt->appliance(); 185 QFileInfo fi (mFileSelector->path()); 393 Ui::UIExportApplianceWzdPage4::retranslateUi(this); 394 395 /* Wizard page 4 title */ 396 setTitle(tr("Appliance Export Settings")); 397 398 /* Setup defaults */ 399 m_strDefaultApplianceName = tr("Appliance"); 400 401 /* Translate the file selector */ 402 m_pFileSelector->setFileDialogTitle(tr("Select a file to export into")); 403 m_pFileSelector->setFileFilters(tr("Open Virtualization Format (%1)").arg("*.ovf")); 404 } 405 406 void UIExportApplianceWzdPage4::initializePage() 407 { 408 /* Translate */ 409 retranslateUi(); 410 411 /* Setup components for chosen storage-type */ 412 StorageType storageType = field("storageType").value<StorageType>(); 413 switch (storageType) 414 { 415 case Filesystem: 416 m_pPage4Text1->setText(tr("Please choose a filename to export the OVF to.")); 417 m_pTxUsername->setVisible(false); 418 m_pLeUsername->setVisible(false); 419 m_pTxPassword->setVisible(false); 420 m_pLePassword->setVisible(false); 421 m_pTxHostname->setVisible(false); 422 m_pLeHostname->setVisible(false); 423 m_pTxBucket->setVisible(false); 424 m_pLeBucket->setVisible(false); 425 m_pSelectOVF09->setVisible(true); 426 m_pFileSelector->setChooserVisible(true); 427 m_pFileSelector->setFocus(); 428 break; 429 case SunCloud: 430 m_pPage4Text1->setText(tr("Please complete the additional fields like the username, password " 431 "and the bucket, and provide a filename for the OVF target.")); 432 m_pTxUsername->setVisible(true); 433 m_pLeUsername->setVisible(true); 434 m_pTxPassword->setVisible(true); 435 m_pLePassword->setVisible(true); 436 m_pTxHostname->setVisible(false); 437 m_pLeHostname->setVisible(false); 438 m_pTxBucket->setVisible(true); 439 m_pLeBucket->setVisible(true); 440 m_pSelectOVF09->setVisible(false); 441 m_pSelectOVF09->setChecked(false); 442 m_pFileSelector->setChooserVisible(false); 443 m_pLeUsername->setFocus(); 444 break; 445 case S3: 446 m_pPage4Text1->setText(tr("Please complete the additional fields like the username, password, " 447 "hostname and the bucket, and provide a filename for the OVF target.")); 448 m_pTxUsername->setVisible(true); 449 m_pLeUsername->setVisible(true); 450 m_pTxPassword->setVisible(true); 451 m_pLePassword->setVisible(true); 452 m_pTxHostname->setVisible(true); 453 m_pLeHostname->setVisible(true); 454 m_pTxBucket->setVisible(true); 455 m_pLeBucket->setVisible(true); 456 m_pSelectOVF09->setVisible(true); 457 m_pFileSelector->setChooserVisible(false); 458 m_pLeUsername->setFocus(); 459 break; 460 } 461 462 if (!m_pFileSelector->path().isEmpty()) 463 { 464 QFileInfo fi(m_pFileSelector->path()); 465 QString strName = fi.fileName(); 466 if (storageType == Filesystem) 467 strName = QDir::toNativeSeparators(QString("%1/%2").arg(vboxGlobal().documentsPath()).arg(strName)); 468 m_pFileSelector->setPath(strName); 469 } 470 471 if (m_pFileSelector->path().isEmpty()) 472 { 473 /* Set the default filename */ 474 QString strName = m_strDefaultApplianceName; 475 /* If it is one VM only, we use the VM name as file name */ 476 if (field("machineNames").toStringList().size() == 1) 477 strName = field("machineNames").toStringList()[0]; 478 479 strName += ".ovf"; 480 481 if (storageType == Filesystem) 482 strName = QDir::toNativeSeparators(QString("%1/%2").arg(vboxGlobal().documentsPath()).arg(strName)); 483 m_pFileSelector->setPath(strName); 484 } 485 AssertMsg(!field("applianceWidget").value<ExportAppliancePointer>().isNull(), 486 ("Appliance Widget Pointer is not set!\n")); 487 field("applianceWidget").value<ExportAppliancePointer>()->prepareExport(); 488 } 489 490 bool UIExportApplianceWzdPage4::isComplete() const 491 { 492 bool bComplete = m_pFileSelector->path().toLower().endsWith(".ovf"); 493 StorageType storageType = field("storageType").value<StorageType>(); 494 switch (storageType) 495 { 496 case Filesystem: 497 break; 498 case SunCloud: 499 bComplete &= !m_pLeUsername->text().isEmpty() && !m_pLePassword->text().isEmpty() && 500 !m_pLeBucket->text().isEmpty(); 501 break; 502 case S3: 503 bComplete &= !m_pLeUsername->text().isEmpty() && !m_pLePassword->text().isEmpty() && 504 !m_pLeHostname->text().isEmpty() && !m_pLeBucket->text().isEmpty(); 505 break; 506 } 507 return bComplete; 508 } 509 510 bool UIExportApplianceWzdPage4::validatePage() 511 { 512 return exportAppliance(); 513 } 514 515 bool UIExportApplianceWzdPage4::exportAppliance() 516 { 517 AssertMsg(!field("applianceWidget").value<ExportAppliancePointer>().isNull(), 518 ("Appliance Widget Pointer is not set!\n")); 519 CAppliance *appliance = field("applianceWidget").value<ExportAppliancePointer>()->appliance(); 520 QFileInfo fi(m_pFileSelector->path()); 186 521 QVector<QString> files; 187 522 files << fi.fileName(); … … 191 526 * HardDiskImage. */ 192 527 CVirtualSystemDescriptionVector vsds = appliance->GetVirtualSystemDescriptions(); 193 for (int i =0; i < vsds.size(); ++i)528 for (int i = 0; i < vsds.size(); ++ i) 194 529 { 195 530 QVector<KVirtualSystemDescriptionType> types; 196 531 QVector<QString> refs, origValues, configValues, extraConfigValues; 197 198 vsds[i].GetDescriptionByType (KVirtualSystemDescriptionType_HardDiskImage, types,refs, origValues, configValues, extraConfigValues);532 vsds[i].GetDescriptionByType(KVirtualSystemDescriptionType_HardDiskImage, types, 533 refs, origValues, configValues, extraConfigValues); 199 534 foreach (const QString &s, origValues) 200 files << QString ("%2").arg(s);535 files << QString("%2").arg(s); 201 536 } 202 537 CVFSExplorer explorer = appliance->CreateVFSExplorer(uri()); … … 206 541 { 207 542 /* Show some progress, so the user know whats going on */ 208 vboxProblem().showModalProgressDialog (progress, tr ("Checking files ..."), this); 209 if (progress.GetCanceled()) 210 return; 211 if (!progress.isOk() || progress.GetResultCode() != 0) 212 { 213 vboxProblem().cannotCheckFiles (progress, this); 214 return; 215 } 216 } 217 QVector<QString> exists = explorer.Exists (files); 218 /* Check if the file exists already, if yes get confirmation for 219 * overwriting from the user. */ 220 if (!vboxProblem().askForOverridingFiles (exists, this)) 221 return; 222 /* Ok all is confirmed so delete all the files which exists */ 223 if (!exists.isEmpty()) 224 { 225 CProgress progress1 = explorer.Remove (exists); 226 fResult = explorer.isOk(); 227 if (fResult) 228 { 229 /* Show some progress, so the user know whats going on */ 230 vboxProblem().showModalProgressDialog (progress1, tr ("Removing files ..."), this); 231 if (progress1.GetCanceled()) 232 return; 233 if (!progress1.isOk() || progress1.GetResultCode() != 0) 234 { 235 vboxProblem().cannotRemoveFiles (progress1, this); 236 return; 237 } 238 } 239 } 240 /* Export the VMs, on success we are finished */ 241 if (exportVMs (*appliance)) 242 { 243 // vboxGlobal().virtualBox().SetExtraData (VBoxDefs::GUI_Export_StorageType, QString::number(currentStorageType())); 244 // vboxGlobal().virtualBox().SetExtraData (VBoxDefs::GUI_Export_Username, mLeUsername->text()); 245 // vboxGlobal().virtualBox().SetExtraData (VBoxDefs::GUI_Export_Hostname, mLeHostname->text()); 246 // vboxGlobal().virtualBox().SetExtraData (VBoxDefs::GUI_Export_Bucket, mLeBucket->text()); 247 QIAbstractWizard::accept(); 248 } 249 } 250 251 void VBoxExportApplianceWzd::showNextPage() 252 { 253 /* We propose a filename the first time the second page is displayed */ 254 if (sender() == mBtnNext1) 255 { 256 prepareSettingsWidget(); 257 } 258 else if (sender() == mBtnNext3) 259 { 260 storageTypeChanged(); 261 if (mFileSelector->path().isEmpty()) 262 { 263 /* Set the default filename */ 264 QString name = mDefaultApplianceName; 265 /* If it is one VM only, we use the VM name as file name */ 266 if (mVMListWidget->selectedItems().size() == 1) 267 name = mVMListWidget->selectedItems().first()->text(); 268 269 name += ".ovf"; 270 271 if (currentStorageType() == Filesystem) 272 name = QDir::toNativeSeparators (QString ("%1/%2").arg (vboxGlobal().documentsPath()) 273 .arg (name)); 274 mFileSelector->setPath (name); 275 mWValFileSelector->revalidate(); 276 } 277 mExportSettingsWgt->prepareExport(); 278 } 279 280 QIAbstractWizard::showNextPage(); 281 } 282 283 void VBoxExportApplianceWzd::onPageShow() 284 { 285 QWidget *page = mPageStack->currentWidget(); 286 287 if (page == mTargetOptionsPage) 288 finishButton()->setDefault (true); 289 else 290 nextButton (page)->setDefault (true); 291 } 292 293 void VBoxExportApplianceWzd::addListViewVMItems (const QString& aSelectName) 294 { 295 CVirtualBox vbox = vboxGlobal().virtualBox(); 296 CMachineVector vec = vbox.GetMachines(); 297 for (CMachineVector::ConstIterator m = vec.begin(); 298 m != vec.end(); ++ m) 299 { 300 QPixmap icon; 301 QString name; 302 QString uuid; 303 bool enabled; 304 if (m->GetAccessible()) 305 { 306 icon = vboxGlobal().vmGuestOSTypeIcon (m->GetOSTypeId()).scaled (16, 16, Qt::IgnoreAspectRatio, Qt::SmoothTransformation); 307 name = m->GetName(); 308 uuid = m->GetId(); 309 enabled = m->GetSessionState() == KSessionState_Closed; 310 } 311 else 312 { 313 QString settingsFile = m->GetSettingsFilePath(); 314 QFileInfo fi (settingsFile); 315 name = fi.completeSuffix().toLower() == "xml" ? 316 fi.completeBaseName() : fi.fileName(); 317 icon = QPixmap (":/os_other.png").scaled (16, 16, Qt::IgnoreAspectRatio, Qt::SmoothTransformation); 318 enabled = false; 319 } 320 QListWidgetItem *item = new VMListWidgetItems (icon, name, mVMListWidget); 321 item->setData (Qt::UserRole, uuid); 322 if (!enabled) 323 item->setFlags (0); 324 mVMListWidget->addItem (item); 325 } 326 mVMListWidget->sortItems(); 327 328 /* Make sure aSelectName is initial selected in the list */ 329 QList<QListWidgetItem *> list = mVMListWidget->findItems (aSelectName, Qt::MatchExactly); 330 if (list.size() > 0) 331 mVMListWidget->setCurrentItem (list.first()); 332 } 333 334 bool VBoxExportApplianceWzd::prepareSettingsWidget() 335 { 336 CVirtualBox vbox = vboxGlobal().virtualBox(); 337 CAppliance *appliance = mExportSettingsWgt->init(); 338 bool fResult = appliance->isOk(); 339 if (fResult) 340 { 341 /* Iterate over all selected items */ 342 QList<QListWidgetItem *> list = mVMListWidget->selectedItems(); 343 foreach (const QListWidgetItem* item, list) 344 { 345 /* The VM uuid can be fetched by the UserRole */ 346 QString uuid = item->data (Qt::UserRole).toString(); 347 /* Get the machine with the uuid */ 348 CMachine m = vbox.GetMachine (uuid); 349 fResult = m.isOk(); 350 if (fResult) 351 { 352 /* Add the export description to our appliance object */ 353 CVirtualSystemDescription vsd = m.Export (*appliance); 354 fResult = m.isOk(); 355 if (!fResult) 356 { 357 vboxProblem().cannotExportAppliance (m, appliance, this); 358 return false; 359 } 360 /* Now add some new fields the user may change */ 361 vsd.AddDescription (KVirtualSystemDescriptionType_Product, "", ""); 362 vsd.AddDescription (KVirtualSystemDescriptionType_ProductUrl, "", ""); 363 vsd.AddDescription (KVirtualSystemDescriptionType_Vendor, "", ""); 364 vsd.AddDescription (KVirtualSystemDescriptionType_VendorUrl, "", ""); 365 vsd.AddDescription (KVirtualSystemDescriptionType_Version, "", ""); 366 vsd.AddDescription (KVirtualSystemDescriptionType_License, "", ""); 367 } 368 else 369 break; 370 } 371 /* Make sure the settings widget get the new descriptions */ 372 mExportSettingsWgt->populate(); 373 } 374 if (!fResult) 375 vboxProblem().cannotExportAppliance (appliance, this); 376 return fResult; 377 } 378 379 bool VBoxExportApplianceWzd::exportVMs (CAppliance &aAppliance) 380 { 381 /* Write the appliance */ 382 QString version = mSelectOVF09->isChecked() ? "ovf-0.9" : "ovf-1.0"; 383 CProgress progress = aAppliance.Write (version, uri()); 384 bool fResult = aAppliance.isOk(); 385 if (fResult) 386 { 387 /* Show some progress, so the user know whats going on */ 388 vboxProblem().showModalProgressDialog (progress, tr ("Exporting Appliance ..."), this); 543 vboxProblem().showModalProgressDialog(progress, tr("Checking files ..."), this); 389 544 if (progress.GetCanceled()) 390 545 return false; 391 546 if (!progress.isOk() || progress.GetResultCode() != 0) 392 547 { 393 vboxProblem().cannotExportAppliance (progress, &aAppliance, this); 548 vboxProblem().cannotCheckFiles(progress, this); 549 return false; 550 } 551 } 552 QVector<QString> exists = explorer.Exists(files); 553 /* Check if the file exists already, if yes get confirmation for overwriting from the user. */ 554 if (!vboxProblem().askForOverridingFiles(exists, this)) 555 return false; 556 /* Ok all is confirmed so delete all the files which exists */ 557 if (!exists.isEmpty()) 558 { 559 CProgress progress1 = explorer.Remove(exists); 560 fResult = explorer.isOk(); 561 if (fResult) 562 { 563 /* Show some progress, so the user know whats going on */ 564 vboxProblem().showModalProgressDialog(progress1, tr("Removing files ..."), this); 565 if (progress1.GetCanceled()) 566 return false; 567 if (!progress1.isOk() || progress1.GetResultCode() != 0) 568 { 569 vboxProblem().cannotRemoveFiles(progress1, this); 570 return false; 571 } 572 } 573 } 574 575 /* Export the VMs, on success we are finished */ 576 if (exportVMs(*appliance)) 577 { 578 #if 0 579 /* Save attributes to GUI extra data */ 580 StorageType storageType = field("storageType").value<StorageType>(); 581 vboxGlobal().virtualBox().SetExtraData(VBoxDefs::GUI_Export_StorageType, QString::number(storageType)); 582 vboxGlobal().virtualBox().SetExtraData(VBoxDefs::GUI_Export_Username, m_pLeUsername->text()); 583 vboxGlobal().virtualBox().SetExtraData(VBoxDefs::GUI_Export_Hostname, m_pLeHostname->text()); 584 vboxGlobal().virtualBox().SetExtraData(VBoxDefs::GUI_Export_Bucket, m_pLeBucket->text()); 585 #endif 586 return true; 587 } 588 return false; 589 } 590 591 bool UIExportApplianceWzdPage4::exportVMs(CAppliance &appliance) 592 { 593 /* Write the appliance */ 594 QString version = m_pSelectOVF09->isChecked() ? "ovf-0.9" : "ovf-1.0"; 595 CProgress progress = appliance.Write(version, uri()); 596 bool fResult = appliance.isOk(); 597 if (fResult) 598 { 599 /* Show some progress, so the user know whats going on */ 600 vboxProblem().showModalProgressDialog(progress, tr("Exporting Appliance ..."), this); 601 if (progress.GetCanceled()) 602 return false; 603 if (!progress.isOk() || progress.GetResultCode() != 0) 604 { 605 vboxProblem().cannotExportAppliance(progress, &appliance, this); 394 606 return false; 395 607 } … … 398 610 } 399 611 if (!fResult) 400 vboxProblem().cannotExportAppliance (&aAppliance, this);612 vboxProblem().cannotExportAppliance(&appliance, this); 401 613 return false; 402 614 } 403 615 404 QString VBoxExportApplianceWzd::uri() const 405 { 406 if (currentStorageType() == Filesystem) 407 return mFileSelector->path(); 408 else if (currentStorageType() == SunCloud) 409 { 410 QString uri ("SunCloud://"); 411 if (!mLeUsername->text().isEmpty()) 412 uri = QString ("%1%2").arg (uri).arg (mLeUsername->text()); 413 if (!mLePassword->text().isEmpty()) 414 uri = QString ("%1:%2").arg (uri).arg (mLePassword->text()); 415 if (!mLeUsername->text().isEmpty() || 416 !mLePassword->text().isEmpty()) 417 uri = QString ("%1@").arg (uri); 418 uri = QString ("%1%2/%3/%4").arg (uri).arg ("object.storage.network.com").arg (mLeBucket->text()).arg (mFileSelector->path()); 419 return uri; 420 } 421 else if (currentStorageType() == S3) 422 { 423 QString uri ("S3://"); 424 if (!mLeUsername->text().isEmpty()) 425 uri = QString ("%1%2").arg (uri).arg (mLeUsername->text()); 426 if (!mLePassword->text().isEmpty()) 427 uri = QString ("%1:%2").arg (uri).arg (mLePassword->text()); 428 if (!mLeUsername->text().isEmpty() || 429 !mLePassword->text().isEmpty()) 430 uri = QString ("%1@").arg (uri); 431 uri = QString ("%1%2/%3/%4").arg (uri).arg (mLeHostname->text()).arg (mLeBucket->text()).arg (mFileSelector->path()); 432 return uri; 433 } 434 return ""; 435 } 436 437 VBoxExportApplianceWzd::StorageType VBoxExportApplianceWzd::currentStorageType() const 438 { 439 if (mRBtnLocalFileSystem->isChecked()) 440 return Filesystem; 441 else if (mRBtnSunCloud->isChecked()) 442 return SunCloud; 443 else 444 return S3; 445 } 446 447 void VBoxExportApplianceWzd::storageTypeChanged() 448 { 449 StorageType type = currentStorageType(); 616 QString UIExportApplianceWzdPage4::uri() const 617 { 618 StorageType type = field("storageType").value<StorageType>(); 450 619 switch (type) 451 620 { 452 621 case Filesystem: 453 622 { 454 mTextTargetOptions->setText (mExportToFileSystemDesc); 455 mLblUsername->setVisible (false); 456 mLeUsername->setVisible (false); 457 mLblPassword->setVisible (false); 458 mLePassword->setVisible (false); 459 mLblHostname->setVisible (false); 460 mLeHostname->setVisible (false); 461 mLblBucket->setVisible (false); 462 mLeBucket->setVisible (false); 463 mSelectOVF09->setVisible (true); 464 mFileSelector->setChooserVisible (true); 465 mFileSelector->setFocus(); 466 break; 467 }; 623 return m_pFileSelector->path(); 624 } 468 625 case SunCloud: 469 626 { 470 mTextTargetOptions->setText (mExportToSunCloudDesc); 471 mLblUsername->setVisible (true); 472 mLeUsername->setVisible (true); 473 mLblPassword->setVisible (true); 474 mLePassword->setVisible (true); 475 mLblHostname->setVisible (false); 476 mLeHostname->setVisible (false); 477 mLblBucket->setVisible (true); 478 mLeBucket->setVisible (true); 479 mSelectOVF09->setVisible (false); 480 mSelectOVF09->setChecked (false); 481 mFileSelector->setChooserVisible (false); 482 mLeUsername->setFocus(); 483 break; 484 }; 627 QString uri("SunCloud://"); 628 if (!m_pLeUsername->text().isEmpty()) 629 uri = QString("%1%2").arg(uri).arg(m_pLeUsername->text()); 630 if (!m_pLePassword->text().isEmpty()) 631 uri = QString("%1:%2").arg(uri).arg(m_pLePassword->text()); 632 if (!m_pLeUsername->text().isEmpty() || !m_pLePassword->text().isEmpty()) 633 uri = QString("%1@").arg(uri); 634 uri = QString("%1%2/%3/%4").arg(uri).arg("object.storage.network.com").arg(m_pLeBucket->text()).arg(m_pFileSelector->path()); 635 return uri; 636 } 485 637 case S3: 486 638 { 487 mTextTargetOptions->setText (mExportToS3Desc); 488 mLblUsername->setVisible (true); 489 mLeUsername->setVisible (true); 490 mLblPassword->setVisible (true); 491 mLePassword->setVisible (true); 492 mLblHostname->setVisible (true); 493 mLeHostname->setVisible (true); 494 mLblBucket->setVisible (true); 495 mLeBucket->setVisible (true); 496 mSelectOVF09->setVisible (true); 497 mFileSelector->setChooserVisible (false); 498 mLeUsername->setFocus(); 499 break; 500 }; 501 } 502 503 if (!mFileSelector->path().isEmpty()) 504 { 505 QFileInfo fi (mFileSelector->path()); 506 QString name = fi.fileName(); 507 if (type == Filesystem) 508 name = QDir::toNativeSeparators (QString ("%1/%2").arg (vboxGlobal().documentsPath()) 509 .arg (name)); 510 mFileSelector->setPath (name); 511 } 512 } 513 514 void VBoxExportApplianceWzd::setCurrentStorageType (VBoxExportApplianceWzd::StorageType aType) 515 { 516 switch (aType) 517 { 518 case Filesystem: mRBtnLocalFileSystem->setChecked(true); mRBtnLocalFileSystem->setFocus(); break; 519 case SunCloud: mRBtnSunCloud->setChecked(true); mRBtnSunCloud->setFocus(); break; 520 case S3: mRBtnS3->setChecked(true); mRBtnS3->setFocus(); break; 521 } 522 } 523 639 QString uri("S3://"); 640 if (!m_pLeUsername->text().isEmpty()) 641 uri = QString("%1%2").arg(uri).arg(m_pLeUsername->text()); 642 if (!m_pLePassword->text().isEmpty()) 643 uri = QString("%1:%2").arg(uri).arg(m_pLePassword->text()); 644 if (!m_pLeUsername->text().isEmpty() || !m_pLePassword->text().isEmpty()) 645 uri = QString("%1@").arg(uri); 646 uri = QString("%1%2/%3/%4").arg(uri).arg(m_pLeHostname->text()).arg(m_pLeBucket->text()).arg(m_pFileSelector->path()); 647 return uri; 648 } 649 } 650 return QString(); 651 } -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/exportappliance/UIExportApplianceWzd.h
r25432 r26079 2 2 * 3 3 * VBox frontends: Qt4 GUI ("VirtualBox"): 4 * VBoxExportApplianceWzd class declaration4 * UIExportApplianceWzd class declaration 5 5 */ 6 6 7 7 /* 8 * Copyright (C) 2009 Sun Microsystems, Inc.8 * Copyright (C) 2009-2010 Sun Microsystems, Inc. 9 9 * 10 10 * This file is part of VirtualBox Open Source Edition (OSE), as … … 21 21 */ 22 22 23 #ifndef __ VBoxExportApplianceWzd_h__24 #define __ VBoxExportApplianceWzd_h__23 #ifndef __UIExportApplianceWzd_h__ 24 #define __UIExportApplianceWzd_h__ 25 25 26 #include "VBoxExportApplianceWzd.gen.h" 27 #include "QIAbstractWizard.h" 28 #include "QIWithRetranslateUI.h" 26 /* Global includes */ 27 #include <QPointer> 29 28 30 class QIWidgetValidator; 29 /* Local includes */ 30 #include "QIWizard.h" 31 32 /* Generated includes */ 33 #include "UIExportApplianceWzdPage1.gen.h" 34 #include "UIExportApplianceWzdPage2.gen.h" 35 #include "UIExportApplianceWzdPage3.gen.h" 36 #include "UIExportApplianceWzdPage4.gen.h" 37 38 /* Local forwards */ 31 39 class CAppliance; 32 40 33 class VBoxExportApplianceWzd : public QIWithRetranslateUI<QIAbstractWizard>, 34 public Ui::VBoxExportApplianceWzd 41 enum StorageType { Filesystem, SunCloud, S3 }; 42 Q_DECLARE_METATYPE(StorageType); 43 44 typedef QPointer<VBoxExportApplianceWgt> ExportAppliancePointer; 45 Q_DECLARE_METATYPE(ExportAppliancePointer); 46 47 class UIExportApplianceWzd : public QIWizard 35 48 { 36 49 Q_OBJECT; 37 50 38 enum StorageType 39 { 40 Filesystem, 41 SunCloud, 42 S3 43 }; 51 public: 44 52 45 46 public: 47 VBoxExportApplianceWzd (QWidget* aParent = NULL, const QString& aSelectName = QString::null); 53 UIExportApplianceWzd(QWidget *pParent, const QString &strSelectedVMName = QString()); 48 54 49 55 protected: 56 50 57 void retranslateUi(); 51 58 52 59 private slots: 53 void revalidate (QIWidgetValidator *aWval);54 void enableNext (const QIWidgetValidator *aWval);55 60 56 void accept(); 61 void sltCurrentIdChanged(int iId); 62 }; 57 63 58 void showNextPage(); 59 void onPageShow(); 64 class UIExportApplianceWzdPage1 : public QIWizardPage, public Ui::UIExportApplianceWzdPage1 65 { 66 Q_OBJECT; 67 Q_PROPERTY(QString selectedVMName READ selectedVMName WRITE setSelectedVMName); 68 Q_PROPERTY(QStringList machineNames READ machineNames WRITE setMachineNames); 69 Q_PROPERTY(QStringList machineIDs READ machineIDs WRITE setMachineIDs); 70 71 public: 72 73 UIExportApplianceWzdPage1(); 74 75 protected: 76 77 void retranslateUi(); 78 79 void initializePage(); 80 void cleanupPage(); 81 82 bool isComplete() const; 83 84 private slots: 85 86 void sltSelectedVMChanged(); 60 87 61 88 private: 62 void addListViewVMItems (const QString& aSelectName);63 bool prepareSettingsWidget();64 bool exportVMs (CAppliance &aAppliance);65 QString uri() const;66 StorageType currentStorageType() const;67 void setCurrentStorageType(VBoxExportApplianceWzd::StorageType aType);68 89 69 void storageTypeChanged();90 void populateVMSelectorItems(); 70 91 71 /* Private member vars */ 72 QString mDefaultApplianceName; 92 QString selectedVMName() const { return m_strSelectedVMName; } 93 void setSelectedVMName(const QString &strSelectedVMName) { m_strSelectedVMName = strSelectedVMName; } 94 QString m_strSelectedVMName; 73 95 74 QIWidgetValidator *mWValVMSelector; 75 QIWidgetValidator *mWValFileSelector; 96 QStringList machineNames() const { return m_MachineNames; } 97 void setMachineNames(const QStringList &machineNames) { m_MachineNames = machineNames; } 98 QStringList m_MachineNames; 76 99 77 QString mExportToFileSystemDesc;78 QString mExportToSunCloudDesc;79 QString mExportToS3Desc;100 QStringList machineIDs() const { return m_MachineIDs; } 101 void setMachineIDs(const QStringList &machineIDs) { m_MachineIDs = machineIDs; } 102 QStringList m_MachineIDs; 80 103 }; 81 104 82 #endif /* __VBoxExportApplianceWzd_h__ */ 105 class UIExportApplianceWzdPage2 : public QIWizardPage, public Ui::UIExportApplianceWzdPage2 106 { 107 Q_OBJECT; 108 Q_PROPERTY(ExportAppliancePointer applianceWidget READ applianceWidget WRITE setApplianceWidget); 83 109 110 public: 111 112 UIExportApplianceWzdPage2(); 113 114 protected: 115 116 void retranslateUi(); 117 118 void initializePage(); 119 void cleanupPage(); 120 121 int nextId() const; 122 123 private: 124 125 bool prepareSettingsWidget(); 126 127 ExportAppliancePointer applianceWidget() const { return m_pApplianceWidget; } 128 void setApplianceWidget(const ExportAppliancePointer &pApplianceWidget) { m_pApplianceWidget = pApplianceWidget; } 129 ExportAppliancePointer m_pApplianceWidget; 130 }; 131 132 class UIExportApplianceWzdPage3 : public QIWizardPage, public Ui::UIExportApplianceWzdPage3 133 { 134 Q_OBJECT; 135 Q_PROPERTY(StorageType storageType READ storageType WRITE setStorageType); 136 137 public: 138 139 UIExportApplianceWzdPage3(); 140 141 protected: 142 143 void retranslateUi(); 144 145 void initializePage(); 146 147 private slots: 148 149 void sltStorageTypeChanged(); 150 151 private: 152 153 StorageType storageType() const { return m_StorageType; } 154 void setStorageType(StorageType storageType) { m_StorageType = storageType; } 155 StorageType m_StorageType; 156 }; 157 158 class UIExportApplianceWzdPage4 : public QIWizardPage, public Ui::UIExportApplianceWzdPage4 159 { 160 Q_OBJECT; 161 162 public: 163 164 UIExportApplianceWzdPage4(); 165 166 protected: 167 168 void retranslateUi(); 169 170 void initializePage(); 171 172 bool isComplete() const; 173 bool validatePage(); 174 175 private: 176 177 bool exportAppliance(); 178 bool exportVMs(CAppliance &appliance); 179 QString uri() const; 180 181 QString m_strDefaultApplianceName; 182 }; 183 184 #endif /* __UIExportApplianceWzd_h__ */ -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/exportappliance/UIExportApplianceWzdPage1.ui
r25432 r26079 2 2 <ui version="4.0"> 3 3 <comment> 4 VBox frontends: Qt4 GUI ( "VirtualBox"):4 VBox frontends: Qt4 GUI ("VirtualBox"): 5 5 6 Copyright (C) 2009 Sun Microsystems, Inc.6 Copyright (C) 2009-2010 Sun Microsystems, Inc. 7 7 8 8 This file is part of VirtualBox Open Source Edition (OSE), as … … 18 18 additional information or have any questions. 19 19 </comment> 20 <class> VBoxExportApplianceWzd</class>21 <widget class="QWidget" name=" VBoxExportApplianceWzd">20 <class>UIExportApplianceWzdPage1</class> 21 <widget class="QWidget" name="UIExportApplianceWzdPage1"> 22 22 <property name="geometry"> 23 23 <rect> 24 24 <x>0</x> 25 25 <y>0</y> 26 <width> 556</width>27 <height>4 52</height>26 <width>600</width> 27 <height>400</height> 28 28 </rect> 29 29 </property> 30 <property name="windowTitle"> 31 <string>Appliance Export Wizard</string> 30 <property name="sizePolicy"> 31 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 32 <horstretch>0</horstretch> 33 <verstretch>0</verstretch> 34 </sizepolicy> 32 35 </property> 33 <layout class="QVBoxLayout" name=" verticalLayout">34 <property name=" margin">36 <layout class="QVBoxLayout" name="m_pLayout1"> 37 <property name="bottomMargin" > 35 38 <number>0</number> 36 39 </property> 37 40 <item> 38 <widget class="Q StackedWidget" name="mPageStack">39 <property name=" currentIndex">40 < number>2</number>41 <widget class="QILabel" name="m_pPage1Text1"> 42 <property name="text"> 43 <string><p>This wizard will guide you through the process of exporting an appliance.</p><p>Use the <b>Next</b> button to go the next page of the wizard and the <b>Back</b> button to return to the previous page.</p><p>Please select the virtual machines that you wish to the appliance. You can select more than one. Please note that these machines have to be turned off before they can be exported.</p></string> 41 44 </property> 42 <widget class="QWidget" name="mVMSelectPage"> 43 <layout class="QVBoxLayout" name="verticalLayout_2"> 44 <item> 45 <widget class="QLabel" name="mPageWelcomeHdr"> 46 <property name="font"> 47 <font> 48 <family>Arial</family> 49 <pointsize>12</pointsize> 50 <weight>75</weight> 51 <bold>true</bold> 52 </font> 53 </property> 54 <property name="text"> 55 <string>Welcome to the Appliance Export Wizard!</string> 56 </property> 57 </widget> 58 </item> 59 <item> 60 <widget class="Line" name="line11"> 61 <property name="orientation"> 62 <enum>Qt::Horizontal</enum> 63 </property> 64 </widget> 65 </item> 66 <item> 67 <layout class="QGridLayout" name="gridLayout"> 68 <item row="0" column="0" rowspan="3"> 69 <widget class="QLabel" name="mLogoWelcome"> 70 <property name="sizePolicy"> 71 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 72 <horstretch>0</horstretch> 73 <verstretch>0</verstretch> 74 </sizepolicy> 75 </property> 76 <property name="autoFillBackground"> 77 <bool>true</bool> 78 </property> 79 <property name="text"> 80 <string/> 81 </property> 82 <property name="pixmap"> 83 <pixmap resource="../VirtualBox1.qrc">:/vmw_ovf_import.png</pixmap> 84 </property> 85 <property name="alignment"> 86 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 87 </property> 88 </widget> 89 </item> 90 <item row="0" column="1"> 91 <widget class="QILabel" name="mTextWelcome"> 92 <property name="sizePolicy"> 93 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 94 <horstretch>0</horstretch> 95 <verstretch>0</verstretch> 96 </sizepolicy> 97 </property> 98 <property name="minimumSize"> 99 <size> 100 <width>300</width> 101 <height>0</height> 102 </size> 103 </property> 104 <property name="text"> 105 <string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> 106 <html><head><meta name="qrichtext" content="1" /><style type="text/css"> 107 p, li { white-space: pre-wrap; } 108 </style></head><body> 109 <p style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">This wizard will guide you through the process of exporting an appliance. </p> 110 <p style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Use the <span style=" font-weight:600;">Next</span> button to go the next page of the wizard and the <span style=" font-weight:600;">Back</span> button to return to the previous page.</p> 111 <p style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Please select the virtual machines that you wish to the appliance. You can select more than one. Please note that these machines have to be turned off before they can be exported.</p></body></html></string> 112 </property> 113 <property name="wordWrap"> 114 <bool>true</bool> 115 </property> 116 </widget> 117 </item> 118 <item row="1" column="1"> 119 <widget class="QListWidget" name="mVMListWidget"/> 120 </item> 121 </layout> 122 </item> 123 <item> 124 <widget class="Line" name="line12"> 125 <property name="orientation"> 126 <enum>Qt::Horizontal</enum> 127 </property> 128 </widget> 129 </item> 130 <item> 131 <layout class="QHBoxLayout" name="_2"> 132 <item> 133 <spacer> 134 <property name="orientation"> 135 <enum>Qt::Horizontal</enum> 136 </property> 137 <property name="sizeHint" stdset="0"> 138 <size> 139 <width>0</width> 140 <height>0</height> 141 </size> 142 </property> 143 </spacer> 144 </item> 145 <item> 146 <widget class="QPushButton" name="mBtnBack1"> 147 <property name="enabled"> 148 <bool>false</bool> 149 </property> 150 <property name="text"> 151 <string>< &Back</string> 152 </property> 153 </widget> 154 </item> 155 <item> 156 <widget class="QPushButton" name="mBtnNext1"> 157 <property name="text"> 158 <string>&Next ></string> 159 </property> 160 </widget> 161 </item> 162 <item> 163 <spacer> 164 <property name="orientation"> 165 <enum>Qt::Horizontal</enum> 166 </property> 167 <property name="sizeType"> 168 <enum>QSizePolicy::Fixed</enum> 169 </property> 170 <property name="sizeHint" stdset="0"> 171 <size> 172 <width>5</width> 173 <height>0</height> 174 </size> 175 </property> 176 </spacer> 177 </item> 178 <item> 179 <widget class="QPushButton" name="mBtnCancel1"> 180 <property name="text"> 181 <string>Cancel</string> 182 </property> 183 </widget> 184 </item> 185 </layout> 186 </item> 187 </layout> 188 </widget> 189 <widget class="QWidget" name="mVMSettingsPage"> 190 <layout class="QVBoxLayout" name="verticalLayout_4"> 191 <item> 192 <widget class="QLabel" name="mPageSettingsHdr"> 193 <property name="font"> 194 <font> 195 <family>Arial</family> 196 <pointsize>12</pointsize> 197 <weight>75</weight> 198 <bold>true</bold> 199 </font> 200 </property> 201 <property name="text"> 202 <string>Appliance Export Settings</string> 203 </property> 204 </widget> 205 </item> 206 <item> 207 <widget class="Line" name="line21_2"> 208 <property name="orientation"> 209 <enum>Qt::Horizontal</enum> 210 </property> 211 </widget> 212 </item> 213 <item> 214 <layout class="QGridLayout" name="gridLayout_3"> 215 <item row="0" column="0" rowspan="2"> 216 <widget class="QLabel" name="mLogoSettings"> 217 <property name="sizePolicy"> 218 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 219 <horstretch>0</horstretch> 220 <verstretch>0</verstretch> 221 </sizepolicy> 222 </property> 223 <property name="autoFillBackground"> 224 <bool>true</bool> 225 </property> 226 <property name="text"> 227 <string/> 228 </property> 229 <property name="pixmap"> 230 <pixmap resource="../VirtualBox1.qrc">:/vmw_ovf_import.png</pixmap> 231 </property> 232 <property name="alignment"> 233 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 234 </property> 235 </widget> 236 </item> 237 <item row="0" column="1"> 238 <widget class="QILabel" name="mTextSettings"> 239 <property name="sizePolicy"> 240 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 241 <horstretch>0</horstretch> 242 <verstretch>0</verstretch> 243 </sizepolicy> 244 </property> 245 <property name="minimumSize"> 246 <size> 247 <width>300</width> 248 <height>0</height> 249 </size> 250 </property> 251 <property name="text"> 252 <string>Here you can change additional configuration values of the selected virtual machines. You can modify most of the properties shown by double-clicking on the items.</string> 253 </property> 254 <property name="wordWrap"> 255 <bool>true</bool> 256 </property> 257 </widget> 258 </item> 259 <item row="1" column="1"> 260 <widget class="VBoxExportApplianceWgt" name="mExportSettingsWgt" native="true"> 261 <property name="enabled"> 262 <bool>true</bool> 263 </property> 264 <property name="sizePolicy"> 265 <sizepolicy hsizetype="Preferred" vsizetype="MinimumExpanding"> 266 <horstretch>0</horstretch> 267 <verstretch>0</verstretch> 268 </sizepolicy> 269 </property> 270 <property name="minimumSize"> 271 <size> 272 <width>0</width> 273 <height>0</height> 274 </size> 275 </property> 276 <property name="baseSize"> 277 <size> 278 <width>0</width> 279 <height>0</height> 280 </size> 281 </property> 282 </widget> 283 </item> 284 </layout> 285 </item> 286 <item> 287 <widget class="Line" name="line22_2"> 288 <property name="orientation"> 289 <enum>Qt::Horizontal</enum> 290 </property> 291 </widget> 292 </item> 293 <item> 294 <layout class="QHBoxLayout" name="_4"> 295 <item> 296 <widget class="QPushButton" name="mBtnRestore"> 297 <property name="text"> 298 <string>Restore Defaults</string> 299 </property> 300 </widget> 301 </item> 302 <item> 303 <spacer> 304 <property name="orientation"> 305 <enum>Qt::Horizontal</enum> 306 </property> 307 <property name="sizeHint" stdset="0"> 308 <size> 309 <width>0</width> 310 <height>0</height> 311 </size> 312 </property> 313 </spacer> 314 </item> 315 <item> 316 <widget class="QPushButton" name="mBtnBack2"> 317 <property name="text"> 318 <string>< &Back</string> 319 </property> 320 </widget> 321 </item> 322 <item> 323 <widget class="QPushButton" name="mBtnNext2"> 324 <property name="text"> 325 <string>&Next ></string> 326 </property> 327 </widget> 328 </item> 329 <item> 330 <spacer> 331 <property name="orientation"> 332 <enum>Qt::Horizontal</enum> 333 </property> 334 <property name="sizeType"> 335 <enum>QSizePolicy::Fixed</enum> 336 </property> 337 <property name="sizeHint" stdset="0"> 338 <size> 339 <width>5</width> 340 <height>0</height> 341 </size> 342 </property> 343 </spacer> 344 </item> 345 <item> 346 <widget class="QPushButton" name="mBtnCancel2"> 347 <property name="text"> 348 <string>Cancel</string> 349 </property> 350 </widget> 351 </item> 352 </layout> 353 </item> 354 </layout> 355 </widget> 356 <widget class="QWidget" name="mTargetSelectPage"> 357 <layout class="QVBoxLayout" name="verticalLayout_6"> 358 <item> 359 <widget class="QLabel" name="mPageTargetSelectHdr"> 360 <property name="font"> 361 <font> 362 <family>Arial</family> 363 <pointsize>12</pointsize> 364 <weight>75</weight> 365 <bold>true</bold> 366 </font> 367 </property> 368 <property name="text"> 369 <string>Appliance Export Settings</string> 370 </property> 371 </widget> 372 </item> 373 <item> 374 <widget class="Line" name="line21_3"> 375 <property name="orientation"> 376 <enum>Qt::Horizontal</enum> 377 </property> 378 </widget> 379 </item> 380 <item> 381 <layout class="QGridLayout" name="gridLayout_5"> 382 <item row="0" column="0" rowspan="2"> 383 <widget class="QLabel" name="mLogoTargetSelect"> 384 <property name="sizePolicy"> 385 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 386 <horstretch>0</horstretch> 387 <verstretch>0</verstretch> 388 </sizepolicy> 389 </property> 390 <property name="autoFillBackground"> 391 <bool>true</bool> 392 </property> 393 <property name="text"> 394 <string/> 395 </property> 396 <property name="pixmap"> 397 <pixmap resource="../VirtualBox1.qrc">:/vmw_ovf_import.png</pixmap> 398 </property> 399 <property name="alignment"> 400 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 401 </property> 402 </widget> 403 </item> 404 <item row="0" column="1"> 405 <widget class="QILabel" name="mTextTargetSelect"> 406 <property name="sizePolicy"> 407 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 408 <horstretch>0</horstretch> 409 <verstretch>0</verstretch> 410 </sizepolicy> 411 </property> 412 <property name="minimumSize"> 413 <size> 414 <width>300</width> 415 <height>0</height> 416 </size> 417 </property> 418 <property name="text"> 419 <string>Please specify the target for the OVF export. You can choose between a local file system export, uploading the OVF to the Sun Cloud service or an S3 storage server.</string> 420 </property> 421 <property name="wordWrap"> 422 <bool>true</bool> 423 </property> 424 </widget> 425 </item> 426 <item row="1" column="1"> 427 <layout class="QVBoxLayout" name="verticalLayout_5"> 428 <item> 429 <widget class="QRadioButton" name="mRBtnLocalFileSystem"> 430 <property name="text"> 431 <string>&Local Filesystem </string> 432 </property> 433 <property name="checked"> 434 <bool>true</bool> 435 </property> 436 </widget> 437 </item> 438 <item> 439 <widget class="QRadioButton" name="mRBtnSunCloud"> 440 <property name="text"> 441 <string>Sun &Cloud</string> 442 </property> 443 </widget> 444 </item> 445 <item> 446 <widget class="QRadioButton" name="mRBtnS3"> 447 <property name="text"> 448 <string>&Simple Storage System (S3)</string> 449 </property> 450 </widget> 451 </item> 452 <item> 453 <spacer name="verticalSpacer"> 454 <property name="orientation"> 455 <enum>Qt::Vertical</enum> 456 </property> 457 <property name="sizeHint" stdset="0"> 458 <size> 459 <width>20</width> 460 <height>40</height> 461 </size> 462 </property> 463 </spacer> 464 </item> 465 </layout> 466 </item> 467 </layout> 468 </item> 469 <item> 470 <widget class="Line" name="line22_3"> 471 <property name="orientation"> 472 <enum>Qt::Horizontal</enum> 473 </property> 474 </widget> 475 </item> 476 <item> 477 <layout class="QHBoxLayout" name="_6"> 478 <item> 479 <spacer> 480 <property name="orientation"> 481 <enum>Qt::Horizontal</enum> 482 </property> 483 <property name="sizeHint" stdset="0"> 484 <size> 485 <width>0</width> 486 <height>0</height> 487 </size> 488 </property> 489 </spacer> 490 </item> 491 <item> 492 <widget class="QPushButton" name="mBtnBack3"> 493 <property name="text"> 494 <string>< &Back</string> 495 </property> 496 </widget> 497 </item> 498 <item> 499 <widget class="QPushButton" name="mBtnNext3"> 500 <property name="text"> 501 <string>&Next ></string> 502 </property> 503 </widget> 504 </item> 505 <item> 506 <spacer> 507 <property name="orientation"> 508 <enum>Qt::Horizontal</enum> 509 </property> 510 <property name="sizeType"> 511 <enum>QSizePolicy::Fixed</enum> 512 </property> 513 <property name="sizeHint" stdset="0"> 514 <size> 515 <width>5</width> 516 <height>0</height> 517 </size> 518 </property> 519 </spacer> 520 </item> 521 <item> 522 <widget class="QPushButton" name="mBtnCancel3"> 523 <property name="text"> 524 <string>Cancel</string> 525 </property> 526 </widget> 527 </item> 528 </layout> 529 </item> 530 </layout> 531 </widget> 532 <widget class="QWidget" name="mTargetOptionsPage"> 533 <layout class="QVBoxLayout" name="verticalLayout_3"> 534 <item> 535 <widget class="QLabel" name="mPageTargetOptionsHdr"> 536 <property name="font"> 537 <font> 538 <family>Arial</family> 539 <pointsize>12</pointsize> 540 <weight>75</weight> 541 <bold>true</bold> 542 </font> 543 </property> 544 <property name="text"> 545 <string>Appliance Export Settings</string> 546 </property> 547 </widget> 548 </item> 549 <item> 550 <widget class="Line" name="line21"> 551 <property name="orientation"> 552 <enum>Qt::Horizontal</enum> 553 </property> 554 </widget> 555 </item> 556 <item> 557 <layout class="QGridLayout" name="gridLayout_4"> 558 <item row="0" column="0" rowspan="4"> 559 <widget class="QLabel" name="mLogoTargetOptions"> 560 <property name="sizePolicy"> 561 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 562 <horstretch>0</horstretch> 563 <verstretch>0</verstretch> 564 </sizepolicy> 565 </property> 566 <property name="autoFillBackground"> 567 <bool>true</bool> 568 </property> 569 <property name="text"> 570 <string/> 571 </property> 572 <property name="pixmap"> 573 <pixmap resource="../VirtualBox1.qrc">:/vmw_ovf_import.png</pixmap> 574 </property> 575 <property name="alignment"> 576 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 577 </property> 578 </widget> 579 </item> 580 <item row="0" column="1"> 581 <widget class="QILabel" name="mTextTargetOptions"> 582 <property name="sizePolicy"> 583 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 584 <horstretch>0</horstretch> 585 <verstretch>0</verstretch> 586 </sizepolicy> 587 </property> 588 <property name="minimumSize"> 589 <size> 590 <width>300</width> 591 <height>0</height> 592 </size> 593 </property> 594 <property name="wordWrap"> 595 <bool>true</bool> 596 </property> 597 </widget> 598 </item> 599 <item row="1" column="1"> 600 <layout class="QGridLayout" name="gridLayout_2"> 601 <item row="0" column="0"> 602 <widget class="QLabel" name="mLblUsername"> 603 <property name="text"> 604 <string>&Username:</string> 605 </property> 606 <property name="buddy"> 607 <cstring>mLeUsername</cstring> 608 </property> 609 </widget> 610 </item> 611 <item row="0" column="1"> 612 <widget class="QLineEdit" name="mLeUsername"/> 613 </item> 614 <item row="1" column="0"> 615 <widget class="QLabel" name="mLblPassword"> 616 <property name="text"> 617 <string>&Password:</string> 618 </property> 619 <property name="buddy"> 620 <cstring>mLePassword</cstring> 621 </property> 622 </widget> 623 </item> 624 <item row="1" column="1"> 625 <widget class="QLineEdit" name="mLePassword"> 626 <property name="echoMode"> 627 <enum>QLineEdit::Password</enum> 628 </property> 629 </widget> 630 </item> 631 <item row="3" column="1"> 632 <widget class="QLineEdit" name="mLeBucket"/> 633 </item> 634 <item row="5" column="0"> 635 <widget class="QLabel" name="mLblFile"> 636 <property name="text"> 637 <string>&File:</string> 638 </property> 639 <property name="buddy"> 640 <cstring>mFileSelector</cstring> 641 </property> 642 </widget> 643 </item> 644 <item row="5" column="1"> 645 <widget class="VBoxEmptyFileSelector" name="mFileSelector" native="true"/> 646 </item> 647 <item row="3" column="0"> 648 <widget class="QLabel" name="mLblBucket"> 649 <property name="text"> 650 <string>&Bucket:</string> 651 </property> 652 <property name="buddy"> 653 <cstring>mLeBucket</cstring> 654 </property> 655 </widget> 656 </item> 657 <item row="2" column="0"> 658 <widget class="QLabel" name="mLblHostname"> 659 <property name="text"> 660 <string>&Hostname:</string> 661 </property> 662 <property name="buddy"> 663 <cstring>mLeHostname</cstring> 664 </property> 665 </widget> 666 </item> 667 <item row="2" column="1"> 668 <widget class="QLineEdit" name="mLeHostname"/> 669 </item> 670 </layout> 671 </item> 672 <item row="2" column="1"> 673 <widget class="QCheckBox" name="mSelectOVF09"> 674 <property name="toolTip"> 675 <string>Write in legacy OVF 0.9 format for compatibility with other virtualization products.</string> 676 </property> 677 <property name="text"> 678 <string>&Write legacy OVF 0.9</string> 679 </property> 680 </widget> 681 </item> 682 <item row="3" column="1"> 683 <spacer name="spacer"> 684 <property name="orientation"> 685 <enum>Qt::Vertical</enum> 686 </property> 687 <property name="sizeHint" stdset="0"> 688 <size> 689 <width>415</width> 690 <height>46</height> 691 </size> 692 </property> 693 </spacer> 694 </item> 695 </layout> 696 </item> 697 <item> 698 <widget class="Line" name="line22"> 699 <property name="orientation"> 700 <enum>Qt::Horizontal</enum> 701 </property> 702 </widget> 703 </item> 704 <item> 705 <layout class="QHBoxLayout" name="_3"> 706 <item> 707 <spacer> 708 <property name="orientation"> 709 <enum>Qt::Horizontal</enum> 710 </property> 711 <property name="sizeHint" stdset="0"> 712 <size> 713 <width>0</width> 714 <height>0</height> 715 </size> 716 </property> 717 </spacer> 718 </item> 719 <item> 720 <widget class="QPushButton" name="mBtnBack4"> 721 <property name="text"> 722 <string>< &Back</string> 723 </property> 724 </widget> 725 </item> 726 <item> 727 <widget class="QPushButton" name="mBtnFinish"> 728 <property name="text"> 729 <string>&Export ></string> 730 </property> 731 </widget> 732 </item> 733 <item> 734 <spacer> 735 <property name="orientation"> 736 <enum>Qt::Horizontal</enum> 737 </property> 738 <property name="sizeType"> 739 <enum>QSizePolicy::Fixed</enum> 740 </property> 741 <property name="sizeHint" stdset="0"> 742 <size> 743 <width>5</width> 744 <height>0</height> 745 </size> 746 </property> 747 </spacer> 748 </item> 749 <item> 750 <widget class="QPushButton" name="mBtnCancel4"> 751 <property name="text"> 752 <string>Cancel</string> 753 </property> 754 </widget> 755 </item> 756 </layout> 757 </item> 758 </layout> 759 </widget> 45 <property name="wordWrap"> 46 <bool>true</bool> 47 </property> 760 48 </widget> 49 </item> 50 <item> 51 <widget class="QListWidget" name="m_pVMSelector"/> 761 52 </item> 762 53 </layout> … … 768 59 <header>QILabel.h</header> 769 60 </customwidget> 770 <customwidget>771 <class>VBoxEmptyFileSelector</class>772 <extends>QWidget</extends>773 <header>VBoxFilePathSelectorWidget.h</header>774 </customwidget>775 <customwidget>776 <class>VBoxExportApplianceWgt</class>777 <extends>QWidget</extends>778 <header>VBoxExportApplianceWgt.h</header>779 <container>1</container>780 </customwidget>781 61 </customwidgets> 782 <tabstops> 783 <tabstop>mVMListWidget</tabstop> 784 <tabstop>mBtnBack1</tabstop> 785 <tabstop>mBtnNext1</tabstop> 786 <tabstop>mBtnCancel1</tabstop> 787 <tabstop>mTargetOptionsPage</tabstop> 788 <tabstop>mBtnRestore</tabstop> 789 <tabstop>mBtnBack2</tabstop> 790 <tabstop>mBtnNext2</tabstop> 791 <tabstop>mBtnCancel2</tabstop> 792 <tabstop>mLeUsername</tabstop> 793 <tabstop>mLePassword</tabstop> 794 <tabstop>mLeHostname</tabstop> 795 <tabstop>mLeBucket</tabstop> 796 <tabstop>mFileSelector</tabstop> 797 <tabstop>mSelectOVF09</tabstop> 798 <tabstop>mBtnBack4</tabstop> 799 <tabstop>mBtnFinish</tabstop> 800 <tabstop>mBtnCancel4</tabstop> 801 </tabstops> 802 <resources> 803 <include location="../VirtualBox1.qrc"/> 804 </resources> 62 <resources/> 805 63 <connections/> 806 64 </ui> -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/exportappliance/UIExportApplianceWzdPage2.ui
r25432 r26079 2 2 <ui version="4.0"> 3 3 <comment> 4 VBox frontends: Qt4 GUI ( "VirtualBox"):4 VBox frontends: Qt4 GUI ("VirtualBox"): 5 5 6 Copyright (C) 2009 Sun Microsystems, Inc.6 Copyright (C) 2009-2010 Sun Microsystems, Inc. 7 7 8 8 This file is part of VirtualBox Open Source Edition (OSE), as … … 18 18 additional information or have any questions. 19 19 </comment> 20 <class> VBoxExportApplianceWzd</class>21 <widget class="QWidget" name=" VBoxExportApplianceWzd">20 <class>UIExportApplianceWzdPage2</class> 21 <widget class="QWidget" name="UIExportApplianceWzdPage2"> 22 22 <property name="geometry"> 23 23 <rect> 24 24 <x>0</x> 25 25 <y>0</y> 26 <width> 556</width>27 <height>4 52</height>26 <width>600</width> 27 <height>400</height> 28 28 </rect> 29 29 </property> 30 <property name="windowTitle"> 31 <string>Appliance Export Wizard</string> 30 <property name="sizePolicy"> 31 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 32 <horstretch>0</horstretch> 33 <verstretch>0</verstretch> 34 </sizepolicy> 32 35 </property> 33 <layout class="QVBoxLayout" name=" verticalLayout">34 <property name=" margin">36 <layout class="QVBoxLayout" name="m_pLayout1"> 37 <property name="bottomMargin" > 35 38 <number>0</number> 36 39 </property> 37 40 <item> 38 <widget class="Q StackedWidget" name="mPageStack">39 <property name=" currentIndex">40 < number>2</number>41 <widget class="QILabel" name="m_pPage2Text1"> 42 <property name="text"> 43 <string>Here you can change additional configuration values of the selected virtual machines. You can modify most of the properties shown by double-clicking on the items.</string> 41 44 </property> 42 <widget class="QWidget" name="mVMSelectPage"> 43 <layout class="QVBoxLayout" name="verticalLayout_2"> 44 <item> 45 <widget class="QLabel" name="mPageWelcomeHdr"> 46 <property name="font"> 47 <font> 48 <family>Arial</family> 49 <pointsize>12</pointsize> 50 <weight>75</weight> 51 <bold>true</bold> 52 </font> 53 </property> 54 <property name="text"> 55 <string>Welcome to the Appliance Export Wizard!</string> 56 </property> 57 </widget> 58 </item> 59 <item> 60 <widget class="Line" name="line11"> 61 <property name="orientation"> 62 <enum>Qt::Horizontal</enum> 63 </property> 64 </widget> 65 </item> 66 <item> 67 <layout class="QGridLayout" name="gridLayout"> 68 <item row="0" column="0" rowspan="3"> 69 <widget class="QLabel" name="mLogoWelcome"> 70 <property name="sizePolicy"> 71 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 72 <horstretch>0</horstretch> 73 <verstretch>0</verstretch> 74 </sizepolicy> 75 </property> 76 <property name="autoFillBackground"> 77 <bool>true</bool> 78 </property> 79 <property name="text"> 80 <string/> 81 </property> 82 <property name="pixmap"> 83 <pixmap resource="../VirtualBox1.qrc">:/vmw_ovf_import.png</pixmap> 84 </property> 85 <property name="alignment"> 86 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 87 </property> 88 </widget> 89 </item> 90 <item row="0" column="1"> 91 <widget class="QILabel" name="mTextWelcome"> 92 <property name="sizePolicy"> 93 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 94 <horstretch>0</horstretch> 95 <verstretch>0</verstretch> 96 </sizepolicy> 97 </property> 98 <property name="minimumSize"> 99 <size> 100 <width>300</width> 101 <height>0</height> 102 </size> 103 </property> 104 <property name="text"> 105 <string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> 106 <html><head><meta name="qrichtext" content="1" /><style type="text/css"> 107 p, li { white-space: pre-wrap; } 108 </style></head><body> 109 <p style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">This wizard will guide you through the process of exporting an appliance. </p> 110 <p style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Use the <span style=" font-weight:600;">Next</span> button to go the next page of the wizard and the <span style=" font-weight:600;">Back</span> button to return to the previous page.</p> 111 <p style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Please select the virtual machines that you wish to the appliance. You can select more than one. Please note that these machines have to be turned off before they can be exported.</p></body></html></string> 112 </property> 113 <property name="wordWrap"> 114 <bool>true</bool> 115 </property> 116 </widget> 117 </item> 118 <item row="1" column="1"> 119 <widget class="QListWidget" name="mVMListWidget"/> 120 </item> 121 </layout> 122 </item> 123 <item> 124 <widget class="Line" name="line12"> 125 <property name="orientation"> 126 <enum>Qt::Horizontal</enum> 127 </property> 128 </widget> 129 </item> 130 <item> 131 <layout class="QHBoxLayout" name="_2"> 132 <item> 133 <spacer> 134 <property name="orientation"> 135 <enum>Qt::Horizontal</enum> 136 </property> 137 <property name="sizeHint" stdset="0"> 138 <size> 139 <width>0</width> 140 <height>0</height> 141 </size> 142 </property> 143 </spacer> 144 </item> 145 <item> 146 <widget class="QPushButton" name="mBtnBack1"> 147 <property name="enabled"> 148 <bool>false</bool> 149 </property> 150 <property name="text"> 151 <string>< &Back</string> 152 </property> 153 </widget> 154 </item> 155 <item> 156 <widget class="QPushButton" name="mBtnNext1"> 157 <property name="text"> 158 <string>&Next ></string> 159 </property> 160 </widget> 161 </item> 162 <item> 163 <spacer> 164 <property name="orientation"> 165 <enum>Qt::Horizontal</enum> 166 </property> 167 <property name="sizeType"> 168 <enum>QSizePolicy::Fixed</enum> 169 </property> 170 <property name="sizeHint" stdset="0"> 171 <size> 172 <width>5</width> 173 <height>0</height> 174 </size> 175 </property> 176 </spacer> 177 </item> 178 <item> 179 <widget class="QPushButton" name="mBtnCancel1"> 180 <property name="text"> 181 <string>Cancel</string> 182 </property> 183 </widget> 184 </item> 185 </layout> 186 </item> 187 </layout> 188 </widget> 189 <widget class="QWidget" name="mVMSettingsPage"> 190 <layout class="QVBoxLayout" name="verticalLayout_4"> 191 <item> 192 <widget class="QLabel" name="mPageSettingsHdr"> 193 <property name="font"> 194 <font> 195 <family>Arial</family> 196 <pointsize>12</pointsize> 197 <weight>75</weight> 198 <bold>true</bold> 199 </font> 200 </property> 201 <property name="text"> 202 <string>Appliance Export Settings</string> 203 </property> 204 </widget> 205 </item> 206 <item> 207 <widget class="Line" name="line21_2"> 208 <property name="orientation"> 209 <enum>Qt::Horizontal</enum> 210 </property> 211 </widget> 212 </item> 213 <item> 214 <layout class="QGridLayout" name="gridLayout_3"> 215 <item row="0" column="0" rowspan="2"> 216 <widget class="QLabel" name="mLogoSettings"> 217 <property name="sizePolicy"> 218 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 219 <horstretch>0</horstretch> 220 <verstretch>0</verstretch> 221 </sizepolicy> 222 </property> 223 <property name="autoFillBackground"> 224 <bool>true</bool> 225 </property> 226 <property name="text"> 227 <string/> 228 </property> 229 <property name="pixmap"> 230 <pixmap resource="../VirtualBox1.qrc">:/vmw_ovf_import.png</pixmap> 231 </property> 232 <property name="alignment"> 233 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 234 </property> 235 </widget> 236 </item> 237 <item row="0" column="1"> 238 <widget class="QILabel" name="mTextSettings"> 239 <property name="sizePolicy"> 240 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 241 <horstretch>0</horstretch> 242 <verstretch>0</verstretch> 243 </sizepolicy> 244 </property> 245 <property name="minimumSize"> 246 <size> 247 <width>300</width> 248 <height>0</height> 249 </size> 250 </property> 251 <property name="text"> 252 <string>Here you can change additional configuration values of the selected virtual machines. You can modify most of the properties shown by double-clicking on the items.</string> 253 </property> 254 <property name="wordWrap"> 255 <bool>true</bool> 256 </property> 257 </widget> 258 </item> 259 <item row="1" column="1"> 260 <widget class="VBoxExportApplianceWgt" name="mExportSettingsWgt" native="true"> 261 <property name="enabled"> 262 <bool>true</bool> 263 </property> 264 <property name="sizePolicy"> 265 <sizepolicy hsizetype="Preferred" vsizetype="MinimumExpanding"> 266 <horstretch>0</horstretch> 267 <verstretch>0</verstretch> 268 </sizepolicy> 269 </property> 270 <property name="minimumSize"> 271 <size> 272 <width>0</width> 273 <height>0</height> 274 </size> 275 </property> 276 <property name="baseSize"> 277 <size> 278 <width>0</width> 279 <height>0</height> 280 </size> 281 </property> 282 </widget> 283 </item> 284 </layout> 285 </item> 286 <item> 287 <widget class="Line" name="line22_2"> 288 <property name="orientation"> 289 <enum>Qt::Horizontal</enum> 290 </property> 291 </widget> 292 </item> 293 <item> 294 <layout class="QHBoxLayout" name="_4"> 295 <item> 296 <widget class="QPushButton" name="mBtnRestore"> 297 <property name="text"> 298 <string>Restore Defaults</string> 299 </property> 300 </widget> 301 </item> 302 <item> 303 <spacer> 304 <property name="orientation"> 305 <enum>Qt::Horizontal</enum> 306 </property> 307 <property name="sizeHint" stdset="0"> 308 <size> 309 <width>0</width> 310 <height>0</height> 311 </size> 312 </property> 313 </spacer> 314 </item> 315 <item> 316 <widget class="QPushButton" name="mBtnBack2"> 317 <property name="text"> 318 <string>< &Back</string> 319 </property> 320 </widget> 321 </item> 322 <item> 323 <widget class="QPushButton" name="mBtnNext2"> 324 <property name="text"> 325 <string>&Next ></string> 326 </property> 327 </widget> 328 </item> 329 <item> 330 <spacer> 331 <property name="orientation"> 332 <enum>Qt::Horizontal</enum> 333 </property> 334 <property name="sizeType"> 335 <enum>QSizePolicy::Fixed</enum> 336 </property> 337 <property name="sizeHint" stdset="0"> 338 <size> 339 <width>5</width> 340 <height>0</height> 341 </size> 342 </property> 343 </spacer> 344 </item> 345 <item> 346 <widget class="QPushButton" name="mBtnCancel2"> 347 <property name="text"> 348 <string>Cancel</string> 349 </property> 350 </widget> 351 </item> 352 </layout> 353 </item> 354 </layout> 355 </widget> 356 <widget class="QWidget" name="mTargetSelectPage"> 357 <layout class="QVBoxLayout" name="verticalLayout_6"> 358 <item> 359 <widget class="QLabel" name="mPageTargetSelectHdr"> 360 <property name="font"> 361 <font> 362 <family>Arial</family> 363 <pointsize>12</pointsize> 364 <weight>75</weight> 365 <bold>true</bold> 366 </font> 367 </property> 368 <property name="text"> 369 <string>Appliance Export Settings</string> 370 </property> 371 </widget> 372 </item> 373 <item> 374 <widget class="Line" name="line21_3"> 375 <property name="orientation"> 376 <enum>Qt::Horizontal</enum> 377 </property> 378 </widget> 379 </item> 380 <item> 381 <layout class="QGridLayout" name="gridLayout_5"> 382 <item row="0" column="0" rowspan="2"> 383 <widget class="QLabel" name="mLogoTargetSelect"> 384 <property name="sizePolicy"> 385 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 386 <horstretch>0</horstretch> 387 <verstretch>0</verstretch> 388 </sizepolicy> 389 </property> 390 <property name="autoFillBackground"> 391 <bool>true</bool> 392 </property> 393 <property name="text"> 394 <string/> 395 </property> 396 <property name="pixmap"> 397 <pixmap resource="../VirtualBox1.qrc">:/vmw_ovf_import.png</pixmap> 398 </property> 399 <property name="alignment"> 400 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 401 </property> 402 </widget> 403 </item> 404 <item row="0" column="1"> 405 <widget class="QILabel" name="mTextTargetSelect"> 406 <property name="sizePolicy"> 407 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 408 <horstretch>0</horstretch> 409 <verstretch>0</verstretch> 410 </sizepolicy> 411 </property> 412 <property name="minimumSize"> 413 <size> 414 <width>300</width> 415 <height>0</height> 416 </size> 417 </property> 418 <property name="text"> 419 <string>Please specify the target for the OVF export. You can choose between a local file system export, uploading the OVF to the Sun Cloud service or an S3 storage server.</string> 420 </property> 421 <property name="wordWrap"> 422 <bool>true</bool> 423 </property> 424 </widget> 425 </item> 426 <item row="1" column="1"> 427 <layout class="QVBoxLayout" name="verticalLayout_5"> 428 <item> 429 <widget class="QRadioButton" name="mRBtnLocalFileSystem"> 430 <property name="text"> 431 <string>&Local Filesystem </string> 432 </property> 433 <property name="checked"> 434 <bool>true</bool> 435 </property> 436 </widget> 437 </item> 438 <item> 439 <widget class="QRadioButton" name="mRBtnSunCloud"> 440 <property name="text"> 441 <string>Sun &Cloud</string> 442 </property> 443 </widget> 444 </item> 445 <item> 446 <widget class="QRadioButton" name="mRBtnS3"> 447 <property name="text"> 448 <string>&Simple Storage System (S3)</string> 449 </property> 450 </widget> 451 </item> 452 <item> 453 <spacer name="verticalSpacer"> 454 <property name="orientation"> 455 <enum>Qt::Vertical</enum> 456 </property> 457 <property name="sizeHint" stdset="0"> 458 <size> 459 <width>20</width> 460 <height>40</height> 461 </size> 462 </property> 463 </spacer> 464 </item> 465 </layout> 466 </item> 467 </layout> 468 </item> 469 <item> 470 <widget class="Line" name="line22_3"> 471 <property name="orientation"> 472 <enum>Qt::Horizontal</enum> 473 </property> 474 </widget> 475 </item> 476 <item> 477 <layout class="QHBoxLayout" name="_6"> 478 <item> 479 <spacer> 480 <property name="orientation"> 481 <enum>Qt::Horizontal</enum> 482 </property> 483 <property name="sizeHint" stdset="0"> 484 <size> 485 <width>0</width> 486 <height>0</height> 487 </size> 488 </property> 489 </spacer> 490 </item> 491 <item> 492 <widget class="QPushButton" name="mBtnBack3"> 493 <property name="text"> 494 <string>< &Back</string> 495 </property> 496 </widget> 497 </item> 498 <item> 499 <widget class="QPushButton" name="mBtnNext3"> 500 <property name="text"> 501 <string>&Next ></string> 502 </property> 503 </widget> 504 </item> 505 <item> 506 <spacer> 507 <property name="orientation"> 508 <enum>Qt::Horizontal</enum> 509 </property> 510 <property name="sizeType"> 511 <enum>QSizePolicy::Fixed</enum> 512 </property> 513 <property name="sizeHint" stdset="0"> 514 <size> 515 <width>5</width> 516 <height>0</height> 517 </size> 518 </property> 519 </spacer> 520 </item> 521 <item> 522 <widget class="QPushButton" name="mBtnCancel3"> 523 <property name="text"> 524 <string>Cancel</string> 525 </property> 526 </widget> 527 </item> 528 </layout> 529 </item> 530 </layout> 531 </widget> 532 <widget class="QWidget" name="mTargetOptionsPage"> 533 <layout class="QVBoxLayout" name="verticalLayout_3"> 534 <item> 535 <widget class="QLabel" name="mPageTargetOptionsHdr"> 536 <property name="font"> 537 <font> 538 <family>Arial</family> 539 <pointsize>12</pointsize> 540 <weight>75</weight> 541 <bold>true</bold> 542 </font> 543 </property> 544 <property name="text"> 545 <string>Appliance Export Settings</string> 546 </property> 547 </widget> 548 </item> 549 <item> 550 <widget class="Line" name="line21"> 551 <property name="orientation"> 552 <enum>Qt::Horizontal</enum> 553 </property> 554 </widget> 555 </item> 556 <item> 557 <layout class="QGridLayout" name="gridLayout_4"> 558 <item row="0" column="0" rowspan="4"> 559 <widget class="QLabel" name="mLogoTargetOptions"> 560 <property name="sizePolicy"> 561 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 562 <horstretch>0</horstretch> 563 <verstretch>0</verstretch> 564 </sizepolicy> 565 </property> 566 <property name="autoFillBackground"> 567 <bool>true</bool> 568 </property> 569 <property name="text"> 570 <string/> 571 </property> 572 <property name="pixmap"> 573 <pixmap resource="../VirtualBox1.qrc">:/vmw_ovf_import.png</pixmap> 574 </property> 575 <property name="alignment"> 576 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 577 </property> 578 </widget> 579 </item> 580 <item row="0" column="1"> 581 <widget class="QILabel" name="mTextTargetOptions"> 582 <property name="sizePolicy"> 583 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 584 <horstretch>0</horstretch> 585 <verstretch>0</verstretch> 586 </sizepolicy> 587 </property> 588 <property name="minimumSize"> 589 <size> 590 <width>300</width> 591 <height>0</height> 592 </size> 593 </property> 594 <property name="wordWrap"> 595 <bool>true</bool> 596 </property> 597 </widget> 598 </item> 599 <item row="1" column="1"> 600 <layout class="QGridLayout" name="gridLayout_2"> 601 <item row="0" column="0"> 602 <widget class="QLabel" name="mLblUsername"> 603 <property name="text"> 604 <string>&Username:</string> 605 </property> 606 <property name="buddy"> 607 <cstring>mLeUsername</cstring> 608 </property> 609 </widget> 610 </item> 611 <item row="0" column="1"> 612 <widget class="QLineEdit" name="mLeUsername"/> 613 </item> 614 <item row="1" column="0"> 615 <widget class="QLabel" name="mLblPassword"> 616 <property name="text"> 617 <string>&Password:</string> 618 </property> 619 <property name="buddy"> 620 <cstring>mLePassword</cstring> 621 </property> 622 </widget> 623 </item> 624 <item row="1" column="1"> 625 <widget class="QLineEdit" name="mLePassword"> 626 <property name="echoMode"> 627 <enum>QLineEdit::Password</enum> 628 </property> 629 </widget> 630 </item> 631 <item row="3" column="1"> 632 <widget class="QLineEdit" name="mLeBucket"/> 633 </item> 634 <item row="5" column="0"> 635 <widget class="QLabel" name="mLblFile"> 636 <property name="text"> 637 <string>&File:</string> 638 </property> 639 <property name="buddy"> 640 <cstring>mFileSelector</cstring> 641 </property> 642 </widget> 643 </item> 644 <item row="5" column="1"> 645 <widget class="VBoxEmptyFileSelector" name="mFileSelector" native="true"/> 646 </item> 647 <item row="3" column="0"> 648 <widget class="QLabel" name="mLblBucket"> 649 <property name="text"> 650 <string>&Bucket:</string> 651 </property> 652 <property name="buddy"> 653 <cstring>mLeBucket</cstring> 654 </property> 655 </widget> 656 </item> 657 <item row="2" column="0"> 658 <widget class="QLabel" name="mLblHostname"> 659 <property name="text"> 660 <string>&Hostname:</string> 661 </property> 662 <property name="buddy"> 663 <cstring>mLeHostname</cstring> 664 </property> 665 </widget> 666 </item> 667 <item row="2" column="1"> 668 <widget class="QLineEdit" name="mLeHostname"/> 669 </item> 670 </layout> 671 </item> 672 <item row="2" column="1"> 673 <widget class="QCheckBox" name="mSelectOVF09"> 674 <property name="toolTip"> 675 <string>Write in legacy OVF 0.9 format for compatibility with other virtualization products.</string> 676 </property> 677 <property name="text"> 678 <string>&Write legacy OVF 0.9</string> 679 </property> 680 </widget> 681 </item> 682 <item row="3" column="1"> 683 <spacer name="spacer"> 684 <property name="orientation"> 685 <enum>Qt::Vertical</enum> 686 </property> 687 <property name="sizeHint" stdset="0"> 688 <size> 689 <width>415</width> 690 <height>46</height> 691 </size> 692 </property> 693 </spacer> 694 </item> 695 </layout> 696 </item> 697 <item> 698 <widget class="Line" name="line22"> 699 <property name="orientation"> 700 <enum>Qt::Horizontal</enum> 701 </property> 702 </widget> 703 </item> 704 <item> 705 <layout class="QHBoxLayout" name="_3"> 706 <item> 707 <spacer> 708 <property name="orientation"> 709 <enum>Qt::Horizontal</enum> 710 </property> 711 <property name="sizeHint" stdset="0"> 712 <size> 713 <width>0</width> 714 <height>0</height> 715 </size> 716 </property> 717 </spacer> 718 </item> 719 <item> 720 <widget class="QPushButton" name="mBtnBack4"> 721 <property name="text"> 722 <string>< &Back</string> 723 </property> 724 </widget> 725 </item> 726 <item> 727 <widget class="QPushButton" name="mBtnFinish"> 728 <property name="text"> 729 <string>&Export ></string> 730 </property> 731 </widget> 732 </item> 733 <item> 734 <spacer> 735 <property name="orientation"> 736 <enum>Qt::Horizontal</enum> 737 </property> 738 <property name="sizeType"> 739 <enum>QSizePolicy::Fixed</enum> 740 </property> 741 <property name="sizeHint" stdset="0"> 742 <size> 743 <width>5</width> 744 <height>0</height> 745 </size> 746 </property> 747 </spacer> 748 </item> 749 <item> 750 <widget class="QPushButton" name="mBtnCancel4"> 751 <property name="text"> 752 <string>Cancel</string> 753 </property> 754 </widget> 755 </item> 756 </layout> 757 </item> 758 </layout> 759 </widget> 45 <property name="wordWrap"> 46 <bool>true</bool> 47 </property> 48 </widget> 49 </item> 50 <item> 51 <widget class="VBoxExportApplianceWgt" name="m_pSettingsCnt" native="true"> 52 <property name="sizePolicy"> 53 <sizepolicy hsizetype="Preferred" vsizetype="MinimumExpanding"> 54 <horstretch>0</horstretch> 55 <verstretch>0</verstretch> 56 </sizepolicy> 57 </property> 760 58 </widget> 761 59 </item> … … 769 67 </customwidget> 770 68 <customwidget> 771 <class>VBoxEmptyFileSelector</class>772 <extends>QWidget</extends>773 <header>VBoxFilePathSelectorWidget.h</header>774 </customwidget>775 <customwidget>776 69 <class>VBoxExportApplianceWgt</class> 777 70 <extends>QWidget</extends> … … 780 73 </customwidget> 781 74 </customwidgets> 782 <tabstops> 783 <tabstop>mVMListWidget</tabstop> 784 <tabstop>mBtnBack1</tabstop> 785 <tabstop>mBtnNext1</tabstop> 786 <tabstop>mBtnCancel1</tabstop> 787 <tabstop>mTargetOptionsPage</tabstop> 788 <tabstop>mBtnRestore</tabstop> 789 <tabstop>mBtnBack2</tabstop> 790 <tabstop>mBtnNext2</tabstop> 791 <tabstop>mBtnCancel2</tabstop> 792 <tabstop>mLeUsername</tabstop> 793 <tabstop>mLePassword</tabstop> 794 <tabstop>mLeHostname</tabstop> 795 <tabstop>mLeBucket</tabstop> 796 <tabstop>mFileSelector</tabstop> 797 <tabstop>mSelectOVF09</tabstop> 798 <tabstop>mBtnBack4</tabstop> 799 <tabstop>mBtnFinish</tabstop> 800 <tabstop>mBtnCancel4</tabstop> 801 </tabstops> 802 <resources> 803 <include location="../VirtualBox1.qrc"/> 804 </resources> 75 <resources/> 805 76 <connections/> 806 77 </ui> -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/exportappliance/UIExportApplianceWzdPage3.ui
r25432 r26079 2 2 <ui version="4.0"> 3 3 <comment> 4 VBox frontends: Qt4 GUI ( "VirtualBox"):4 VBox frontends: Qt4 GUI ("VirtualBox"): 5 5 6 Copyright (C) 2009 Sun Microsystems, Inc.6 Copyright (C) 2009-2010 Sun Microsystems, Inc. 7 7 8 8 This file is part of VirtualBox Open Source Edition (OSE), as … … 18 18 additional information or have any questions. 19 19 </comment> 20 <class> VBoxExportApplianceWzd</class>21 <widget class="QWidget" name=" VBoxExportApplianceWzd">20 <class>UIExportApplianceWzdPage3</class> 21 <widget class="QWidget" name="UIExportApplianceWzdPage3"> 22 22 <property name="geometry"> 23 23 <rect> 24 24 <x>0</x> 25 25 <y>0</y> 26 <width> 556</width>27 <height>4 52</height>26 <width>600</width> 27 <height>400</height> 28 28 </rect> 29 29 </property> 30 <property name="windowTitle"> 31 <string>Appliance Export Wizard</string> 30 <property name="sizePolicy"> 31 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 32 <horstretch>0</horstretch> 33 <verstretch>0</verstretch> 34 </sizepolicy> 32 35 </property> 33 <layout class="QVBoxLayout" name=" verticalLayout">34 <property name=" margin">36 <layout class="QVBoxLayout" name="m_pLayout1"> 37 <property name="bottomMargin" > 35 38 <number>0</number> 36 39 </property> 37 40 <item> 38 <widget class="Q StackedWidget" name="mPageStack">39 <property name=" currentIndex">40 < number>2</number>41 <widget class="QILabel" name="m_pPage3Text1"> 42 <property name="text"> 43 <string>Please specify the target for the OVF export. You can choose between a local file system export, uploading the OVF to the Sun Cloud service or an S3 storage server.</string> 41 44 </property> 42 <widget class="QWidget" name="mVMSelectPage"> 43 <layout class="QVBoxLayout" name="verticalLayout_2"> 44 <item> 45 <widget class="QLabel" name="mPageWelcomeHdr"> 46 <property name="font"> 47 <font> 48 <family>Arial</family> 49 <pointsize>12</pointsize> 50 <weight>75</weight> 51 <bold>true</bold> 52 </font> 53 </property> 54 <property name="text"> 55 <string>Welcome to the Appliance Export Wizard!</string> 56 </property> 57 </widget> 58 </item> 59 <item> 60 <widget class="Line" name="line11"> 61 <property name="orientation"> 62 <enum>Qt::Horizontal</enum> 63 </property> 64 </widget> 65 </item> 66 <item> 67 <layout class="QGridLayout" name="gridLayout"> 68 <item row="0" column="0" rowspan="3"> 69 <widget class="QLabel" name="mLogoWelcome"> 70 <property name="sizePolicy"> 71 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 72 <horstretch>0</horstretch> 73 <verstretch>0</verstretch> 74 </sizepolicy> 75 </property> 76 <property name="autoFillBackground"> 77 <bool>true</bool> 78 </property> 79 <property name="text"> 80 <string/> 81 </property> 82 <property name="pixmap"> 83 <pixmap resource="../VirtualBox1.qrc">:/vmw_ovf_import.png</pixmap> 84 </property> 85 <property name="alignment"> 86 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 87 </property> 88 </widget> 89 </item> 90 <item row="0" column="1"> 91 <widget class="QILabel" name="mTextWelcome"> 92 <property name="sizePolicy"> 93 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 94 <horstretch>0</horstretch> 95 <verstretch>0</verstretch> 96 </sizepolicy> 97 </property> 98 <property name="minimumSize"> 99 <size> 100 <width>300</width> 101 <height>0</height> 102 </size> 103 </property> 104 <property name="text"> 105 <string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> 106 <html><head><meta name="qrichtext" content="1" /><style type="text/css"> 107 p, li { white-space: pre-wrap; } 108 </style></head><body> 109 <p style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">This wizard will guide you through the process of exporting an appliance. </p> 110 <p style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Use the <span style=" font-weight:600;">Next</span> button to go the next page of the wizard and the <span style=" font-weight:600;">Back</span> button to return to the previous page.</p> 111 <p style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Please select the virtual machines that you wish to the appliance. You can select more than one. Please note that these machines have to be turned off before they can be exported.</p></body></html></string> 112 </property> 113 <property name="wordWrap"> 114 <bool>true</bool> 115 </property> 116 </widget> 117 </item> 118 <item row="1" column="1"> 119 <widget class="QListWidget" name="mVMListWidget"/> 120 </item> 121 </layout> 122 </item> 123 <item> 124 <widget class="Line" name="line12"> 125 <property name="orientation"> 126 <enum>Qt::Horizontal</enum> 127 </property> 128 </widget> 129 </item> 130 <item> 131 <layout class="QHBoxLayout" name="_2"> 132 <item> 133 <spacer> 134 <property name="orientation"> 135 <enum>Qt::Horizontal</enum> 136 </property> 137 <property name="sizeHint" stdset="0"> 138 <size> 139 <width>0</width> 140 <height>0</height> 141 </size> 142 </property> 143 </spacer> 144 </item> 145 <item> 146 <widget class="QPushButton" name="mBtnBack1"> 147 <property name="enabled"> 148 <bool>false</bool> 149 </property> 150 <property name="text"> 151 <string>< &Back</string> 152 </property> 153 </widget> 154 </item> 155 <item> 156 <widget class="QPushButton" name="mBtnNext1"> 157 <property name="text"> 158 <string>&Next ></string> 159 </property> 160 </widget> 161 </item> 162 <item> 163 <spacer> 164 <property name="orientation"> 165 <enum>Qt::Horizontal</enum> 166 </property> 167 <property name="sizeType"> 168 <enum>QSizePolicy::Fixed</enum> 169 </property> 170 <property name="sizeHint" stdset="0"> 171 <size> 172 <width>5</width> 173 <height>0</height> 174 </size> 175 </property> 176 </spacer> 177 </item> 178 <item> 179 <widget class="QPushButton" name="mBtnCancel1"> 180 <property name="text"> 181 <string>Cancel</string> 182 </property> 183 </widget> 184 </item> 185 </layout> 186 </item> 187 </layout> 188 </widget> 189 <widget class="QWidget" name="mVMSettingsPage"> 190 <layout class="QVBoxLayout" name="verticalLayout_4"> 191 <item> 192 <widget class="QLabel" name="mPageSettingsHdr"> 193 <property name="font"> 194 <font> 195 <family>Arial</family> 196 <pointsize>12</pointsize> 197 <weight>75</weight> 198 <bold>true</bold> 199 </font> 200 </property> 201 <property name="text"> 202 <string>Appliance Export Settings</string> 203 </property> 204 </widget> 205 </item> 206 <item> 207 <widget class="Line" name="line21_2"> 208 <property name="orientation"> 209 <enum>Qt::Horizontal</enum> 210 </property> 211 </widget> 212 </item> 213 <item> 214 <layout class="QGridLayout" name="gridLayout_3"> 215 <item row="0" column="0" rowspan="2"> 216 <widget class="QLabel" name="mLogoSettings"> 217 <property name="sizePolicy"> 218 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 219 <horstretch>0</horstretch> 220 <verstretch>0</verstretch> 221 </sizepolicy> 222 </property> 223 <property name="autoFillBackground"> 224 <bool>true</bool> 225 </property> 226 <property name="text"> 227 <string/> 228 </property> 229 <property name="pixmap"> 230 <pixmap resource="../VirtualBox1.qrc">:/vmw_ovf_import.png</pixmap> 231 </property> 232 <property name="alignment"> 233 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 234 </property> 235 </widget> 236 </item> 237 <item row="0" column="1"> 238 <widget class="QILabel" name="mTextSettings"> 239 <property name="sizePolicy"> 240 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 241 <horstretch>0</horstretch> 242 <verstretch>0</verstretch> 243 </sizepolicy> 244 </property> 245 <property name="minimumSize"> 246 <size> 247 <width>300</width> 248 <height>0</height> 249 </size> 250 </property> 251 <property name="text"> 252 <string>Here you can change additional configuration values of the selected virtual machines. You can modify most of the properties shown by double-clicking on the items.</string> 253 </property> 254 <property name="wordWrap"> 255 <bool>true</bool> 256 </property> 257 </widget> 258 </item> 259 <item row="1" column="1"> 260 <widget class="VBoxExportApplianceWgt" name="mExportSettingsWgt" native="true"> 261 <property name="enabled"> 262 <bool>true</bool> 263 </property> 264 <property name="sizePolicy"> 265 <sizepolicy hsizetype="Preferred" vsizetype="MinimumExpanding"> 266 <horstretch>0</horstretch> 267 <verstretch>0</verstretch> 268 </sizepolicy> 269 </property> 270 <property name="minimumSize"> 271 <size> 272 <width>0</width> 273 <height>0</height> 274 </size> 275 </property> 276 <property name="baseSize"> 277 <size> 278 <width>0</width> 279 <height>0</height> 280 </size> 281 </property> 282 </widget> 283 </item> 284 </layout> 285 </item> 286 <item> 287 <widget class="Line" name="line22_2"> 288 <property name="orientation"> 289 <enum>Qt::Horizontal</enum> 290 </property> 291 </widget> 292 </item> 293 <item> 294 <layout class="QHBoxLayout" name="_4"> 295 <item> 296 <widget class="QPushButton" name="mBtnRestore"> 297 <property name="text"> 298 <string>Restore Defaults</string> 299 </property> 300 </widget> 301 </item> 302 <item> 303 <spacer> 304 <property name="orientation"> 305 <enum>Qt::Horizontal</enum> 306 </property> 307 <property name="sizeHint" stdset="0"> 308 <size> 309 <width>0</width> 310 <height>0</height> 311 </size> 312 </property> 313 </spacer> 314 </item> 315 <item> 316 <widget class="QPushButton" name="mBtnBack2"> 317 <property name="text"> 318 <string>< &Back</string> 319 </property> 320 </widget> 321 </item> 322 <item> 323 <widget class="QPushButton" name="mBtnNext2"> 324 <property name="text"> 325 <string>&Next ></string> 326 </property> 327 </widget> 328 </item> 329 <item> 330 <spacer> 331 <property name="orientation"> 332 <enum>Qt::Horizontal</enum> 333 </property> 334 <property name="sizeType"> 335 <enum>QSizePolicy::Fixed</enum> 336 </property> 337 <property name="sizeHint" stdset="0"> 338 <size> 339 <width>5</width> 340 <height>0</height> 341 </size> 342 </property> 343 </spacer> 344 </item> 345 <item> 346 <widget class="QPushButton" name="mBtnCancel2"> 347 <property name="text"> 348 <string>Cancel</string> 349 </property> 350 </widget> 351 </item> 352 </layout> 353 </item> 354 </layout> 355 </widget> 356 <widget class="QWidget" name="mTargetSelectPage"> 357 <layout class="QVBoxLayout" name="verticalLayout_6"> 358 <item> 359 <widget class="QLabel" name="mPageTargetSelectHdr"> 360 <property name="font"> 361 <font> 362 <family>Arial</family> 363 <pointsize>12</pointsize> 364 <weight>75</weight> 365 <bold>true</bold> 366 </font> 367 </property> 368 <property name="text"> 369 <string>Appliance Export Settings</string> 370 </property> 371 </widget> 372 </item> 373 <item> 374 <widget class="Line" name="line21_3"> 375 <property name="orientation"> 376 <enum>Qt::Horizontal</enum> 377 </property> 378 </widget> 379 </item> 380 <item> 381 <layout class="QGridLayout" name="gridLayout_5"> 382 <item row="0" column="0" rowspan="2"> 383 <widget class="QLabel" name="mLogoTargetSelect"> 384 <property name="sizePolicy"> 385 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 386 <horstretch>0</horstretch> 387 <verstretch>0</verstretch> 388 </sizepolicy> 389 </property> 390 <property name="autoFillBackground"> 391 <bool>true</bool> 392 </property> 393 <property name="text"> 394 <string/> 395 </property> 396 <property name="pixmap"> 397 <pixmap resource="../VirtualBox1.qrc">:/vmw_ovf_import.png</pixmap> 398 </property> 399 <property name="alignment"> 400 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 401 </property> 402 </widget> 403 </item> 404 <item row="0" column="1"> 405 <widget class="QILabel" name="mTextTargetSelect"> 406 <property name="sizePolicy"> 407 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 408 <horstretch>0</horstretch> 409 <verstretch>0</verstretch> 410 </sizepolicy> 411 </property> 412 <property name="minimumSize"> 413 <size> 414 <width>300</width> 415 <height>0</height> 416 </size> 417 </property> 418 <property name="text"> 419 <string>Please specify the target for the OVF export. You can choose between a local file system export, uploading the OVF to the Sun Cloud service or an S3 storage server.</string> 420 </property> 421 <property name="wordWrap"> 422 <bool>true</bool> 423 </property> 424 </widget> 425 </item> 426 <item row="1" column="1"> 427 <layout class="QVBoxLayout" name="verticalLayout_5"> 428 <item> 429 <widget class="QRadioButton" name="mRBtnLocalFileSystem"> 430 <property name="text"> 431 <string>&Local Filesystem </string> 432 </property> 433 <property name="checked"> 434 <bool>true</bool> 435 </property> 436 </widget> 437 </item> 438 <item> 439 <widget class="QRadioButton" name="mRBtnSunCloud"> 440 <property name="text"> 441 <string>Sun &Cloud</string> 442 </property> 443 </widget> 444 </item> 445 <item> 446 <widget class="QRadioButton" name="mRBtnS3"> 447 <property name="text"> 448 <string>&Simple Storage System (S3)</string> 449 </property> 450 </widget> 451 </item> 452 <item> 453 <spacer name="verticalSpacer"> 454 <property name="orientation"> 455 <enum>Qt::Vertical</enum> 456 </property> 457 <property name="sizeHint" stdset="0"> 458 <size> 459 <width>20</width> 460 <height>40</height> 461 </size> 462 </property> 463 </spacer> 464 </item> 465 </layout> 466 </item> 467 </layout> 468 </item> 469 <item> 470 <widget class="Line" name="line22_3"> 471 <property name="orientation"> 472 <enum>Qt::Horizontal</enum> 473 </property> 474 </widget> 475 </item> 476 <item> 477 <layout class="QHBoxLayout" name="_6"> 478 <item> 479 <spacer> 480 <property name="orientation"> 481 <enum>Qt::Horizontal</enum> 482 </property> 483 <property name="sizeHint" stdset="0"> 484 <size> 485 <width>0</width> 486 <height>0</height> 487 </size> 488 </property> 489 </spacer> 490 </item> 491 <item> 492 <widget class="QPushButton" name="mBtnBack3"> 493 <property name="text"> 494 <string>< &Back</string> 495 </property> 496 </widget> 497 </item> 498 <item> 499 <widget class="QPushButton" name="mBtnNext3"> 500 <property name="text"> 501 <string>&Next ></string> 502 </property> 503 </widget> 504 </item> 505 <item> 506 <spacer> 507 <property name="orientation"> 508 <enum>Qt::Horizontal</enum> 509 </property> 510 <property name="sizeType"> 511 <enum>QSizePolicy::Fixed</enum> 512 </property> 513 <property name="sizeHint" stdset="0"> 514 <size> 515 <width>5</width> 516 <height>0</height> 517 </size> 518 </property> 519 </spacer> 520 </item> 521 <item> 522 <widget class="QPushButton" name="mBtnCancel3"> 523 <property name="text"> 524 <string>Cancel</string> 525 </property> 526 </widget> 527 </item> 528 </layout> 529 </item> 530 </layout> 531 </widget> 532 <widget class="QWidget" name="mTargetOptionsPage"> 533 <layout class="QVBoxLayout" name="verticalLayout_3"> 534 <item> 535 <widget class="QLabel" name="mPageTargetOptionsHdr"> 536 <property name="font"> 537 <font> 538 <family>Arial</family> 539 <pointsize>12</pointsize> 540 <weight>75</weight> 541 <bold>true</bold> 542 </font> 543 </property> 544 <property name="text"> 545 <string>Appliance Export Settings</string> 546 </property> 547 </widget> 548 </item> 549 <item> 550 <widget class="Line" name="line21"> 551 <property name="orientation"> 552 <enum>Qt::Horizontal</enum> 553 </property> 554 </widget> 555 </item> 556 <item> 557 <layout class="QGridLayout" name="gridLayout_4"> 558 <item row="0" column="0" rowspan="4"> 559 <widget class="QLabel" name="mLogoTargetOptions"> 560 <property name="sizePolicy"> 561 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 562 <horstretch>0</horstretch> 563 <verstretch>0</verstretch> 564 </sizepolicy> 565 </property> 566 <property name="autoFillBackground"> 567 <bool>true</bool> 568 </property> 569 <property name="text"> 570 <string/> 571 </property> 572 <property name="pixmap"> 573 <pixmap resource="../VirtualBox1.qrc">:/vmw_ovf_import.png</pixmap> 574 </property> 575 <property name="alignment"> 576 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 577 </property> 578 </widget> 579 </item> 580 <item row="0" column="1"> 581 <widget class="QILabel" name="mTextTargetOptions"> 582 <property name="sizePolicy"> 583 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 584 <horstretch>0</horstretch> 585 <verstretch>0</verstretch> 586 </sizepolicy> 587 </property> 588 <property name="minimumSize"> 589 <size> 590 <width>300</width> 591 <height>0</height> 592 </size> 593 </property> 594 <property name="wordWrap"> 595 <bool>true</bool> 596 </property> 597 </widget> 598 </item> 599 <item row="1" column="1"> 600 <layout class="QGridLayout" name="gridLayout_2"> 601 <item row="0" column="0"> 602 <widget class="QLabel" name="mLblUsername"> 603 <property name="text"> 604 <string>&Username:</string> 605 </property> 606 <property name="buddy"> 607 <cstring>mLeUsername</cstring> 608 </property> 609 </widget> 610 </item> 611 <item row="0" column="1"> 612 <widget class="QLineEdit" name="mLeUsername"/> 613 </item> 614 <item row="1" column="0"> 615 <widget class="QLabel" name="mLblPassword"> 616 <property name="text"> 617 <string>&Password:</string> 618 </property> 619 <property name="buddy"> 620 <cstring>mLePassword</cstring> 621 </property> 622 </widget> 623 </item> 624 <item row="1" column="1"> 625 <widget class="QLineEdit" name="mLePassword"> 626 <property name="echoMode"> 627 <enum>QLineEdit::Password</enum> 628 </property> 629 </widget> 630 </item> 631 <item row="3" column="1"> 632 <widget class="QLineEdit" name="mLeBucket"/> 633 </item> 634 <item row="5" column="0"> 635 <widget class="QLabel" name="mLblFile"> 636 <property name="text"> 637 <string>&File:</string> 638 </property> 639 <property name="buddy"> 640 <cstring>mFileSelector</cstring> 641 </property> 642 </widget> 643 </item> 644 <item row="5" column="1"> 645 <widget class="VBoxEmptyFileSelector" name="mFileSelector" native="true"/> 646 </item> 647 <item row="3" column="0"> 648 <widget class="QLabel" name="mLblBucket"> 649 <property name="text"> 650 <string>&Bucket:</string> 651 </property> 652 <property name="buddy"> 653 <cstring>mLeBucket</cstring> 654 </property> 655 </widget> 656 </item> 657 <item row="2" column="0"> 658 <widget class="QLabel" name="mLblHostname"> 659 <property name="text"> 660 <string>&Hostname:</string> 661 </property> 662 <property name="buddy"> 663 <cstring>mLeHostname</cstring> 664 </property> 665 </widget> 666 </item> 667 <item row="2" column="1"> 668 <widget class="QLineEdit" name="mLeHostname"/> 669 </item> 670 </layout> 671 </item> 672 <item row="2" column="1"> 673 <widget class="QCheckBox" name="mSelectOVF09"> 674 <property name="toolTip"> 675 <string>Write in legacy OVF 0.9 format for compatibility with other virtualization products.</string> 676 </property> 677 <property name="text"> 678 <string>&Write legacy OVF 0.9</string> 679 </property> 680 </widget> 681 </item> 682 <item row="3" column="1"> 683 <spacer name="spacer"> 684 <property name="orientation"> 685 <enum>Qt::Vertical</enum> 686 </property> 687 <property name="sizeHint" stdset="0"> 688 <size> 689 <width>415</width> 690 <height>46</height> 691 </size> 692 </property> 693 </spacer> 694 </item> 695 </layout> 696 </item> 697 <item> 698 <widget class="Line" name="line22"> 699 <property name="orientation"> 700 <enum>Qt::Horizontal</enum> 701 </property> 702 </widget> 703 </item> 704 <item> 705 <layout class="QHBoxLayout" name="_3"> 706 <item> 707 <spacer> 708 <property name="orientation"> 709 <enum>Qt::Horizontal</enum> 710 </property> 711 <property name="sizeHint" stdset="0"> 712 <size> 713 <width>0</width> 714 <height>0</height> 715 </size> 716 </property> 717 </spacer> 718 </item> 719 <item> 720 <widget class="QPushButton" name="mBtnBack4"> 721 <property name="text"> 722 <string>< &Back</string> 723 </property> 724 </widget> 725 </item> 726 <item> 727 <widget class="QPushButton" name="mBtnFinish"> 728 <property name="text"> 729 <string>&Export ></string> 730 </property> 731 </widget> 732 </item> 733 <item> 734 <spacer> 735 <property name="orientation"> 736 <enum>Qt::Horizontal</enum> 737 </property> 738 <property name="sizeType"> 739 <enum>QSizePolicy::Fixed</enum> 740 </property> 741 <property name="sizeHint" stdset="0"> 742 <size> 743 <width>5</width> 744 <height>0</height> 745 </size> 746 </property> 747 </spacer> 748 </item> 749 <item> 750 <widget class="QPushButton" name="mBtnCancel4"> 751 <property name="text"> 752 <string>Cancel</string> 753 </property> 754 </widget> 755 </item> 756 </layout> 757 </item> 758 </layout> 759 </widget> 45 <property name="wordWrap"> 46 <bool>true</bool> 47 </property> 760 48 </widget> 49 </item> 50 <item> 51 <widget class="QRadioButton" name="m_pTypeLocalFilesystem"> 52 <property name="text"> 53 <string>&Local Filesystem </string> 54 </property> 55 </widget> 56 </item> 57 <item> 58 <widget class="QRadioButton" name="m_pTypeSunCloud"> 59 <property name="text"> 60 <string>Sun &Cloud</string> 61 </property> 62 </widget> 63 </item> 64 <item> 65 <widget class="QRadioButton" name="m_pTypeSimpleStorageSystem"> 66 <property name="text"> 67 <string>&Simple Storage System (S3)</string> 68 </property> 69 </widget> 70 </item> 71 <item> 72 <spacer name="m_pSpacer1"> 73 <property name="orientation"> 74 <enum>Qt::Vertical</enum> 75 </property> 76 <property name="sizeHint" stdset="0"> 77 <size> 78 <width>0</width> 79 <height>252</height> 80 </size> 81 </property> 82 </spacer> 761 83 </item> 762 84 </layout> … … 768 90 <header>QILabel.h</header> 769 91 </customwidget> 770 <customwidget>771 <class>VBoxEmptyFileSelector</class>772 <extends>QWidget</extends>773 <header>VBoxFilePathSelectorWidget.h</header>774 </customwidget>775 <customwidget>776 <class>VBoxExportApplianceWgt</class>777 <extends>QWidget</extends>778 <header>VBoxExportApplianceWgt.h</header>779 <container>1</container>780 </customwidget>781 92 </customwidgets> 782 <tabstops> 783 <tabstop>mVMListWidget</tabstop> 784 <tabstop>mBtnBack1</tabstop> 785 <tabstop>mBtnNext1</tabstop> 786 <tabstop>mBtnCancel1</tabstop> 787 <tabstop>mTargetOptionsPage</tabstop> 788 <tabstop>mBtnRestore</tabstop> 789 <tabstop>mBtnBack2</tabstop> 790 <tabstop>mBtnNext2</tabstop> 791 <tabstop>mBtnCancel2</tabstop> 792 <tabstop>mLeUsername</tabstop> 793 <tabstop>mLePassword</tabstop> 794 <tabstop>mLeHostname</tabstop> 795 <tabstop>mLeBucket</tabstop> 796 <tabstop>mFileSelector</tabstop> 797 <tabstop>mSelectOVF09</tabstop> 798 <tabstop>mBtnBack4</tabstop> 799 <tabstop>mBtnFinish</tabstop> 800 <tabstop>mBtnCancel4</tabstop> 801 </tabstops> 802 <resources> 803 <include location="../VirtualBox1.qrc"/> 804 </resources> 93 <resources/> 805 94 <connections/> 806 95 </ui> -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/exportappliance/UIExportApplianceWzdPage4.ui
r25432 r26079 2 2 <ui version="4.0"> 3 3 <comment> 4 VBox frontends: Qt4 GUI ( "VirtualBox"):4 VBox frontends: Qt4 GUI ("VirtualBox"): 5 5 6 Copyright (C) 2009 Sun Microsystems, Inc.6 Copyright (C) 2009-2010 Sun Microsystems, Inc. 7 7 8 8 This file is part of VirtualBox Open Source Edition (OSE), as … … 18 18 additional information or have any questions. 19 19 </comment> 20 <class> VBoxExportApplianceWzd</class>21 <widget class="QWidget" name=" VBoxExportApplianceWzd">20 <class>UIExportApplianceWzdPage4</class> 21 <widget class="QWidget" name="UIExportApplianceWzdPage4"> 22 22 <property name="geometry"> 23 23 <rect> 24 24 <x>0</x> 25 25 <y>0</y> 26 <width> 556</width>27 <height>4 52</height>26 <width>600</width> 27 <height>400</height> 28 28 </rect> 29 29 </property> 30 <property name="windowTitle"> 31 <string>Appliance Export Wizard</string> 30 <property name="sizePolicy"> 31 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 32 <horstretch>0</horstretch> 33 <verstretch>0</verstretch> 34 </sizepolicy> 32 35 </property> 33 <layout class="QVBoxLayout" name=" verticalLayout">34 <property name=" margin">36 <layout class="QVBoxLayout" name="m_pLayout1"> 37 <property name="bottomMargin" > 35 38 <number>0</number> 36 39 </property> 37 40 <item> 38 <widget class="Q StackedWidget" name="mPageStack">39 <property name=" currentIndex">40 < number>2</number>41 <widget class="QILabel" name="m_pPage4Text1"> 42 <property name="wordWrap"> 43 <bool>true</bool> 41 44 </property> 42 <widget class="QWidget" name="mVMSelectPage">43 <layout class="QVBoxLayout" name="verticalLayout_2">44 <item>45 <widget class="QLabel" name="mPageWelcomeHdr">46 <property name="font">47 <font>48 <family>Arial</family>49 <pointsize>12</pointsize>50 <weight>75</weight>51 <bold>true</bold>52 </font>53 </property>54 <property name="text">55 <string>Welcome to the Appliance Export Wizard!</string>56 </property>57 </widget>58 </item>59 <item>60 <widget class="Line" name="line11">61 <property name="orientation">62 <enum>Qt::Horizontal</enum>63 </property>64 </widget>65 </item>66 <item>67 <layout class="QGridLayout" name="gridLayout">68 <item row="0" column="0" rowspan="3">69 <widget class="QLabel" name="mLogoWelcome">70 <property name="sizePolicy">71 <sizepolicy hsizetype="Maximum" vsizetype="Minimum">72 <horstretch>0</horstretch>73 <verstretch>0</verstretch>74 </sizepolicy>75 </property>76 <property name="autoFillBackground">77 <bool>true</bool>78 </property>79 <property name="text">80 <string/>81 </property>82 <property name="pixmap">83 <pixmap resource="../VirtualBox1.qrc">:/vmw_ovf_import.png</pixmap>84 </property>85 <property name="alignment">86 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set>87 </property>88 </widget>89 </item>90 <item row="0" column="1">91 <widget class="QILabel" name="mTextWelcome">92 <property name="sizePolicy">93 <sizepolicy hsizetype="Minimum" vsizetype="Minimum">94 <horstretch>0</horstretch>95 <verstretch>0</verstretch>96 </sizepolicy>97 </property>98 <property name="minimumSize">99 <size>100 <width>300</width>101 <height>0</height>102 </size>103 </property>104 <property name="text">105 <string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">106 <html><head><meta name="qrichtext" content="1" /><style type="text/css">107 p, li { white-space: pre-wrap; }108 </style></head><body>109 <p style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">This wizard will guide you through the process of exporting an appliance. </p>110 <p style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Use the <span style=" font-weight:600;">Next</span> button to go the next page of the wizard and the <span style=" font-weight:600;">Back</span> button to return to the previous page.</p>111 <p style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Please select the virtual machines that you wish to the appliance. You can select more than one. Please note that these machines have to be turned off before they can be exported.</p></body></html></string>112 </property>113 <property name="wordWrap">114 <bool>true</bool>115 </property>116 </widget>117 </item>118 <item row="1" column="1">119 <widget class="QListWidget" name="mVMListWidget"/>120 </item>121 </layout>122 </item>123 <item>124 <widget class="Line" name="line12">125 <property name="orientation">126 <enum>Qt::Horizontal</enum>127 </property>128 </widget>129 </item>130 <item>131 <layout class="QHBoxLayout" name="_2">132 <item>133 <spacer>134 <property name="orientation">135 <enum>Qt::Horizontal</enum>136 </property>137 <property name="sizeHint" stdset="0">138 <size>139 <width>0</width>140 <height>0</height>141 </size>142 </property>143 </spacer>144 </item>145 <item>146 <widget class="QPushButton" name="mBtnBack1">147 <property name="enabled">148 <bool>false</bool>149 </property>150 <property name="text">151 <string>< &Back</string>152 </property>153 </widget>154 </item>155 <item>156 <widget class="QPushButton" name="mBtnNext1">157 <property name="text">158 <string>&Next ></string>159 </property>160 </widget>161 </item>162 <item>163 <spacer>164 <property name="orientation">165 <enum>Qt::Horizontal</enum>166 </property>167 <property name="sizeType">168 <enum>QSizePolicy::Fixed</enum>169 </property>170 <property name="sizeHint" stdset="0">171 <size>172 <width>5</width>173 <height>0</height>174 </size>175 </property>176 </spacer>177 </item>178 <item>179 <widget class="QPushButton" name="mBtnCancel1">180 <property name="text">181 <string>Cancel</string>182 </property>183 </widget>184 </item>185 </layout>186 </item>187 </layout>188 </widget>189 <widget class="QWidget" name="mVMSettingsPage">190 <layout class="QVBoxLayout" name="verticalLayout_4">191 <item>192 <widget class="QLabel" name="mPageSettingsHdr">193 <property name="font">194 <font>195 <family>Arial</family>196 <pointsize>12</pointsize>197 <weight>75</weight>198 <bold>true</bold>199 </font>200 </property>201 <property name="text">202 <string>Appliance Export Settings</string>203 </property>204 </widget>205 </item>206 <item>207 <widget class="Line" name="line21_2">208 <property name="orientation">209 <enum>Qt::Horizontal</enum>210 </property>211 </widget>212 </item>213 <item>214 <layout class="QGridLayout" name="gridLayout_3">215 <item row="0" column="0" rowspan="2">216 <widget class="QLabel" name="mLogoSettings">217 <property name="sizePolicy">218 <sizepolicy hsizetype="Maximum" vsizetype="Minimum">219 <horstretch>0</horstretch>220 <verstretch>0</verstretch>221 </sizepolicy>222 </property>223 <property name="autoFillBackground">224 <bool>true</bool>225 </property>226 <property name="text">227 <string/>228 </property>229 <property name="pixmap">230 <pixmap resource="../VirtualBox1.qrc">:/vmw_ovf_import.png</pixmap>231 </property>232 <property name="alignment">233 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set>234 </property>235 </widget>236 </item>237 <item row="0" column="1">238 <widget class="QILabel" name="mTextSettings">239 <property name="sizePolicy">240 <sizepolicy hsizetype="Minimum" vsizetype="Minimum">241 <horstretch>0</horstretch>242 <verstretch>0</verstretch>243 </sizepolicy>244 </property>245 <property name="minimumSize">246 <size>247 <width>300</width>248 <height>0</height>249 </size>250 </property>251 <property name="text">252 <string>Here you can change additional configuration values of the selected virtual machines. You can modify most of the properties shown by double-clicking on the items.</string>253 </property>254 <property name="wordWrap">255 <bool>true</bool>256 </property>257 </widget>258 </item>259 <item row="1" column="1">260 <widget class="VBoxExportApplianceWgt" name="mExportSettingsWgt" native="true">261 <property name="enabled">262 <bool>true</bool>263 </property>264 <property name="sizePolicy">265 <sizepolicy hsizetype="Preferred" vsizetype="MinimumExpanding">266 <horstretch>0</horstretch>267 <verstretch>0</verstretch>268 </sizepolicy>269 </property>270 <property name="minimumSize">271 <size>272 <width>0</width>273 <height>0</height>274 </size>275 </property>276 <property name="baseSize">277 <size>278 <width>0</width>279 <height>0</height>280 </size>281 </property>282 </widget>283 </item>284 </layout>285 </item>286 <item>287 <widget class="Line" name="line22_2">288 <property name="orientation">289 <enum>Qt::Horizontal</enum>290 </property>291 </widget>292 </item>293 <item>294 <layout class="QHBoxLayout" name="_4">295 <item>296 <widget class="QPushButton" name="mBtnRestore">297 <property name="text">298 <string>Restore Defaults</string>299 </property>300 </widget>301 </item>302 <item>303 <spacer>304 <property name="orientation">305 <enum>Qt::Horizontal</enum>306 </property>307 <property name="sizeHint" stdset="0">308 <size>309 <width>0</width>310 <height>0</height>311 </size>312 </property>313 </spacer>314 </item>315 <item>316 <widget class="QPushButton" name="mBtnBack2">317 <property name="text">318 <string>< &Back</string>319 </property>320 </widget>321 </item>322 <item>323 <widget class="QPushButton" name="mBtnNext2">324 <property name="text">325 <string>&Next ></string>326 </property>327 </widget>328 </item>329 <item>330 <spacer>331 <property name="orientation">332 <enum>Qt::Horizontal</enum>333 </property>334 <property name="sizeType">335 <enum>QSizePolicy::Fixed</enum>336 </property>337 <property name="sizeHint" stdset="0">338 <size>339 <width>5</width>340 <height>0</height>341 </size>342 </property>343 </spacer>344 </item>345 <item>346 <widget class="QPushButton" name="mBtnCancel2">347 <property name="text">348 <string>Cancel</string>349 </property>350 </widget>351 </item>352 </layout>353 </item>354 </layout>355 </widget>356 <widget class="QWidget" name="mTargetSelectPage">357 <layout class="QVBoxLayout" name="verticalLayout_6">358 <item>359 <widget class="QLabel" name="mPageTargetSelectHdr">360 <property name="font">361 <font>362 <family>Arial</family>363 <pointsize>12</pointsize>364 <weight>75</weight>365 <bold>true</bold>366 </font>367 </property>368 <property name="text">369 <string>Appliance Export Settings</string>370 </property>371 </widget>372 </item>373 <item>374 <widget class="Line" name="line21_3">375 <property name="orientation">376 <enum>Qt::Horizontal</enum>377 </property>378 </widget>379 </item>380 <item>381 <layout class="QGridLayout" name="gridLayout_5">382 <item row="0" column="0" rowspan="2">383 <widget class="QLabel" name="mLogoTargetSelect">384 <property name="sizePolicy">385 <sizepolicy hsizetype="Maximum" vsizetype="Minimum">386 <horstretch>0</horstretch>387 <verstretch>0</verstretch>388 </sizepolicy>389 </property>390 <property name="autoFillBackground">391 <bool>true</bool>392 </property>393 <property name="text">394 <string/>395 </property>396 <property name="pixmap">397 <pixmap resource="../VirtualBox1.qrc">:/vmw_ovf_import.png</pixmap>398 </property>399 <property name="alignment">400 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set>401 </property>402 </widget>403 </item>404 <item row="0" column="1">405 <widget class="QILabel" name="mTextTargetSelect">406 <property name="sizePolicy">407 <sizepolicy hsizetype="Minimum" vsizetype="Minimum">408 <horstretch>0</horstretch>409 <verstretch>0</verstretch>410 </sizepolicy>411 </property>412 <property name="minimumSize">413 <size>414 <width>300</width>415 <height>0</height>416 </size>417 </property>418 <property name="text">419 <string>Please specify the target for the OVF export. You can choose between a local file system export, uploading the OVF to the Sun Cloud service or an S3 storage server.</string>420 </property>421 <property name="wordWrap">422 <bool>true</bool>423 </property>424 </widget>425 </item>426 <item row="1" column="1">427 <layout class="QVBoxLayout" name="verticalLayout_5">428 <item>429 <widget class="QRadioButton" name="mRBtnLocalFileSystem">430 <property name="text">431 <string>&Local Filesystem </string>432 </property>433 <property name="checked">434 <bool>true</bool>435 </property>436 </widget>437 </item>438 <item>439 <widget class="QRadioButton" name="mRBtnSunCloud">440 <property name="text">441 <string>Sun &Cloud</string>442 </property>443 </widget>444 </item>445 <item>446 <widget class="QRadioButton" name="mRBtnS3">447 <property name="text">448 <string>&Simple Storage System (S3)</string>449 </property>450 </widget>451 </item>452 <item>453 <spacer name="verticalSpacer">454 <property name="orientation">455 <enum>Qt::Vertical</enum>456 </property>457 <property name="sizeHint" stdset="0">458 <size>459 <width>20</width>460 <height>40</height>461 </size>462 </property>463 </spacer>464 </item>465 </layout>466 </item>467 </layout>468 </item>469 <item>470 <widget class="Line" name="line22_3">471 <property name="orientation">472 <enum>Qt::Horizontal</enum>473 </property>474 </widget>475 </item>476 <item>477 <layout class="QHBoxLayout" name="_6">478 <item>479 <spacer>480 <property name="orientation">481 <enum>Qt::Horizontal</enum>482 </property>483 <property name="sizeHint" stdset="0">484 <size>485 <width>0</width>486 <height>0</height>487 </size>488 </property>489 </spacer>490 </item>491 <item>492 <widget class="QPushButton" name="mBtnBack3">493 <property name="text">494 <string>< &Back</string>495 </property>496 </widget>497 </item>498 <item>499 <widget class="QPushButton" name="mBtnNext3">500 <property name="text">501 <string>&Next ></string>502 </property>503 </widget>504 </item>505 <item>506 <spacer>507 <property name="orientation">508 <enum>Qt::Horizontal</enum>509 </property>510 <property name="sizeType">511 <enum>QSizePolicy::Fixed</enum>512 </property>513 <property name="sizeHint" stdset="0">514 <size>515 <width>5</width>516 <height>0</height>517 </size>518 </property>519 </spacer>520 </item>521 <item>522 <widget class="QPushButton" name="mBtnCancel3">523 <property name="text">524 <string>Cancel</string>525 </property>526 </widget>527 </item>528 </layout>529 </item>530 </layout>531 </widget>532 <widget class="QWidget" name="mTargetOptionsPage">533 <layout class="QVBoxLayout" name="verticalLayout_3">534 <item>535 <widget class="QLabel" name="mPageTargetOptionsHdr">536 <property name="font">537 <font>538 <family>Arial</family>539 <pointsize>12</pointsize>540 <weight>75</weight>541 <bold>true</bold>542 </font>543 </property>544 <property name="text">545 <string>Appliance Export Settings</string>546 </property>547 </widget>548 </item>549 <item>550 <widget class="Line" name="line21">551 <property name="orientation">552 <enum>Qt::Horizontal</enum>553 </property>554 </widget>555 </item>556 <item>557 <layout class="QGridLayout" name="gridLayout_4">558 <item row="0" column="0" rowspan="4">559 <widget class="QLabel" name="mLogoTargetOptions">560 <property name="sizePolicy">561 <sizepolicy hsizetype="Maximum" vsizetype="Minimum">562 <horstretch>0</horstretch>563 <verstretch>0</verstretch>564 </sizepolicy>565 </property>566 <property name="autoFillBackground">567 <bool>true</bool>568 </property>569 <property name="text">570 <string/>571 </property>572 <property name="pixmap">573 <pixmap resource="../VirtualBox1.qrc">:/vmw_ovf_import.png</pixmap>574 </property>575 <property name="alignment">576 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set>577 </property>578 </widget>579 </item>580 <item row="0" column="1">581 <widget class="QILabel" name="mTextTargetOptions">582 <property name="sizePolicy">583 <sizepolicy hsizetype="Minimum" vsizetype="Minimum">584 <horstretch>0</horstretch>585 <verstretch>0</verstretch>586 </sizepolicy>587 </property>588 <property name="minimumSize">589 <size>590 <width>300</width>591 <height>0</height>592 </size>593 </property>594 <property name="wordWrap">595 <bool>true</bool>596 </property>597 </widget>598 </item>599 <item row="1" column="1">600 <layout class="QGridLayout" name="gridLayout_2">601 <item row="0" column="0">602 <widget class="QLabel" name="mLblUsername">603 <property name="text">604 <string>&Username:</string>605 </property>606 <property name="buddy">607 <cstring>mLeUsername</cstring>608 </property>609 </widget>610 </item>611 <item row="0" column="1">612 <widget class="QLineEdit" name="mLeUsername"/>613 </item>614 <item row="1" column="0">615 <widget class="QLabel" name="mLblPassword">616 <property name="text">617 <string>&Password:</string>618 </property>619 <property name="buddy">620 <cstring>mLePassword</cstring>621 </property>622 </widget>623 </item>624 <item row="1" column="1">625 <widget class="QLineEdit" name="mLePassword">626 <property name="echoMode">627 <enum>QLineEdit::Password</enum>628 </property>629 </widget>630 </item>631 <item row="3" column="1">632 <widget class="QLineEdit" name="mLeBucket"/>633 </item>634 <item row="5" column="0">635 <widget class="QLabel" name="mLblFile">636 <property name="text">637 <string>&File:</string>638 </property>639 <property name="buddy">640 <cstring>mFileSelector</cstring>641 </property>642 </widget>643 </item>644 <item row="5" column="1">645 <widget class="VBoxEmptyFileSelector" name="mFileSelector" native="true"/>646 </item>647 <item row="3" column="0">648 <widget class="QLabel" name="mLblBucket">649 <property name="text">650 <string>&Bucket:</string>651 </property>652 <property name="buddy">653 <cstring>mLeBucket</cstring>654 </property>655 </widget>656 </item>657 <item row="2" column="0">658 <widget class="QLabel" name="mLblHostname">659 <property name="text">660 <string>&Hostname:</string>661 </property>662 <property name="buddy">663 <cstring>mLeHostname</cstring>664 </property>665 </widget>666 </item>667 <item row="2" column="1">668 <widget class="QLineEdit" name="mLeHostname"/>669 </item>670 </layout>671 </item>672 <item row="2" column="1">673 <widget class="QCheckBox" name="mSelectOVF09">674 <property name="toolTip">675 <string>Write in legacy OVF 0.9 format for compatibility with other virtualization products.</string>676 </property>677 <property name="text">678 <string>&Write legacy OVF 0.9</string>679 </property>680 </widget>681 </item>682 <item row="3" column="1">683 <spacer name="spacer">684 <property name="orientation">685 <enum>Qt::Vertical</enum>686 </property>687 <property name="sizeHint" stdset="0">688 <size>689 <width>415</width>690 <height>46</height>691 </size>692 </property>693 </spacer>694 </item>695 </layout>696 </item>697 <item>698 <widget class="Line" name="line22">699 <property name="orientation">700 <enum>Qt::Horizontal</enum>701 </property>702 </widget>703 </item>704 <item>705 <layout class="QHBoxLayout" name="_3">706 <item>707 <spacer>708 <property name="orientation">709 <enum>Qt::Horizontal</enum>710 </property>711 <property name="sizeHint" stdset="0">712 <size>713 <width>0</width>714 <height>0</height>715 </size>716 </property>717 </spacer>718 </item>719 <item>720 <widget class="QPushButton" name="mBtnBack4">721 <property name="text">722 <string>< &Back</string>723 </property>724 </widget>725 </item>726 <item>727 <widget class="QPushButton" name="mBtnFinish">728 <property name="text">729 <string>&Export ></string>730 </property>731 </widget>732 </item>733 <item>734 <spacer>735 <property name="orientation">736 <enum>Qt::Horizontal</enum>737 </property>738 <property name="sizeType">739 <enum>QSizePolicy::Fixed</enum>740 </property>741 <property name="sizeHint" stdset="0">742 <size>743 <width>5</width>744 <height>0</height>745 </size>746 </property>747 </spacer>748 </item>749 <item>750 <widget class="QPushButton" name="mBtnCancel4">751 <property name="text">752 <string>Cancel</string>753 </property>754 </widget>755 </item>756 </layout>757 </item>758 </layout>759 </widget>760 45 </widget> 46 </item> 47 <item> 48 <layout class="QGridLayout" name="m_pLayout2"> 49 <item row="0" column="0"> 50 <widget class="QLabel" name="m_pTxUsername"> 51 <property name="text"> 52 <string>&Username:</string> 53 </property> 54 <property name="alignment"> 55 <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> 56 </property> 57 <property name="buddy"> 58 <cstring>m_pLeUsername</cstring> 59 </property> 60 </widget> 61 </item> 62 <item row="0" column="1"> 63 <widget class="QLineEdit" name="m_pLeUsername"/> 64 </item> 65 <item row="1" column="0"> 66 <widget class="QLabel" name="m_pTxPassword"> 67 <property name="text"> 68 <string>&Password:</string> 69 </property> 70 <property name="alignment"> 71 <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> 72 </property> 73 <property name="buddy"> 74 <cstring>m_pLePassword</cstring> 75 </property> 76 </widget> 77 </item> 78 <item row="1" column="1"> 79 <widget class="QLineEdit" name="m_pLePassword"> 80 <property name="echoMode"> 81 <enum>QLineEdit::Password</enum> 82 </property> 83 </widget> 84 </item> 85 <item row="2" column="0"> 86 <widget class="QLabel" name="m_pTxHostname"> 87 <property name="text"> 88 <string>&Hostname:</string> 89 </property> 90 <property name="alignment"> 91 <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> 92 </property> 93 <property name="buddy"> 94 <cstring>m_pLeHostname</cstring> 95 </property> 96 </widget> 97 </item> 98 <item row="2" column="1"> 99 <widget class="QLineEdit" name="m_pLeHostname"/> 100 </item> 101 <item row="3" column="0"> 102 <widget class="QLabel" name="m_pTxBucket"> 103 <property name="text"> 104 <string>&Bucket:</string> 105 </property> 106 <property name="alignment"> 107 <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> 108 </property> 109 <property name="buddy"> 110 <cstring>m_pLeBucket</cstring> 111 </property> 112 </widget> 113 </item> 114 <item row="3" column="1"> 115 <widget class="QLineEdit" name="m_pLeBucket"/> 116 </item> 117 <item row="5" column="0"> 118 <widget class="QLabel" name="m_pTxFile"> 119 <property name="text"> 120 <string>&File:</string> 121 </property> 122 <property name="alignment"> 123 <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> 124 </property> 125 <property name="buddy"> 126 <cstring>m_pFileSelector</cstring> 127 </property> 128 </widget> 129 </item> 130 <item row="5" column="1"> 131 <widget class="VBoxEmptyFileSelector" name="m_pFileSelector" native="true"/> 132 </item> 133 </layout> 134 </item> 135 <item> 136 <widget class="QCheckBox" name="m_pSelectOVF09"> 137 <property name="toolTip"> 138 <string>Write in legacy OVF 0.9 format for compatibility with other virtualization products.</string> 139 </property> 140 <property name="text"> 141 <string>&Write legacy OVF 0.9</string> 142 </property> 143 </widget> 144 </item> 145 <item> 146 <spacer name="m_pSpacer1"> 147 <property name="sizeHint" stdset="0"> 148 <size> 149 <width>0</width> 150 <height>174</height> 151 </size> 152 </property> 153 </spacer> 761 154 </item> 762 155 </layout> … … 773 166 <header>VBoxFilePathSelectorWidget.h</header> 774 167 </customwidget> 775 <customwidget>776 <class>VBoxExportApplianceWgt</class>777 <extends>QWidget</extends>778 <header>VBoxExportApplianceWgt.h</header>779 <container>1</container>780 </customwidget>781 168 </customwidgets> 782 <tabstops> 783 <tabstop>mVMListWidget</tabstop> 784 <tabstop>mBtnBack1</tabstop> 785 <tabstop>mBtnNext1</tabstop> 786 <tabstop>mBtnCancel1</tabstop> 787 <tabstop>mTargetOptionsPage</tabstop> 788 <tabstop>mBtnRestore</tabstop> 789 <tabstop>mBtnBack2</tabstop> 790 <tabstop>mBtnNext2</tabstop> 791 <tabstop>mBtnCancel2</tabstop> 792 <tabstop>mLeUsername</tabstop> 793 <tabstop>mLePassword</tabstop> 794 <tabstop>mLeHostname</tabstop> 795 <tabstop>mLeBucket</tabstop> 796 <tabstop>mFileSelector</tabstop> 797 <tabstop>mSelectOVF09</tabstop> 798 <tabstop>mBtnBack4</tabstop> 799 <tabstop>mBtnFinish</tabstop> 800 <tabstop>mBtnCancel4</tabstop> 801 </tabstops> 802 <resources> 803 <include location="../VirtualBox1.qrc"/> 804 </resources> 169 <resources/> 805 170 <connections/> 806 171 </ui> -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/firstrun/UIFirstRunWzd.cpp
r25432 r26079 2 2 * 3 3 * VBox frontends: Qt4 GUI ("VirtualBox"): 4 * VBoxVMFirstRunWzd class implementation4 * UIFirstRunWzd class implementation 5 5 */ 6 6 7 7 /* 8 * Copyright (C) 2008-20 09Sun Microsystems, Inc.8 * Copyright (C) 2008-2010 Sun Microsystems, Inc. 9 9 * 10 10 * This file is part of VirtualBox Open Source Edition (OSE), as … … 22 22 23 23 /* Local includes */ 24 #include " VBoxVMFirstRunWzd.h"24 #include "UIFirstRunWzd.h" 25 25 #include "VBoxGlobal.h" 26 26 #include "VBoxProblemReporter.h" 27 27 #include "VBoxMediaManagerDlg.h" 28 #include "QIWidgetValidator.h" 29 30 VBoxVMFirstRunWzd::VBoxVMFirstRunWzd (const CMachine &aMachine, QWidget *aParent) 31 : QIWithRetranslateUI <QIAbstractWizard> (aParent) 32 , mValidator (0) 33 , mMachine (aMachine) 34 { 35 /* Apply UI decorations */ 36 Ui::VBoxVMFirstRunWzd::setupUi (this); 37 38 /* Initialize wizard hdr */ 39 initializeWizardHdr(); 28 #include "VBoxVMSettingsHD.h" 29 30 UIFirstRunWzd::UIFirstRunWzd(QWidget *pParent, const CMachine &machine) : QIWizard(pParent) 31 { 32 /* Create & add pages */ 33 UIFirstRunWzdPage1 *pPage1 = new UIFirstRunWzdPage1; 34 UIFirstRunWzdPage2 *pPage2 = new UIFirstRunWzdPage2; 35 UIFirstRunWzdPage3 *pPage3 = new UIFirstRunWzdPage3; 36 37 addPage(pPage1); 38 addPage(pPage2); 39 addPage(pPage3); 40 41 /* Set 'machine' field value for page 3 */ 42 setField("machine", QVariant::fromValue(machine)); 43 44 /* Init pages basing on machine set */ 45 pPage1->init(); 46 pPage2->init(); 47 pPage3->init(); 48 49 /* Translate */ 50 retranslateUi(); 51 52 /* Resize to 'golden ratio' */ 53 resizeToGoldenRatio(); 54 55 /* Assign watermark */ 56 assignWatermark(":/vmw_new_welcome.png"); 57 } 58 59 void UIFirstRunWzd::retranslateUi() 60 { 61 /* Wizard title */ 62 setWindowTitle(tr("First Run Wizard")); 63 } 64 65 UIFirstRunWzdPage1::UIFirstRunWzdPage1() 66 { 67 /* Decorate page */ 68 Ui::UIFirstRunWzdPage1::setupUi(this); 69 70 /* Translate */ 71 retranslateUi(); 72 } 73 74 void UIFirstRunWzdPage1::init() 75 { 76 /* Current machine */ 77 CMachine machine = field("machine").value<CMachine>(); 78 AssertMsg(!machine.isNull(), ("Field 'machine' must be set!\n")); 40 79 41 80 /* Hide unnecessary text labels */ 42 CMediumAttachment hda = mMachine.GetMediumAttachment ("IDE Controller", 0, 0); 43 mTextWelcome1->setHidden (hda.isNull()); 44 mTextType1->setHidden (hda.isNull()); 45 mTextSource1->setHidden (hda.isNull()); 46 mTextSummaryHdr1->setHidden (hda.isNull()); 47 mTextSummaryFtr1->setHidden (hda.isNull()); 48 mTextWelcome2->setHidden (!hda.isNull()); 49 mTextType2->setHidden (!hda.isNull()); 50 mTextSource2->setHidden (!hda.isNull()); 51 mTextSummaryHdr2->setHidden (!hda.isNull()); 52 mTextSummaryFtr2->setHidden (!hda.isNull()); 53 54 /* Media page */ 55 mCbMedia->setMachineId (mMachine.GetId()); 56 mTbVmm->setIcon (VBoxGlobal::iconSet (":/select_file_16px.png", ":/select_file_dis_16px.png")); 57 mValidator = new QIWidgetValidator (mPageMedia, this); 58 connect (mValidator, SIGNAL (validityChanged (const QIWidgetValidator *)), 59 this, SLOT (enableNext (const QIWidgetValidator *))); 60 connect (mValidator, SIGNAL (isValidRequested (QIWidgetValidator *)), 61 this, SLOT (revalidate (QIWidgetValidator *))); 62 connect (mRbCdType, SIGNAL (clicked()), this, SLOT (mediaTypeChanged())); 63 connect (mRbFdType, SIGNAL (clicked()), this, SLOT (mediaTypeChanged())); 64 connect (mTbVmm, SIGNAL (clicked()), this, SLOT (openMediaManager())); 65 mRbCdType->animateClick(); 66 67 /* Revalidate updated page */ 68 mValidator->revalidate(); 69 70 /* Initialize wizard ftr */ 71 initializeWizardFtr(); 72 73 retranslateUi(); 74 } 75 76 void VBoxVMFirstRunWzd::retranslateUi() 81 CMediumAttachment hda = machine.GetMediumAttachment(VBoxVMSettingsHD::tr("IDE Controller"), 0, 0); 82 m_pPage1Text1Var1->setHidden(hda.isNull()); 83 m_pPage1Text1Var2->setHidden(!hda.isNull()); 84 } 85 86 void UIFirstRunWzdPage1::retranslateUi() 77 87 { 78 88 /* Translate uic generated strings */ 79 Ui::VBoxVMFirstRunWzd::retranslateUi (this); 80 81 QWidget *page = mPageStack->currentWidget(); 82 83 if (page == mPageSummary) 84 { 85 /* Compose Summary */ 86 QString type = mRbCdType->isChecked() ? tr ("CD/DVD-ROM Device") : tr ("Floppy Device"); 87 QString source = mCbMedia->currentText(); 88 QString summary = QString ("<table>" 89 "<tr><td>%1: </td><td>%2</td></tr>" 90 "<tr><td>%3: </td><td>%4</td></tr>" 91 "</table>") 92 .arg (tr ("Type", "summary"), type) 93 .arg (tr ("Source", "summary"), source); 94 mTeSummary->setText (summary); 95 } 96 } 97 98 void VBoxVMFirstRunWzd::accept() 89 Ui::UIFirstRunWzdPage1::retranslateUi(this); 90 91 /* Wizard page 1 title */ 92 setTitle(tr("Welcome to the First Run Wizard!")); 93 } 94 95 UIFirstRunWzdPage2::UIFirstRunWzdPage2() 96 { 97 /* Decorate page */ 98 Ui::UIFirstRunWzdPage2::setupUi(this); 99 100 /* Register KStorageBus class */ 101 qRegisterMetaType<KStorageBus>(); 102 103 /* Register 'type', 'description', 'source', 'id' fields! */ 104 registerField("bus", this, "bus"); 105 registerField("description", this, "description"); 106 registerField("source", this, "source"); 107 registerField("id", this, "id"); 108 109 /* Setup contents */ 110 m_pSelectMediaButton->setIcon(VBoxGlobal::iconSet(":/select_file_16px.png", ":/select_file_dis_16px.png")); 111 112 /* Setup connections */ 113 connect (m_pTypeCD, SIGNAL(clicked()), this, SLOT(sltMediumChanged())); 114 connect (m_pTypeFD, SIGNAL(clicked()), this, SLOT(sltMediumChanged())); 115 connect (m_pMediaSelector, SIGNAL(currentIndexChanged(int)), this, SLOT(sltMediumChanged())); 116 connect (m_pSelectMediaButton, SIGNAL(clicked()), this, SLOT(sltOpenVirtualMediaManager())); 117 118 /* Translate */ 119 retranslateUi(); 120 } 121 122 void UIFirstRunWzdPage2::init() 123 { 124 /* Current machine */ 125 CMachine machine = field("machine").value<CMachine>(); 126 AssertMsg(!machine.isNull(), ("Field 'machine' must be set!\n")); 127 128 /* Hide unnecessary text labels */ 129 CMediumAttachment hda = machine.GetMediumAttachment(VBoxVMSettingsHD::tr("IDE Controller"), 0, 0); 130 m_pPage2Text1Var1->setHidden(hda.isNull()); 131 m_pPage2Text1Var2->setHidden(!hda.isNull()); 132 m_pPage2Text2Var1->setHidden(hda.isNull()); 133 m_pPage2Text2Var2->setHidden(!hda.isNull()); 134 135 /* Assign selector machine */ 136 m_pMediaSelector->setMachineId(machine.GetId()); 137 } 138 139 void UIFirstRunWzdPage2::retranslateUi() 140 { 141 /* Translate uic generated strings */ 142 Ui::UIFirstRunWzdPage2::retranslateUi(this); 143 144 /* Wizard page 2 title */ 145 setTitle(tr("Select Installation Media")); 146 } 147 148 void UIFirstRunWzdPage2::initializePage() 149 { 150 /* Translate */ 151 retranslateUi(); 152 153 /* Initial choice */ 154 m_pTypeCD->click(); 155 m_pMediaSelector->setCurrentIndex(0); 156 157 /* CD button should initially have focus */ 158 m_pTypeCD->isChecked(); 159 } 160 161 bool UIFirstRunWzdPage2::isComplete() const 162 { 163 return !vboxGlobal().findMedium(field("id").toString()).isNull(); 164 } 165 166 void UIFirstRunWzdPage2::sltMediumChanged() 167 { 168 /* Update data */ 169 if (m_pTypeCD->isChecked()) 170 { 171 if (m_pMediaSelector->type() != VBoxDefs::MediumType_DVD) 172 { 173 m_pMediaSelector->setType(VBoxDefs::MediumType_DVD); 174 m_pMediaSelector->repopulate(); 175 } 176 m_Bus = KStorageBus_IDE; 177 m_strDescription = VBoxGlobal::removeAccelMark(m_pTypeCD->text()); 178 m_strSource = m_pMediaSelector->currentText(); 179 m_strId = m_pMediaSelector->id(); 180 } 181 else if (m_pTypeFD->isChecked()) 182 { 183 if (m_pMediaSelector->type() != VBoxDefs::MediumType_Floppy) 184 { 185 m_pMediaSelector->setType(VBoxDefs::MediumType_Floppy); 186 m_pMediaSelector->repopulate(); 187 } 188 m_Bus = KStorageBus_Floppy; 189 m_strDescription = VBoxGlobal::removeAccelMark(m_pTypeFD->text()); 190 m_strSource = m_pMediaSelector->currentText(); 191 m_strId = m_pMediaSelector->id(); 192 } 193 else 194 { 195 m_Bus = KStorageBus_Null; 196 m_strDescription.clear(); 197 m_strSource.clear(); 198 m_strId.clear(); 199 } 200 201 emit completeChanged(); 202 } 203 204 void UIFirstRunWzdPage2::sltOpenVirtualMediaManager() 205 { 206 /* Create & open VMM */ 207 VBoxMediaManagerDlg dlg(this); 208 dlg.setup(m_pMediaSelector->type(), true /* aDoSelect */); 209 if (dlg.exec() == QDialog::Accepted) 210 m_pMediaSelector->setCurrentItem(dlg.selectedId()); 211 } 212 213 UIFirstRunWzdPage3::UIFirstRunWzdPage3() 214 { 215 /* Decorate page */ 216 Ui::UIFirstRunWzdPage3::setupUi(this); 217 218 /* Register CMachine class */ 219 qRegisterMetaType<CMachine>(); 220 221 /* Register 'machine' field */ 222 registerField("machine", this, "machine"); 223 224 /* Disable the background painting of the summary widget */ 225 m_pSummaryText->viewport()->setAutoFillBackground (false); 226 /* Make the summary field read-only */ 227 m_pSummaryText->setReadOnly (true); 228 229 /* Translate */ 230 retranslateUi(); 231 } 232 233 void UIFirstRunWzdPage3::init() 234 { 235 /* Current machine */ 236 CMachine machine = field("machine").value<CMachine>(); 237 AssertMsg(!machine.isNull(), ("Field 'machine' must be set!\n")); 238 239 /* Hide unnecessary text labels */ 240 CMediumAttachment hda = machine.GetMediumAttachment(VBoxVMSettingsHD::tr("IDE Controller"), 0, 0); 241 m_pPage3Text1Var1->setHidden(hda.isNull()); 242 m_pPage3Text1Var2->setHidden(!hda.isNull()); 243 m_pPage3Text2Var1->setHidden(hda.isNull()); 244 m_pPage3Text2Var2->setHidden(!hda.isNull()); 245 } 246 247 void UIFirstRunWzdPage3::retranslateUi() 248 { 249 /* Translate uic generated strings */ 250 Ui::UIFirstRunWzdPage3::retranslateUi(this); 251 252 /* Wizard page 3 title */ 253 setTitle(tr("Summary")); 254 255 /* Compose common summary */ 256 QString summary; 257 258 QString description = field("description").toString(); 259 QString source = field("source").toString(); 260 261 summary += QString 262 ( 263 "<tr><td><nobr>%1: </nobr></td><td><nobr>%2</nobr></td></tr>" 264 "<tr><td><nobr>%3: </nobr></td><td><nobr>%4</nobr></td></tr>" 265 ) 266 .arg (tr("Type", "summary"), description) 267 .arg (tr("Source", "summary"), source) 268 ; 269 /* Feat summary to 3 lines */ 270 setSummaryFieldLinesNumber(m_pSummaryText, 2); 271 272 m_pSummaryText->setText("<table cellspacing=0 cellpadding=0>" + summary + "</table>"); 273 } 274 275 void UIFirstRunWzdPage3::initializePage() 276 { 277 /* Translate */ 278 retranslateUi(); 279 280 /* Summary should initially have focus */ 281 m_pSummaryText->setFocus(); 282 } 283 284 void UIFirstRunWzdPage3::cleanupPage() 285 { 286 /* Do not call superclass method! */ 287 } 288 289 bool UIFirstRunWzdPage3::validatePage() 290 { 291 return insertDevice(); 292 } 293 294 bool UIFirstRunWzdPage3::insertDevice() 99 295 { 100 296 /* Composing default controller name */ 101 KStorageBus ctrBus (mRbCdType->isChecked() ? KStorageBus_IDE : KStorageBus_Floppy); 102 LONG ctrPort = mRbCdType->isChecked() ? 1 : 0; 103 LONG ctrDevice = 0; 104 QString ctrName; 297 KStorageBus bus = field("bus").value<KStorageBus>(); 298 QString mediumId = field("id").toString(); 299 LONG port = bus == KStorageBus_IDE ? 1 : 0; 300 LONG device = 0; 301 QString name; 105 302 /* Search for the first controller of the given type */ 106 QVector<CStorageController> c trs = mMachine.GetStorageControllers();107 foreach (CStorageController c tr, ctrs)108 { 109 if (c tr.GetBus() == ctrBus)303 QVector<CStorageController> controllers = m_Machine.GetStorageControllers(); 304 foreach (CStorageController controller, controllers) 305 { 306 if (controller.GetBus() == bus) 110 307 { 111 ctrName = ctr.GetName();308 name = controller.GetName(); 112 309 break; 113 310 } 114 311 } 115 Assert (!ctrName.isEmpty()); 312 Assert (!name.isEmpty()); 313 116 314 /* Mount medium to the predefined port/device */ 117 m Machine.MountMedium (ctrName, ctrPort, ctrDevice, mCbMedia->id(), false /* force */);118 if (m Machine.isOk())119 QIAbstractWizard::accept();315 m_Machine.MountMedium(name, port, device, mediumId, false /* force */); 316 if (m_Machine.isOk()) 317 return true; 120 318 else 121 vboxProblem().cannotRemountMedium (this, mMachine, vboxGlobal().findMedium (mCbMedia->id()), true /* mount? */, false /* retry? */); 122 } 123 124 void VBoxVMFirstRunWzd::revalidate (QIWidgetValidator *aValidator) 125 { 126 /* Do individual validations for pages */ 127 QWidget *pg = aValidator->widget(); 128 bool valid = aValidator->isOtherValid(); 129 130 /* Allow to go to Summary only if non-null medium selected */ 131 if (pg == mPageMedia) 132 valid = !vboxGlobal().findMedium (mCbMedia->id()).isNull(); 133 134 aValidator->setOtherValid (valid); 135 } 136 137 void VBoxVMFirstRunWzd::mediaTypeChanged() 138 { 139 /* CD/DVD media type selected */ 140 if (sender() == mRbCdType) 141 { 142 /* Switch media combo-box type to CD/DVD */ 143 mCbMedia->setType (VBoxDefs::MediumType_DVD); 144 } 145 /* Floppy media type selected */ 146 else if (sender() == mRbFdType) 147 { 148 /* Switch media combo-box type to Floppy */ 149 mCbMedia->setType (VBoxDefs::MediumType_Floppy); 150 } 151 152 /* Update the media combo-box */ 153 mCbMedia->repopulate(); 154 155 /* Revalidate updated page */ 156 mValidator->revalidate(); 157 } 158 159 void VBoxVMFirstRunWzd::openMediaManager() 160 { 161 /* Create & open VMM */ 162 VBoxMediaManagerDlg dlg (this); 163 dlg.setup (mCbMedia->type(), true /* aDoSelect */); 164 if (dlg.exec() == QDialog::Accepted) 165 mCbMedia->setCurrentItem (dlg.selectedId()); 166 167 /* Revalidate updated page */ 168 mValidator->revalidate(); 169 } 170 171 void VBoxVMFirstRunWzd::enableNext (const QIWidgetValidator *aValidator) 172 { 173 nextButton (aValidator->widget())->setEnabled (aValidator->isValid()); 174 } 175 176 void VBoxVMFirstRunWzd::onPageShow() 177 { 178 /* Make sure all is properly translated & composed */ 179 retranslateUi(); 180 181 QWidget *page = mPageStack->currentWidget(); 182 183 if (page == mPageWelcome) 184 nextButton (page)->setFocus(); 185 else if (page == mPageMedia) 186 mRbCdType->isChecked() ? mRbCdType->setFocus() : 187 mRbFdType->setFocus(); 188 else if (page == mPageSummary) 189 mTeSummary->setFocus(); 190 191 if (page == mPageSummary) 192 finishButton()->setDefault (true); 193 else 194 nextButton (page)->setDefault (true); 195 } 196 319 { 320 vboxProblem().cannotRemountMedium(this, m_Machine, vboxGlobal().findMedium(mediumId), 321 true /* mount? */, false /* retry? */); 322 return false; 323 } 324 } -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/firstrun/UIFirstRunWzd.h
r25432 r26079 2 2 * 3 3 * VBox frontends: Qt4 GUI ("VirtualBox"): 4 * VBoxVMFirstRunWzd class declaration4 * UIFirstRunWzd class declaration 5 5 */ 6 6 7 7 /* 8 * Copyright (C) 2008-20 09Sun Microsystems, Inc.8 * Copyright (C) 2008-2010 Sun Microsystems, Inc. 9 9 * 10 10 * This file is part of VirtualBox Open Source Edition (OSE), as … … 21 21 */ 22 22 23 #ifndef __ VBoxVMFirstRunWzd_h__24 #define __ VBoxVMFirstRunWzd_h__23 #ifndef __UIFirstRunWzd_h__ 24 #define __UIFirstRunWzd_h__ 25 25 26 26 /* Local includes */ 27 #include "QIAbstractWizard.h" 28 #include "VBoxVMFirstRunWzd.gen.h" 27 #include "QIWizard.h" 29 28 #include "COMDefs.h" 30 #include "QIWithRetranslateUI.h"31 29 32 /* Local forwardes */ 33 class QIWidgetValidator; 30 /* Generated includes */ 31 #include "UIFirstRunWzdPage1.gen.h" 32 #include "UIFirstRunWzdPage2.gen.h" 33 #include "UIFirstRunWzdPage3.gen.h" 34 34 35 class VBoxVMFirstRunWzd : public QIWithRetranslateUI <QIAbstractWizard>, 36 public Ui::VBoxVMFirstRunWzd 35 class UIFirstRunWzd : public QIWizard 37 36 { 38 37 Q_OBJECT; … … 40 39 public: 41 40 42 VBoxVMFirstRunWzd (const CMachine &aMachine, QWidget *aParent = 0); 41 UIFirstRunWzd(QWidget *pParent, const CMachine &machine); 42 43 protected: 44 45 void retranslateUi(); 46 }; 47 48 class UIFirstRunWzdPage1 : public QIWizardPage, public Ui::UIFirstRunWzdPage1 49 { 50 Q_OBJECT; 51 52 public: 53 54 UIFirstRunWzdPage1(); 55 56 void init(); 57 58 protected: 59 60 void retranslateUi(); 61 }; 62 63 class UIFirstRunWzdPage2 : public QIWizardPage, public Ui::UIFirstRunWzdPage2 64 { 65 Q_OBJECT; 66 Q_PROPERTY(KStorageBus bus READ bus WRITE setBus); 67 Q_PROPERTY(QString description READ description WRITE setDescription); 68 Q_PROPERTY(QString source READ source WRITE setSource); 69 Q_PROPERTY(QString id READ id WRITE setId); 70 71 public: 72 73 UIFirstRunWzdPage2(); 74 75 void init(); 43 76 44 77 protected: … … 46 79 void retranslateUi(); 47 80 81 void initializePage(); 82 83 bool isComplete() const; 84 48 85 private slots: 49 86 50 void accept(); 51 void revalidate (QIWidgetValidator *aValidator); 52 void mediaTypeChanged(); 53 void openMediaManager(); 54 void enableNext (const QIWidgetValidator *aValidator); 55 void onPageShow(); 87 void sltMediumChanged(); 88 void sltOpenVirtualMediaManager(); 56 89 57 90 private: 58 91 59 QIWidgetValidator *mValidator; 60 CMachine mMachine; 92 KStorageBus bus() const { return m_Bus; } 93 void setBus(KStorageBus bus) { m_Bus = bus; } 94 KStorageBus m_Bus; 95 96 QString description() const { return m_strDescription; } 97 void setDescription(const QString &strDescription) { m_strDescription = strDescription; } 98 QString m_strDescription; 99 100 QString source() const { return m_strSource; } 101 void setSource(const QString &strSource) { m_strSource = strSource; } 102 QString m_strSource; 103 104 QString id() const { return m_strId; } 105 void setId(const QString &strId) { m_strId = strId; } 106 QString m_strId; 61 107 }; 62 108 63 #endif // __VBoxVMFirstRunWzd_h__ 109 class UIFirstRunWzdPage3 : public QIWizardPage, public Ui::UIFirstRunWzdPage3 110 { 111 Q_OBJECT; 112 Q_PROPERTY(CMachine machine READ machine WRITE setMachine); 64 113 114 public: 115 116 UIFirstRunWzdPage3(); 117 118 void init(); 119 120 protected: 121 122 void retranslateUi(); 123 124 void initializePage(); 125 void cleanupPage(); 126 127 bool validatePage(); 128 129 private: 130 131 bool insertDevice(); 132 133 CMachine machine() const { return m_Machine; } 134 void setMachine(CMachine &machine) { m_Machine = machine; } 135 CMachine m_Machine; 136 }; 137 138 Q_DECLARE_METATYPE(CMachine); 139 140 #endif // __UIFirstRunWzd_h__ -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/firstrun/UIFirstRunWzdPage1.ui
r25432 r26079 1 <ui version="4.0" > 1 <?xml version="1.0" encoding="UTF-8"?> 2 <ui version="4.0"> 2 3 <comment> 3 4 VBox frontends: Qt4 GUI ("VirtualBox"): 4 5 5 Copyright (C) 200 8-2009Sun Microsystems, Inc.6 Copyright (C) 2009-2010 Sun Microsystems, Inc. 6 7 7 8 This file is part of VirtualBox Open Source Edition (OSE), as … … 17 18 additional information or have any questions. 18 19 </comment> 19 <class> VBoxVMFirstRunWzd</class>20 <widget class="Q Dialog" name="VBoxVMFirstRunWzd">21 <property name="geometry" 20 <class>UIFirstRunWzdPage1</class> 21 <widget class="QWidget" name="UIFirstRunWzdPage1"> 22 <property name="geometry"> 22 23 <rect> 23 24 <x>0</x> 24 25 <y>0</y> 25 <width> 782</width>26 <height> 561</height>26 <width>600</width> 27 <height>400</height> 27 28 </rect> 28 29 </property> 29 <property name="windowTitle" > 30 <string>First Run Wizard</string> 30 <property name="sizePolicy"> 31 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 32 <horstretch>0</horstretch> 33 <verstretch>0</verstretch> 34 </sizepolicy> 31 35 </property> 32 <layout class="QVBoxLayout" > 33 <property name="leftMargin" > 34 <number>0</number> 35 </property> 36 <property name="topMargin" > 37 <number>0</number> 38 </property> 39 <property name="rightMargin" > 40 <number>0</number> 41 </property> 36 <layout class="QVBoxLayout" name="m_pLayout1"> 42 37 <property name="bottomMargin" > 43 38 <number>0</number> 44 39 </property> 45 40 <item> 46 <widget class="Q StackedWidget" name="mPageStack">47 <property name=" currentIndex">48 < number>0</number>41 <widget class="QILabel" name="m_pPage1Text1Var1"> 42 <property name="text"> 43 <string><p>You have started a newly created virtual machine for the first time. This wizard will help you to perform the steps necessary for installing an operating system of your choice onto this virtual machine.</p><p>Use the <b>Next</b> button to go to the next page of the wizard and the <b>Back</b> button to return to the previous page. You can also press <b>Cancel</b> if you want to cancel the execution of this wizard.</p></string> 49 44 </property> 50 <widget class="QWidget" name="mPageWelcome" > 51 <layout class="QVBoxLayout" > 52 <item> 53 <widget class="QLabel" name="mPageWelcomeHdr" > 54 <property name="font" > 55 <font> 56 <family>Arial</family> 57 <pointsize>12</pointsize> 58 <weight>75</weight> 59 <bold>true</bold> 60 </font> 61 </property> 62 <property name="text" > 63 <string>Welcome to the First Run Wizard!</string> 64 </property> 65 </widget> 66 </item> 67 <item> 68 <widget class="Line" name="line11" > 69 <property name="orientation" > 70 <enum>Qt::Horizontal</enum> 71 </property> 72 </widget> 73 </item> 74 <item> 75 <layout class="QHBoxLayout" > 76 <property name="spacing" > 77 <number>10</number> 78 </property> 79 <item> 80 <widget class="QLabel" name="mLogoWelcome" > 81 <property name="sizePolicy" > 82 <sizepolicy vsizetype="Minimum" hsizetype="Maximum" > 83 <horstretch>0</horstretch> 84 <verstretch>0</verstretch> 85 </sizepolicy> 86 </property> 87 <property name="autoFillBackground" > 88 <bool>true</bool> 89 </property> 90 <property name="text" > 91 <string/> 92 </property> 93 <property name="pixmap" > 94 <pixmap resource="../VirtualBox1.qrc" >:/vmw_new_harddisk.png</pixmap> 95 </property> 96 <property name="alignment" > 97 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 98 </property> 99 </widget> 100 </item> 101 <item> 102 <layout class="QVBoxLayout" > 103 <property name="spacing" > 104 <number>10</number> 105 </property> 106 <item> 107 <widget class="QILabel" name="mTextWelcome1" > 108 <property name="sizePolicy" > 109 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 110 <horstretch>0</horstretch> 111 <verstretch>0</verstretch> 112 </sizepolicy> 113 </property> 114 <property name="minimumSize" > 115 <size> 116 <width>300</width> 117 <height>0</height> 118 </size> 119 </property> 120 <property name="text" > 121 <string><p>You have started a newly created virtual machine for the first time. This wizard will help you to perform the steps necessary for installing an operating system of your choice onto this virtual machine.</p><p>Use the <b>Next</b> button to go to the next page of the wizard and the <b>Back</b> button to return to the previous page. You can also press <b>Cancel</b> if you want to cancel the execution of this wizard.</p></string> 122 </property> 123 <property name="alignment" > 124 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 125 </property> 126 <property name="wordWrap" > 127 <bool>true</bool> 128 </property> 129 </widget> 130 </item> 131 <item> 132 <widget class="QILabel" name="mTextWelcome2" > 133 <property name="sizePolicy" > 134 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 135 <horstretch>0</horstretch> 136 <verstretch>0</verstretch> 137 </sizepolicy> 138 </property> 139 <property name="minimumSize" > 140 <size> 141 <width>300</width> 142 <height>0</height> 143 </size> 144 </property> 145 <property name="text" > 146 <string><p>You have started a newly created virtual machine for the first time. This wizard will help you to perform the steps necessary for booting an operating system of your choice on the virtual machine.</p><p>Note that you will not be able to install an operating system into this virtual machine right now because you did not attach any hard disk to it. If this is not what you want, you can cancel the execution of this wizard, select <b>Settings</b> from the <b>Machine</b> menu of the main VirtualBox window to access the settings dialog of this machine and change the hard disk configuration.</p><p>Use the <b>Next</b> button to go to the next page of the wizard and the <b>Back</b> button to return to the previous page. You can also press <b>Cancel</b> if you want to cancel the execution of this wizard.</p></string> 147 </property> 148 <property name="wordWrap" > 149 <bool>true</bool> 150 </property> 151 </widget> 152 </item> 153 <item> 154 <spacer> 155 <property name="orientation" > 156 <enum>Qt::Vertical</enum> 157 </property> 158 <property name="sizeHint" > 159 <size> 160 <width>0</width> 161 <height>0</height> 162 </size> 163 </property> 164 </spacer> 165 </item> 166 </layout> 167 </item> 168 </layout> 169 </item> 170 <item> 171 <widget class="Line" name="line12" > 172 <property name="orientation" > 173 <enum>Qt::Horizontal</enum> 174 </property> 175 </widget> 176 </item> 177 <item> 178 <layout class="QHBoxLayout" > 179 <item> 180 <spacer> 181 <property name="orientation" > 182 <enum>Qt::Horizontal</enum> 183 </property> 184 <property name="sizeHint" > 185 <size> 186 <width>0</width> 187 <height>0</height> 188 </size> 189 </property> 190 </spacer> 191 </item> 192 <item> 193 <widget class="QPushButton" name="mBtnBack1" > 194 <property name="enabled" > 195 <bool>false</bool> 196 </property> 197 <property name="text" > 198 <string>< &Back</string> 199 </property> 200 </widget> 201 </item> 202 <item> 203 <widget class="QPushButton" name="mBtnNext1" > 204 <property name="text" > 205 <string>&Next ></string> 206 </property> 207 </widget> 208 </item> 209 <item> 210 <spacer> 211 <property name="orientation" > 212 <enum>Qt::Horizontal</enum> 213 </property> 214 <property name="sizeType" > 215 <enum>QSizePolicy::Fixed</enum> 216 </property> 217 <property name="sizeHint" > 218 <size> 219 <width>5</width> 220 <height>0</height> 221 </size> 222 </property> 223 </spacer> 224 </item> 225 <item> 226 <widget class="QPushButton" name="mBtnCancel1" > 227 <property name="text" > 228 <string>Cancel</string> 229 </property> 230 </widget> 231 </item> 232 </layout> 233 </item> 234 </layout> 235 </widget> 236 <widget class="QWidget" name="mPageMedia" > 237 <layout class="QVBoxLayout" > 238 <item> 239 <widget class="QLabel" name="mPageMediaHdr" > 240 <property name="font" > 241 <font> 242 <family>Arial</family> 243 <pointsize>12</pointsize> 244 <weight>75</weight> 245 <bold>true</bold> 246 </font> 247 </property> 248 <property name="text" > 249 <string>Select Installation Media</string> 250 </property> 251 </widget> 252 </item> 253 <item> 254 <widget class="Line" name="line21" > 255 <property name="orientation" > 256 <enum>Qt::Horizontal</enum> 257 </property> 258 </widget> 259 </item> 260 <item> 261 <layout class="QHBoxLayout" > 262 <property name="spacing" > 263 <number>10</number> 264 </property> 265 <item> 266 <widget class="QLabel" name="mLogoType" > 267 <property name="sizePolicy" > 268 <sizepolicy vsizetype="Minimum" hsizetype="Maximum" > 269 <horstretch>0</horstretch> 270 <verstretch>0</verstretch> 271 </sizepolicy> 272 </property> 273 <property name="autoFillBackground" > 274 <bool>true</bool> 275 </property> 276 <property name="text" > 277 <string/> 278 </property> 279 <property name="pixmap" > 280 <pixmap resource="../VirtualBox1.qrc" >:/vmw_new_harddisk.png</pixmap> 281 </property> 282 <property name="alignment" > 283 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 284 </property> 285 </widget> 286 </item> 287 <item> 288 <layout class="QVBoxLayout" > 289 <property name="spacing" > 290 <number>10</number> 291 </property> 292 <item> 293 <widget class="QILabel" name="mTextType1" > 294 <property name="sizePolicy" > 295 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 296 <horstretch>0</horstretch> 297 <verstretch>0</verstretch> 298 </sizepolicy> 299 </property> 300 <property name="minimumSize" > 301 <size> 302 <width>300</width> 303 <height>0</height> 304 </size> 305 </property> 306 <property name="text" > 307 <string><p>Select the type of media you would like to use for installation.</p></string> 308 </property> 309 <property name="alignment" > 310 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 311 </property> 312 <property name="wordWrap" > 313 <bool>true</bool> 314 </property> 315 </widget> 316 </item> 317 <item> 318 <widget class="QILabel" name="mTextType2" > 319 <property name="sizePolicy" > 320 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 321 <horstretch>0</horstretch> 322 <verstretch>0</verstretch> 323 </sizepolicy> 324 </property> 325 <property name="minimumSize" > 326 <size> 327 <width>300</width> 328 <height>0</height> 329 </size> 330 </property> 331 <property name="text" > 332 <string><p>Select the type of media you would like to use for booting an operating system.</p></string> 333 </property> 334 <property name="wordWrap" > 335 <bool>true</bool> 336 </property> 337 </widget> 338 </item> 339 <item> 340 <widget class="QGroupBox" name="mGbType" > 341 <property name="sizePolicy" > 342 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 343 <horstretch>0</horstretch> 344 <verstretch>0</verstretch> 345 </sizepolicy> 346 </property> 347 <property name="title" > 348 <string>Media Type</string> 349 </property> 350 <layout class="QVBoxLayout" > 351 <property name="topMargin" > 352 <number>4</number> 353 </property> 354 <item> 355 <widget class="QRadioButton" name="mRbCdType" > 356 <property name="sizePolicy" > 357 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 358 <horstretch>0</horstretch> 359 <verstretch>0</verstretch> 360 </sizepolicy> 361 </property> 362 <property name="text" > 363 <string>&CD/DVD-ROM Device</string> 364 </property> 365 <property name="checked" > 366 <bool>true</bool> 367 </property> 368 </widget> 369 </item> 370 <item> 371 <widget class="QRadioButton" name="mRbFdType" > 372 <property name="sizePolicy" > 373 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 374 <horstretch>0</horstretch> 375 <verstretch>0</verstretch> 376 </sizepolicy> 377 </property> 378 <property name="text" > 379 <string>&Floppy Device</string> 380 </property> 381 </widget> 382 </item> 383 </layout> 384 </widget> 385 </item> 386 <item> 387 <widget class="QILabel" name="mTextSource1" > 388 <property name="sizePolicy" > 389 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 390 <horstretch>0</horstretch> 391 <verstretch>0</verstretch> 392 </sizepolicy> 393 </property> 394 <property name="minimumSize" > 395 <size> 396 <width>300</width> 397 <height>0</height> 398 </size> 399 </property> 400 <property name="text" > 401 <string><p>Select the media which contains the setup program of the operating system you want to install. This media must be bootable, otherwise the setup program will not be able to start.</p></string> 402 </property> 403 <property name="wordWrap" > 404 <bool>true</bool> 405 </property> 406 </widget> 407 </item> 408 <item> 409 <widget class="QILabel" name="mTextSource2" > 410 <property name="sizePolicy" > 411 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 412 <horstretch>0</horstretch> 413 <verstretch>0</verstretch> 414 </sizepolicy> 415 </property> 416 <property name="minimumSize" > 417 <size> 418 <width>300</width> 419 <height>0</height> 420 </size> 421 </property> 422 <property name="text" > 423 <string><p>Select the media that contains the operating system you want to work with. This media must be bootable, otherwise the operating system will not be able to start.</p></string> 424 </property> 425 <property name="wordWrap" > 426 <bool>true</bool> 427 </property> 428 </widget> 429 </item> 430 <item> 431 <widget class="QGroupBox" name="mGbSource" > 432 <property name="sizePolicy" > 433 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 434 <horstretch>0</horstretch> 435 <verstretch>0</verstretch> 436 </sizepolicy> 437 </property> 438 <property name="title" > 439 <string>Media Source</string> 440 </property> 441 <layout class="QHBoxLayout" > 442 <property name="topMargin" > 443 <number>4</number> 444 </property> 445 <item> 446 <widget class="VBoxMediaComboBox" name="mCbMedia" /> 447 </item> 448 <item> 449 <widget class="QToolButton" name="mTbVmm" > 450 <property name="icon" > 451 <iconset resource="../VirtualBox1.qrc" >:/select_file_16px.png</iconset> 452 </property> 453 </widget> 454 </item> 455 </layout> 456 </widget> 457 </item> 458 <item> 459 <spacer> 460 <property name="orientation" > 461 <enum>Qt::Vertical</enum> 462 </property> 463 <property name="sizeHint" > 464 <size> 465 <width>0</width> 466 <height>0</height> 467 </size> 468 </property> 469 </spacer> 470 </item> 471 </layout> 472 </item> 473 </layout> 474 </item> 475 <item> 476 <widget class="Line" name="line22" > 477 <property name="orientation" > 478 <enum>Qt::Horizontal</enum> 479 </property> 480 </widget> 481 </item> 482 <item> 483 <layout class="QHBoxLayout" > 484 <item> 485 <spacer> 486 <property name="orientation" > 487 <enum>Qt::Horizontal</enum> 488 </property> 489 <property name="sizeHint" > 490 <size> 491 <width>0</width> 492 <height>0</height> 493 </size> 494 </property> 495 </spacer> 496 </item> 497 <item> 498 <widget class="QPushButton" name="mBtnBack2" > 499 <property name="text" > 500 <string>< &Back</string> 501 </property> 502 </widget> 503 </item> 504 <item> 505 <widget class="QPushButton" name="mBtnNext2" > 506 <property name="text" > 507 <string>&Next ></string> 508 </property> 509 </widget> 510 </item> 511 <item> 512 <spacer> 513 <property name="orientation" > 514 <enum>Qt::Horizontal</enum> 515 </property> 516 <property name="sizeType" > 517 <enum>QSizePolicy::Fixed</enum> 518 </property> 519 <property name="sizeHint" > 520 <size> 521 <width>5</width> 522 <height>0</height> 523 </size> 524 </property> 525 </spacer> 526 </item> 527 <item> 528 <widget class="QPushButton" name="mBtnCancel2" > 529 <property name="text" > 530 <string>Cancel</string> 531 </property> 532 </widget> 533 </item> 534 </layout> 535 </item> 536 </layout> 537 </widget> 538 <widget class="QWidget" name="mPageSummary" > 539 <layout class="QVBoxLayout" > 540 <item> 541 <widget class="QLabel" name="mPageSummaryHdr" > 542 <property name="font" > 543 <font> 544 <family>Arial</family> 545 <pointsize>12</pointsize> 546 <weight>75</weight> 547 <bold>true</bold> 548 </font> 549 </property> 550 <property name="text" > 551 <string>Summary</string> 552 </property> 553 </widget> 554 </item> 555 <item> 556 <widget class="Line" name="line31" > 557 <property name="orientation" > 558 <enum>Qt::Horizontal</enum> 559 </property> 560 </widget> 561 </item> 562 <item> 563 <layout class="QHBoxLayout" > 564 <property name="spacing" > 565 <number>10</number> 566 </property> 567 <item> 568 <widget class="QLabel" name="mLogoSummary" > 569 <property name="sizePolicy" > 570 <sizepolicy vsizetype="Minimum" hsizetype="Maximum" > 571 <horstretch>0</horstretch> 572 <verstretch>0</verstretch> 573 </sizepolicy> 574 </property> 575 <property name="autoFillBackground" > 576 <bool>true</bool> 577 </property> 578 <property name="text" > 579 <string/> 580 </property> 581 <property name="pixmap" > 582 <pixmap resource="../VirtualBox1.qrc" >:/vmw_new_harddisk.png</pixmap> 583 </property> 584 <property name="alignment" > 585 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 586 </property> 587 </widget> 588 </item> 589 <item> 590 <layout class="QVBoxLayout" > 591 <property name="spacing" > 592 <number>10</number> 593 </property> 594 <item> 595 <widget class="QILabel" name="mTextSummaryHdr1" > 596 <property name="sizePolicy" > 597 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 598 <horstretch>0</horstretch> 599 <verstretch>0</verstretch> 600 </sizepolicy> 601 </property> 602 <property name="minimumSize" > 603 <size> 604 <width>300</width> 605 <height>0</height> 606 </size> 607 </property> 608 <property name="text" > 609 <string><p>You have selected the following media to boot from:</p></string> 610 </property> 611 <property name="alignment" > 612 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 613 </property> 614 <property name="wordWrap" > 615 <bool>true</bool> 616 </property> 617 </widget> 618 </item> 619 <item> 620 <widget class="QILabel" name="mTextSummaryHdr2" > 621 <property name="sizePolicy" > 622 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 623 <horstretch>0</horstretch> 624 <verstretch>0</verstretch> 625 </sizepolicy> 626 </property> 627 <property name="minimumSize" > 628 <size> 629 <width>300</width> 630 <height>0</height> 631 </size> 632 </property> 633 <property name="text" > 634 <string><p>You have selected the following media to boot an operating system from:</p></string> 635 </property> 636 <property name="wordWrap" > 637 <bool>true</bool> 638 </property> 639 </widget> 640 </item> 641 <item> 642 <widget class="QITextEdit" name="mTeSummary" > 643 <property name="sizePolicy" > 644 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 645 <horstretch>0</horstretch> 646 <verstretch>0</verstretch> 647 </sizepolicy> 648 </property> 649 <property name="minimumSize" > 650 <size> 651 <width>300</width> 652 <height>0</height> 653 </size> 654 </property> 655 <property name="frameShape" > 656 <enum>QFrame::NoFrame</enum> 657 </property> 658 <property name="autoFormatting" > 659 <set>QTextEdit::AutoAll</set> 660 </property> 661 <property name="readOnly" > 662 <bool>true</bool> 663 </property> 664 </widget> 665 </item> 666 <item> 667 <widget class="QILabel" name="mTextSummaryFtr1" > 668 <property name="sizePolicy" > 669 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 670 <horstretch>0</horstretch> 671 <verstretch>0</verstretch> 672 </sizepolicy> 673 </property> 674 <property name="minimumSize" > 675 <size> 676 <width>300</width> 677 <height>0</height> 678 </size> 679 </property> 680 <property name="text" > 681 <string><p>If the above is correct, press the <b>Finish</b> button. Once you press it, the selected media will be temporarily mounted on the virtual machine and the machine will start execution.</p><p>Please note that when you close the virtual machine, the specified media will be automatically unmounted and the boot device will be set back to the first hard disk.</p><p>Depending on the type of the setup program, you may need to manually unmount (eject) the media after the setup program reboots the virtual machine, to prevent the installation process from starting again. You can do this by selecting the corresponding <b>Unmount...</b> action in the <b>Devices</b> menu.</p></string> 682 </property> 683 <property name="alignment" > 684 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 685 </property> 686 <property name="wordWrap" > 687 <bool>true</bool> 688 </property> 689 </widget> 690 </item> 691 <item> 692 <widget class="QILabel" name="mTextSummaryFtr2" > 693 <property name="sizePolicy" > 694 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 695 <horstretch>0</horstretch> 696 <verstretch>0</verstretch> 697 </sizepolicy> 698 </property> 699 <property name="minimumSize" > 700 <size> 701 <width>300</width> 702 <height>0</height> 703 </size> 704 </property> 705 <property name="text" > 706 <string><p>If the above is correct, press the <b>Finish</b> button. Once you press it, the selected media will be mounted on the virtual machine and the machine will start execution.</p></string> 707 </property> 708 <property name="wordWrap" > 709 <bool>true</bool> 710 </property> 711 </widget> 712 </item> 713 <item> 714 <spacer> 715 <property name="orientation" > 716 <enum>Qt::Vertical</enum> 717 </property> 718 <property name="sizeType" > 719 <enum>QSizePolicy::Expanding</enum> 720 </property> 721 <property name="sizeHint" > 722 <size> 723 <width>0</width> 724 <height>0</height> 725 </size> 726 </property> 727 </spacer> 728 </item> 729 </layout> 730 </item> 731 </layout> 732 </item> 733 <item> 734 <widget class="Line" name="line32" > 735 <property name="orientation" > 736 <enum>Qt::Horizontal</enum> 737 </property> 738 </widget> 739 </item> 740 <item> 741 <layout class="QHBoxLayout" > 742 <item> 743 <spacer> 744 <property name="orientation" > 745 <enum>Qt::Horizontal</enum> 746 </property> 747 <property name="sizeHint" > 748 <size> 749 <width>0</width> 750 <height>0</height> 751 </size> 752 </property> 753 </spacer> 754 </item> 755 <item> 756 <widget class="QPushButton" name="mBtnBack4" > 757 <property name="text" > 758 <string>< &Back</string> 759 </property> 760 </widget> 761 </item> 762 <item> 763 <widget class="QPushButton" name="mBtnFinish" > 764 <property name="text" > 765 <string>&Finish</string> 766 </property> 767 </widget> 768 </item> 769 <item> 770 <spacer> 771 <property name="orientation" > 772 <enum>Qt::Horizontal</enum> 773 </property> 774 <property name="sizeType" > 775 <enum>QSizePolicy::Fixed</enum> 776 </property> 777 <property name="sizeHint" > 778 <size> 779 <width>5</width> 780 <height>0</height> 781 </size> 782 </property> 783 </spacer> 784 </item> 785 <item> 786 <widget class="QPushButton" name="mBtnCancel4" > 787 <property name="text" > 788 <string>Cancel</string> 789 </property> 790 </widget> 791 </item> 792 </layout> 793 </item> 794 </layout> 795 </widget> 45 <property name="wordWrap"> 46 <bool>true</bool> 47 </property> 796 48 </widget> 49 </item> 50 <item> 51 <widget class="QILabel" name="m_pPage1Text1Var2"> 52 <property name="text"> 53 <string><p>You have started a newly created virtual machine for the first time. This wizard will help you to perform the steps necessary for booting an operating system of your choice on the virtual machine.</p><p>Note that you will not be able to install an operating system into this virtual machine right now because you did not attach any hard disk to it. If this is not what you want, you can cancel the execution of this wizard, select <b>Settings</b> from the <b>Machine</b> menu of the main VirtualBox window to access the settings dialog of this machine and change the hard disk configuration.</p><p>Use the <b>Next</b> button to go to the next page of the wizard and the <b>Back</b> button to return to the previous page. You can also press <b>Cancel</b> if you want to cancel the execution of this wizard.</p></string> 54 </property> 55 <property name="wordWrap"> 56 <bool>true</bool> 57 </property> 58 </widget> 59 </item> 60 <item> 61 <spacer name="m_pSpacer1"> 62 <property name="sizeHint" stdset="0"> 63 <size> 64 <width>0</width> 65 <height>0</height> 66 </size> 67 </property> 68 </spacer> 797 69 </item> 798 70 </layout> … … 804 76 <header>QILabel.h</header> 805 77 </customwidget> 806 <customwidget>807 <class>VBoxMediaComboBox</class>808 <extends>QComboBox</extends>809 <header>VBoxMediaComboBox.h</header>810 </customwidget>811 <customwidget>812 <class>QITextEdit</class>813 <extends>QTextEdit</extends>814 <header>QIAbstractWizard.h</header>815 </customwidget>816 78 </customwidgets> 817 <tabstops> 818 <tabstop>mBtnNext1</tabstop> 819 <tabstop>mBtnCancel1</tabstop> 820 <tabstop>mBtnBack2</tabstop> 821 <tabstop>mBtnNext2</tabstop> 822 <tabstop>mBtnCancel2</tabstop> 823 <tabstop>mBtnBack4</tabstop> 824 <tabstop>mBtnFinish</tabstop> 825 <tabstop>mBtnCancel4</tabstop> 826 </tabstops> 827 <resources> 828 <include location="../VirtualBox1.qrc" /> 829 </resources> 79 <resources/> 830 80 <connections/> 831 81 </ui> -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/firstrun/UIFirstRunWzdPage2.ui
r25432 r26079 1 <ui version="4.0" > 1 <?xml version="1.0" encoding="UTF-8"?> 2 <ui version="4.0"> 2 3 <comment> 3 4 VBox frontends: Qt4 GUI ("VirtualBox"): 4 5 5 Copyright (C) 200 8-2009Sun Microsystems, Inc.6 Copyright (C) 2009-2010 Sun Microsystems, Inc. 6 7 7 8 This file is part of VirtualBox Open Source Edition (OSE), as … … 17 18 additional information or have any questions. 18 19 </comment> 19 <class> VBoxVMFirstRunWzd</class>20 <widget class="Q Dialog" name="VBoxVMFirstRunWzd">21 <property name="geometry" 20 <class>UIFirstRunWzdPage2</class> 21 <widget class="QWidget" name="UIFirstRunWzdPage2"> 22 <property name="geometry"> 22 23 <rect> 23 24 <x>0</x> 24 25 <y>0</y> 25 <width> 782</width>26 <height> 561</height>26 <width>600</width> 27 <height>400</height> 27 28 </rect> 28 29 </property> 29 <property name="windowTitle" > 30 <string>First Run Wizard</string> 30 <property name="sizePolicy"> 31 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 32 <horstretch>0</horstretch> 33 <verstretch>0</verstretch> 34 </sizepolicy> 31 35 </property> 32 <layout class="QVBoxLayout" > 33 <property name="leftMargin" > 34 <number>0</number> 35 </property> 36 <property name="topMargin" > 37 <number>0</number> 38 </property> 39 <property name="rightMargin" > 40 <number>0</number> 41 </property> 36 <layout class="QVBoxLayout" name="m_pLayout1"> 42 37 <property name="bottomMargin" > 43 38 <number>0</number> 44 39 </property> 45 40 <item> 46 <widget class="Q StackedWidget" name="mPageStack">47 <property name=" currentIndex">48 < number>0</number>41 <widget class="QILabel" name="m_pPage2Text1Var1"> 42 <property name="text"> 43 <string><p>Select the type of media you would like to use for installation.</p></string> 49 44 </property> 50 <widget class="QWidget" name="mPageWelcome" > 51 <layout class="QVBoxLayout" > 52 <item> 53 <widget class="QLabel" name="mPageWelcomeHdr" > 54 <property name="font" > 55 <font> 56 <family>Arial</family> 57 <pointsize>12</pointsize> 58 <weight>75</weight> 59 <bold>true</bold> 60 </font> 61 </property> 62 <property name="text" > 63 <string>Welcome to the First Run Wizard!</string> 64 </property> 65 </widget> 66 </item> 67 <item> 68 <widget class="Line" name="line11" > 69 <property name="orientation" > 70 <enum>Qt::Horizontal</enum> 71 </property> 72 </widget> 73 </item> 74 <item> 75 <layout class="QHBoxLayout" > 76 <property name="spacing" > 77 <number>10</number> 78 </property> 79 <item> 80 <widget class="QLabel" name="mLogoWelcome" > 81 <property name="sizePolicy" > 82 <sizepolicy vsizetype="Minimum" hsizetype="Maximum" > 83 <horstretch>0</horstretch> 84 <verstretch>0</verstretch> 85 </sizepolicy> 86 </property> 87 <property name="autoFillBackground" > 88 <bool>true</bool> 89 </property> 90 <property name="text" > 91 <string/> 92 </property> 93 <property name="pixmap" > 94 <pixmap resource="../VirtualBox1.qrc" >:/vmw_new_harddisk.png</pixmap> 95 </property> 96 <property name="alignment" > 97 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 98 </property> 99 </widget> 100 </item> 101 <item> 102 <layout class="QVBoxLayout" > 103 <property name="spacing" > 104 <number>10</number> 105 </property> 106 <item> 107 <widget class="QILabel" name="mTextWelcome1" > 108 <property name="sizePolicy" > 109 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 110 <horstretch>0</horstretch> 111 <verstretch>0</verstretch> 112 </sizepolicy> 113 </property> 114 <property name="minimumSize" > 115 <size> 116 <width>300</width> 117 <height>0</height> 118 </size> 119 </property> 120 <property name="text" > 121 <string><p>You have started a newly created virtual machine for the first time. This wizard will help you to perform the steps necessary for installing an operating system of your choice onto this virtual machine.</p><p>Use the <b>Next</b> button to go to the next page of the wizard and the <b>Back</b> button to return to the previous page. You can also press <b>Cancel</b> if you want to cancel the execution of this wizard.</p></string> 122 </property> 123 <property name="alignment" > 124 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 125 </property> 126 <property name="wordWrap" > 127 <bool>true</bool> 128 </property> 129 </widget> 130 </item> 131 <item> 132 <widget class="QILabel" name="mTextWelcome2" > 133 <property name="sizePolicy" > 134 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 135 <horstretch>0</horstretch> 136 <verstretch>0</verstretch> 137 </sizepolicy> 138 </property> 139 <property name="minimumSize" > 140 <size> 141 <width>300</width> 142 <height>0</height> 143 </size> 144 </property> 145 <property name="text" > 146 <string><p>You have started a newly created virtual machine for the first time. This wizard will help you to perform the steps necessary for booting an operating system of your choice on the virtual machine.</p><p>Note that you will not be able to install an operating system into this virtual machine right now because you did not attach any hard disk to it. If this is not what you want, you can cancel the execution of this wizard, select <b>Settings</b> from the <b>Machine</b> menu of the main VirtualBox window to access the settings dialog of this machine and change the hard disk configuration.</p><p>Use the <b>Next</b> button to go to the next page of the wizard and the <b>Back</b> button to return to the previous page. You can also press <b>Cancel</b> if you want to cancel the execution of this wizard.</p></string> 147 </property> 148 <property name="wordWrap" > 149 <bool>true</bool> 150 </property> 151 </widget> 152 </item> 153 <item> 154 <spacer> 155 <property name="orientation" > 156 <enum>Qt::Vertical</enum> 157 </property> 158 <property name="sizeHint" > 159 <size> 160 <width>0</width> 161 <height>0</height> 162 </size> 163 </property> 164 </spacer> 165 </item> 166 </layout> 167 </item> 168 </layout> 169 </item> 170 <item> 171 <widget class="Line" name="line12" > 172 <property name="orientation" > 173 <enum>Qt::Horizontal</enum> 174 </property> 175 </widget> 176 </item> 177 <item> 178 <layout class="QHBoxLayout" > 179 <item> 180 <spacer> 181 <property name="orientation" > 182 <enum>Qt::Horizontal</enum> 183 </property> 184 <property name="sizeHint" > 185 <size> 186 <width>0</width> 187 <height>0</height> 188 </size> 189 </property> 190 </spacer> 191 </item> 192 <item> 193 <widget class="QPushButton" name="mBtnBack1" > 194 <property name="enabled" > 195 <bool>false</bool> 196 </property> 197 <property name="text" > 198 <string>< &Back</string> 199 </property> 200 </widget> 201 </item> 202 <item> 203 <widget class="QPushButton" name="mBtnNext1" > 204 <property name="text" > 205 <string>&Next ></string> 206 </property> 207 </widget> 208 </item> 209 <item> 210 <spacer> 211 <property name="orientation" > 212 <enum>Qt::Horizontal</enum> 213 </property> 214 <property name="sizeType" > 215 <enum>QSizePolicy::Fixed</enum> 216 </property> 217 <property name="sizeHint" > 218 <size> 219 <width>5</width> 220 <height>0</height> 221 </size> 222 </property> 223 </spacer> 224 </item> 225 <item> 226 <widget class="QPushButton" name="mBtnCancel1" > 227 <property name="text" > 228 <string>Cancel</string> 229 </property> 230 </widget> 231 </item> 232 </layout> 233 </item> 234 </layout> 235 </widget> 236 <widget class="QWidget" name="mPageMedia" > 237 <layout class="QVBoxLayout" > 238 <item> 239 <widget class="QLabel" name="mPageMediaHdr" > 240 <property name="font" > 241 <font> 242 <family>Arial</family> 243 <pointsize>12</pointsize> 244 <weight>75</weight> 245 <bold>true</bold> 246 </font> 247 </property> 248 <property name="text" > 249 <string>Select Installation Media</string> 250 </property> 251 </widget> 252 </item> 253 <item> 254 <widget class="Line" name="line21" > 255 <property name="orientation" > 256 <enum>Qt::Horizontal</enum> 257 </property> 258 </widget> 259 </item> 260 <item> 261 <layout class="QHBoxLayout" > 262 <property name="spacing" > 263 <number>10</number> 264 </property> 265 <item> 266 <widget class="QLabel" name="mLogoType" > 267 <property name="sizePolicy" > 268 <sizepolicy vsizetype="Minimum" hsizetype="Maximum" > 269 <horstretch>0</horstretch> 270 <verstretch>0</verstretch> 271 </sizepolicy> 272 </property> 273 <property name="autoFillBackground" > 274 <bool>true</bool> 275 </property> 276 <property name="text" > 277 <string/> 278 </property> 279 <property name="pixmap" > 280 <pixmap resource="../VirtualBox1.qrc" >:/vmw_new_harddisk.png</pixmap> 281 </property> 282 <property name="alignment" > 283 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 284 </property> 285 </widget> 286 </item> 287 <item> 288 <layout class="QVBoxLayout" > 289 <property name="spacing" > 290 <number>10</number> 291 </property> 292 <item> 293 <widget class="QILabel" name="mTextType1" > 294 <property name="sizePolicy" > 295 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 296 <horstretch>0</horstretch> 297 <verstretch>0</verstretch> 298 </sizepolicy> 299 </property> 300 <property name="minimumSize" > 301 <size> 302 <width>300</width> 303 <height>0</height> 304 </size> 305 </property> 306 <property name="text" > 307 <string><p>Select the type of media you would like to use for installation.</p></string> 308 </property> 309 <property name="alignment" > 310 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 311 </property> 312 <property name="wordWrap" > 313 <bool>true</bool> 314 </property> 315 </widget> 316 </item> 317 <item> 318 <widget class="QILabel" name="mTextType2" > 319 <property name="sizePolicy" > 320 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 321 <horstretch>0</horstretch> 322 <verstretch>0</verstretch> 323 </sizepolicy> 324 </property> 325 <property name="minimumSize" > 326 <size> 327 <width>300</width> 328 <height>0</height> 329 </size> 330 </property> 331 <property name="text" > 332 <string><p>Select the type of media you would like to use for booting an operating system.</p></string> 333 </property> 334 <property name="wordWrap" > 335 <bool>true</bool> 336 </property> 337 </widget> 338 </item> 339 <item> 340 <widget class="QGroupBox" name="mGbType" > 341 <property name="sizePolicy" > 342 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 343 <horstretch>0</horstretch> 344 <verstretch>0</verstretch> 345 </sizepolicy> 346 </property> 347 <property name="title" > 348 <string>Media Type</string> 349 </property> 350 <layout class="QVBoxLayout" > 351 <property name="topMargin" > 352 <number>4</number> 353 </property> 354 <item> 355 <widget class="QRadioButton" name="mRbCdType" > 356 <property name="sizePolicy" > 357 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 358 <horstretch>0</horstretch> 359 <verstretch>0</verstretch> 360 </sizepolicy> 361 </property> 362 <property name="text" > 363 <string>&CD/DVD-ROM Device</string> 364 </property> 365 <property name="checked" > 366 <bool>true</bool> 367 </property> 368 </widget> 369 </item> 370 <item> 371 <widget class="QRadioButton" name="mRbFdType" > 372 <property name="sizePolicy" > 373 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 374 <horstretch>0</horstretch> 375 <verstretch>0</verstretch> 376 </sizepolicy> 377 </property> 378 <property name="text" > 379 <string>&Floppy Device</string> 380 </property> 381 </widget> 382 </item> 383 </layout> 384 </widget> 385 </item> 386 <item> 387 <widget class="QILabel" name="mTextSource1" > 388 <property name="sizePolicy" > 389 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 390 <horstretch>0</horstretch> 391 <verstretch>0</verstretch> 392 </sizepolicy> 393 </property> 394 <property name="minimumSize" > 395 <size> 396 <width>300</width> 397 <height>0</height> 398 </size> 399 </property> 400 <property name="text" > 401 <string><p>Select the media which contains the setup program of the operating system you want to install. This media must be bootable, otherwise the setup program will not be able to start.</p></string> 402 </property> 403 <property name="wordWrap" > 404 <bool>true</bool> 405 </property> 406 </widget> 407 </item> 408 <item> 409 <widget class="QILabel" name="mTextSource2" > 410 <property name="sizePolicy" > 411 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 412 <horstretch>0</horstretch> 413 <verstretch>0</verstretch> 414 </sizepolicy> 415 </property> 416 <property name="minimumSize" > 417 <size> 418 <width>300</width> 419 <height>0</height> 420 </size> 421 </property> 422 <property name="text" > 423 <string><p>Select the media that contains the operating system you want to work with. This media must be bootable, otherwise the operating system will not be able to start.</p></string> 424 </property> 425 <property name="wordWrap" > 426 <bool>true</bool> 427 </property> 428 </widget> 429 </item> 430 <item> 431 <widget class="QGroupBox" name="mGbSource" > 432 <property name="sizePolicy" > 433 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 434 <horstretch>0</horstretch> 435 <verstretch>0</verstretch> 436 </sizepolicy> 437 </property> 438 <property name="title" > 439 <string>Media Source</string> 440 </property> 441 <layout class="QHBoxLayout" > 442 <property name="topMargin" > 443 <number>4</number> 444 </property> 445 <item> 446 <widget class="VBoxMediaComboBox" name="mCbMedia" /> 447 </item> 448 <item> 449 <widget class="QToolButton" name="mTbVmm" > 450 <property name="icon" > 451 <iconset resource="../VirtualBox1.qrc" >:/select_file_16px.png</iconset> 452 </property> 453 </widget> 454 </item> 455 </layout> 456 </widget> 457 </item> 458 <item> 459 <spacer> 460 <property name="orientation" > 461 <enum>Qt::Vertical</enum> 462 </property> 463 <property name="sizeHint" > 464 <size> 465 <width>0</width> 466 <height>0</height> 467 </size> 468 </property> 469 </spacer> 470 </item> 471 </layout> 472 </item> 473 </layout> 474 </item> 475 <item> 476 <widget class="Line" name="line22" > 477 <property name="orientation" > 478 <enum>Qt::Horizontal</enum> 479 </property> 480 </widget> 481 </item> 482 <item> 483 <layout class="QHBoxLayout" > 484 <item> 485 <spacer> 486 <property name="orientation" > 487 <enum>Qt::Horizontal</enum> 488 </property> 489 <property name="sizeHint" > 490 <size> 491 <width>0</width> 492 <height>0</height> 493 </size> 494 </property> 495 </spacer> 496 </item> 497 <item> 498 <widget class="QPushButton" name="mBtnBack2" > 499 <property name="text" > 500 <string>< &Back</string> 501 </property> 502 </widget> 503 </item> 504 <item> 505 <widget class="QPushButton" name="mBtnNext2" > 506 <property name="text" > 507 <string>&Next ></string> 508 </property> 509 </widget> 510 </item> 511 <item> 512 <spacer> 513 <property name="orientation" > 514 <enum>Qt::Horizontal</enum> 515 </property> 516 <property name="sizeType" > 517 <enum>QSizePolicy::Fixed</enum> 518 </property> 519 <property name="sizeHint" > 520 <size> 521 <width>5</width> 522 <height>0</height> 523 </size> 524 </property> 525 </spacer> 526 </item> 527 <item> 528 <widget class="QPushButton" name="mBtnCancel2" > 529 <property name="text" > 530 <string>Cancel</string> 531 </property> 532 </widget> 533 </item> 534 </layout> 535 </item> 536 </layout> 537 </widget> 538 <widget class="QWidget" name="mPageSummary" > 539 <layout class="QVBoxLayout" > 540 <item> 541 <widget class="QLabel" name="mPageSummaryHdr" > 542 <property name="font" > 543 <font> 544 <family>Arial</family> 545 <pointsize>12</pointsize> 546 <weight>75</weight> 547 <bold>true</bold> 548 </font> 549 </property> 550 <property name="text" > 551 <string>Summary</string> 552 </property> 553 </widget> 554 </item> 555 <item> 556 <widget class="Line" name="line31" > 557 <property name="orientation" > 558 <enum>Qt::Horizontal</enum> 559 </property> 560 </widget> 561 </item> 562 <item> 563 <layout class="QHBoxLayout" > 564 <property name="spacing" > 565 <number>10</number> 566 </property> 567 <item> 568 <widget class="QLabel" name="mLogoSummary" > 569 <property name="sizePolicy" > 570 <sizepolicy vsizetype="Minimum" hsizetype="Maximum" > 571 <horstretch>0</horstretch> 572 <verstretch>0</verstretch> 573 </sizepolicy> 574 </property> 575 <property name="autoFillBackground" > 576 <bool>true</bool> 577 </property> 578 <property name="text" > 579 <string/> 580 </property> 581 <property name="pixmap" > 582 <pixmap resource="../VirtualBox1.qrc" >:/vmw_new_harddisk.png</pixmap> 583 </property> 584 <property name="alignment" > 585 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 586 </property> 587 </widget> 588 </item> 589 <item> 590 <layout class="QVBoxLayout" > 591 <property name="spacing" > 592 <number>10</number> 593 </property> 594 <item> 595 <widget class="QILabel" name="mTextSummaryHdr1" > 596 <property name="sizePolicy" > 597 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 598 <horstretch>0</horstretch> 599 <verstretch>0</verstretch> 600 </sizepolicy> 601 </property> 602 <property name="minimumSize" > 603 <size> 604 <width>300</width> 605 <height>0</height> 606 </size> 607 </property> 608 <property name="text" > 609 <string><p>You have selected the following media to boot from:</p></string> 610 </property> 611 <property name="alignment" > 612 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 613 </property> 614 <property name="wordWrap" > 615 <bool>true</bool> 616 </property> 617 </widget> 618 </item> 619 <item> 620 <widget class="QILabel" name="mTextSummaryHdr2" > 621 <property name="sizePolicy" > 622 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 623 <horstretch>0</horstretch> 624 <verstretch>0</verstretch> 625 </sizepolicy> 626 </property> 627 <property name="minimumSize" > 628 <size> 629 <width>300</width> 630 <height>0</height> 631 </size> 632 </property> 633 <property name="text" > 634 <string><p>You have selected the following media to boot an operating system from:</p></string> 635 </property> 636 <property name="wordWrap" > 637 <bool>true</bool> 638 </property> 639 </widget> 640 </item> 641 <item> 642 <widget class="QITextEdit" name="mTeSummary" > 643 <property name="sizePolicy" > 644 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 645 <horstretch>0</horstretch> 646 <verstretch>0</verstretch> 647 </sizepolicy> 648 </property> 649 <property name="minimumSize" > 650 <size> 651 <width>300</width> 652 <height>0</height> 653 </size> 654 </property> 655 <property name="frameShape" > 656 <enum>QFrame::NoFrame</enum> 657 </property> 658 <property name="autoFormatting" > 659 <set>QTextEdit::AutoAll</set> 660 </property> 661 <property name="readOnly" > 662 <bool>true</bool> 663 </property> 664 </widget> 665 </item> 666 <item> 667 <widget class="QILabel" name="mTextSummaryFtr1" > 668 <property name="sizePolicy" > 669 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 670 <horstretch>0</horstretch> 671 <verstretch>0</verstretch> 672 </sizepolicy> 673 </property> 674 <property name="minimumSize" > 675 <size> 676 <width>300</width> 677 <height>0</height> 678 </size> 679 </property> 680 <property name="text" > 681 <string><p>If the above is correct, press the <b>Finish</b> button. Once you press it, the selected media will be temporarily mounted on the virtual machine and the machine will start execution.</p><p>Please note that when you close the virtual machine, the specified media will be automatically unmounted and the boot device will be set back to the first hard disk.</p><p>Depending on the type of the setup program, you may need to manually unmount (eject) the media after the setup program reboots the virtual machine, to prevent the installation process from starting again. You can do this by selecting the corresponding <b>Unmount...</b> action in the <b>Devices</b> menu.</p></string> 682 </property> 683 <property name="alignment" > 684 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 685 </property> 686 <property name="wordWrap" > 687 <bool>true</bool> 688 </property> 689 </widget> 690 </item> 691 <item> 692 <widget class="QILabel" name="mTextSummaryFtr2" > 693 <property name="sizePolicy" > 694 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 695 <horstretch>0</horstretch> 696 <verstretch>0</verstretch> 697 </sizepolicy> 698 </property> 699 <property name="minimumSize" > 700 <size> 701 <width>300</width> 702 <height>0</height> 703 </size> 704 </property> 705 <property name="text" > 706 <string><p>If the above is correct, press the <b>Finish</b> button. Once you press it, the selected media will be mounted on the virtual machine and the machine will start execution.</p></string> 707 </property> 708 <property name="wordWrap" > 709 <bool>true</bool> 710 </property> 711 </widget> 712 </item> 713 <item> 714 <spacer> 715 <property name="orientation" > 716 <enum>Qt::Vertical</enum> 717 </property> 718 <property name="sizeType" > 719 <enum>QSizePolicy::Expanding</enum> 720 </property> 721 <property name="sizeHint" > 722 <size> 723 <width>0</width> 724 <height>0</height> 725 </size> 726 </property> 727 </spacer> 728 </item> 729 </layout> 730 </item> 731 </layout> 732 </item> 733 <item> 734 <widget class="Line" name="line32" > 735 <property name="orientation" > 736 <enum>Qt::Horizontal</enum> 737 </property> 738 </widget> 739 </item> 740 <item> 741 <layout class="QHBoxLayout" > 742 <item> 743 <spacer> 744 <property name="orientation" > 745 <enum>Qt::Horizontal</enum> 746 </property> 747 <property name="sizeHint" > 748 <size> 749 <width>0</width> 750 <height>0</height> 751 </size> 752 </property> 753 </spacer> 754 </item> 755 <item> 756 <widget class="QPushButton" name="mBtnBack4" > 757 <property name="text" > 758 <string>< &Back</string> 759 </property> 760 </widget> 761 </item> 762 <item> 763 <widget class="QPushButton" name="mBtnFinish" > 764 <property name="text" > 765 <string>&Finish</string> 766 </property> 767 </widget> 768 </item> 769 <item> 770 <spacer> 771 <property name="orientation" > 772 <enum>Qt::Horizontal</enum> 773 </property> 774 <property name="sizeType" > 775 <enum>QSizePolicy::Fixed</enum> 776 </property> 777 <property name="sizeHint" > 778 <size> 779 <width>5</width> 780 <height>0</height> 781 </size> 782 </property> 783 </spacer> 784 </item> 785 <item> 786 <widget class="QPushButton" name="mBtnCancel4" > 787 <property name="text" > 788 <string>Cancel</string> 789 </property> 790 </widget> 791 </item> 792 </layout> 793 </item> 794 </layout> 795 </widget> 45 <property name="wordWrap"> 46 <bool>true</bool> 47 </property> 796 48 </widget> 49 </item> 50 <item> 51 <widget class="QILabel" name="m_pPage2Text1Var2"> 52 <property name="text"> 53 <string><p>Select the type of media you would like to use for booting an operating system.</p></string> 54 </property> 55 <property name="wordWrap"> 56 <bool>true</bool> 57 </property> 58 </widget> 59 </item> 60 <item> 61 <widget class="QGroupBox" name="m_pCntType"> 62 <property name="title"> 63 <string>Media Type</string> 64 </property> 65 <layout class="QVBoxLayout" name="m_pLayout2"> 66 <item> 67 <widget class="QRadioButton" name="m_pTypeCD"> 68 <property name="text"> 69 <string>&CD/DVD-ROM Device</string> 70 </property> 71 </widget> 72 </item> 73 <item> 74 <widget class="QRadioButton" name="m_pTypeFD"> 75 <property name="text"> 76 <string>&Floppy Device</string> 77 </property> 78 </widget> 79 </item> 80 </layout> 81 </widget> 82 </item> 83 <item> 84 <widget class="QILabel" name="m_pPage2Text2Var1"> 85 <property name="text"> 86 <string><p>Select the media which contains the setup program of the operating system you want to install. This media must be bootable, otherwise the setup program will not be able to start.</p></string> 87 </property> 88 <property name="wordWrap"> 89 <bool>true</bool> 90 </property> 91 </widget> 92 </item> 93 <item> 94 <widget class="QILabel" name="m_pPage2Text2Var2"> 95 <property name="text"> 96 <string><p>Select the media that contains the operating system you want to work with. This media must be bootable, otherwise the operating system will not be able to start.</p></string> 97 </property> 98 <property name="wordWrap"> 99 <bool>true</bool> 100 </property> 101 </widget> 102 </item> 103 <item> 104 <widget class="QGroupBox" name="m_pCntSource"> 105 <property name="title"> 106 <string>Media Source</string> 107 </property> 108 <layout class="QHBoxLayout" name="m_pLayout3"> 109 <item> 110 <widget class="VBoxMediaComboBox" name="m_pMediaSelector"/> 111 </item> 112 <item> 113 <widget class="QToolButton" name="m_pSelectMediaButton"> 114 <property name="autoRaise"> 115 <bool>true</bool> 116 </property> 117 </widget> 118 </item> 119 </layout> 120 </widget> 121 </item> 122 <item> 123 <spacer name="m_pSpacer1"> 124 <property name="sizeHint" stdset="0"> 125 <size> 126 <width>0</width> 127 <height>62</height> 128 </size> 129 </property> 130 </spacer> 797 131 </item> 798 132 </layout> … … 809 143 <header>VBoxMediaComboBox.h</header> 810 144 </customwidget> 811 <customwidget>812 <class>QITextEdit</class>813 <extends>QTextEdit</extends>814 <header>QIAbstractWizard.h</header>815 </customwidget>816 145 </customwidgets> 817 <tabstops> 818 <tabstop>mBtnNext1</tabstop> 819 <tabstop>mBtnCancel1</tabstop> 820 <tabstop>mBtnBack2</tabstop> 821 <tabstop>mBtnNext2</tabstop> 822 <tabstop>mBtnCancel2</tabstop> 823 <tabstop>mBtnBack4</tabstop> 824 <tabstop>mBtnFinish</tabstop> 825 <tabstop>mBtnCancel4</tabstop> 826 </tabstops> 827 <resources> 828 <include location="../VirtualBox1.qrc" /> 829 </resources> 146 <resources/> 830 147 <connections/> 831 148 </ui> -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/firstrun/UIFirstRunWzdPage3.ui
r25432 r26079 1 <ui version="4.0" > 1 <?xml version="1.0" encoding="UTF-8"?> 2 <ui version="4.0"> 2 3 <comment> 3 4 VBox frontends: Qt4 GUI ("VirtualBox"): 4 5 5 Copyright (C) 200 8-2009Sun Microsystems, Inc.6 Copyright (C) 2009-2010 Sun Microsystems, Inc. 6 7 7 8 This file is part of VirtualBox Open Source Edition (OSE), as … … 17 18 additional information or have any questions. 18 19 </comment> 19 <class> VBoxVMFirstRunWzd</class>20 <widget class="Q Dialog" name="VBoxVMFirstRunWzd">21 <property name="geometry" 20 <class>UIFirstRunWzdPage3</class> 21 <widget class="QWidget" name="UIFirstRunWzdPage3"> 22 <property name="geometry"> 22 23 <rect> 23 24 <x>0</x> 24 25 <y>0</y> 25 <width> 782</width>26 <height> 561</height>26 <width>600</width> 27 <height>600</height> 27 28 </rect> 28 29 </property> 29 <property name="windowTitle" > 30 <string>First Run Wizard</string> 30 <property name="sizePolicy"> 31 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 32 <horstretch>0</horstretch> 33 <verstretch>0</verstretch> 34 </sizepolicy> 31 35 </property> 32 <layout class="QVBoxLayout" > 33 <property name="leftMargin" > 34 <number>0</number> 35 </property> 36 <property name="topMargin" > 37 <number>0</number> 38 </property> 39 <property name="rightMargin" > 40 <number>0</number> 41 </property> 36 <layout class="QVBoxLayout" name="m_pLayout1"> 42 37 <property name="bottomMargin" > 43 38 <number>0</number> 44 39 </property> 45 40 <item> 46 <widget class="Q StackedWidget" name="mPageStack">47 <property name=" currentIndex">48 < number>0</number>41 <widget class="QILabel" name="m_pPage3Text1Var1"> 42 <property name="text"> 43 <string><p>You have selected the following media to boot from:</p></string> 49 44 </property> 50 <widget class="QWidget" name="mPageWelcome" > 51 <layout class="QVBoxLayout" > 52 <item> 53 <widget class="QLabel" name="mPageWelcomeHdr" > 54 <property name="font" > 55 <font> 56 <family>Arial</family> 57 <pointsize>12</pointsize> 58 <weight>75</weight> 59 <bold>true</bold> 60 </font> 61 </property> 62 <property name="text" > 63 <string>Welcome to the First Run Wizard!</string> 64 </property> 65 </widget> 66 </item> 67 <item> 68 <widget class="Line" name="line11" > 69 <property name="orientation" > 70 <enum>Qt::Horizontal</enum> 71 </property> 72 </widget> 73 </item> 74 <item> 75 <layout class="QHBoxLayout" > 76 <property name="spacing" > 77 <number>10</number> 78 </property> 79 <item> 80 <widget class="QLabel" name="mLogoWelcome" > 81 <property name="sizePolicy" > 82 <sizepolicy vsizetype="Minimum" hsizetype="Maximum" > 83 <horstretch>0</horstretch> 84 <verstretch>0</verstretch> 85 </sizepolicy> 86 </property> 87 <property name="autoFillBackground" > 88 <bool>true</bool> 89 </property> 90 <property name="text" > 91 <string/> 92 </property> 93 <property name="pixmap" > 94 <pixmap resource="../VirtualBox1.qrc" >:/vmw_new_harddisk.png</pixmap> 95 </property> 96 <property name="alignment" > 97 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 98 </property> 99 </widget> 100 </item> 101 <item> 102 <layout class="QVBoxLayout" > 103 <property name="spacing" > 104 <number>10</number> 105 </property> 106 <item> 107 <widget class="QILabel" name="mTextWelcome1" > 108 <property name="sizePolicy" > 109 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 110 <horstretch>0</horstretch> 111 <verstretch>0</verstretch> 112 </sizepolicy> 113 </property> 114 <property name="minimumSize" > 115 <size> 116 <width>300</width> 117 <height>0</height> 118 </size> 119 </property> 120 <property name="text" > 121 <string><p>You have started a newly created virtual machine for the first time. This wizard will help you to perform the steps necessary for installing an operating system of your choice onto this virtual machine.</p><p>Use the <b>Next</b> button to go to the next page of the wizard and the <b>Back</b> button to return to the previous page. You can also press <b>Cancel</b> if you want to cancel the execution of this wizard.</p></string> 122 </property> 123 <property name="alignment" > 124 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 125 </property> 126 <property name="wordWrap" > 127 <bool>true</bool> 128 </property> 129 </widget> 130 </item> 131 <item> 132 <widget class="QILabel" name="mTextWelcome2" > 133 <property name="sizePolicy" > 134 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 135 <horstretch>0</horstretch> 136 <verstretch>0</verstretch> 137 </sizepolicy> 138 </property> 139 <property name="minimumSize" > 140 <size> 141 <width>300</width> 142 <height>0</height> 143 </size> 144 </property> 145 <property name="text" > 146 <string><p>You have started a newly created virtual machine for the first time. This wizard will help you to perform the steps necessary for booting an operating system of your choice on the virtual machine.</p><p>Note that you will not be able to install an operating system into this virtual machine right now because you did not attach any hard disk to it. If this is not what you want, you can cancel the execution of this wizard, select <b>Settings</b> from the <b>Machine</b> menu of the main VirtualBox window to access the settings dialog of this machine and change the hard disk configuration.</p><p>Use the <b>Next</b> button to go to the next page of the wizard and the <b>Back</b> button to return to the previous page. You can also press <b>Cancel</b> if you want to cancel the execution of this wizard.</p></string> 147 </property> 148 <property name="wordWrap" > 149 <bool>true</bool> 150 </property> 151 </widget> 152 </item> 153 <item> 154 <spacer> 155 <property name="orientation" > 156 <enum>Qt::Vertical</enum> 157 </property> 158 <property name="sizeHint" > 159 <size> 160 <width>0</width> 161 <height>0</height> 162 </size> 163 </property> 164 </spacer> 165 </item> 166 </layout> 167 </item> 168 </layout> 169 </item> 170 <item> 171 <widget class="Line" name="line12" > 172 <property name="orientation" > 173 <enum>Qt::Horizontal</enum> 174 </property> 175 </widget> 176 </item> 177 <item> 178 <layout class="QHBoxLayout" > 179 <item> 180 <spacer> 181 <property name="orientation" > 182 <enum>Qt::Horizontal</enum> 183 </property> 184 <property name="sizeHint" > 185 <size> 186 <width>0</width> 187 <height>0</height> 188 </size> 189 </property> 190 </spacer> 191 </item> 192 <item> 193 <widget class="QPushButton" name="mBtnBack1" > 194 <property name="enabled" > 195 <bool>false</bool> 196 </property> 197 <property name="text" > 198 <string>< &Back</string> 199 </property> 200 </widget> 201 </item> 202 <item> 203 <widget class="QPushButton" name="mBtnNext1" > 204 <property name="text" > 205 <string>&Next ></string> 206 </property> 207 </widget> 208 </item> 209 <item> 210 <spacer> 211 <property name="orientation" > 212 <enum>Qt::Horizontal</enum> 213 </property> 214 <property name="sizeType" > 215 <enum>QSizePolicy::Fixed</enum> 216 </property> 217 <property name="sizeHint" > 218 <size> 219 <width>5</width> 220 <height>0</height> 221 </size> 222 </property> 223 </spacer> 224 </item> 225 <item> 226 <widget class="QPushButton" name="mBtnCancel1" > 227 <property name="text" > 228 <string>Cancel</string> 229 </property> 230 </widget> 231 </item> 232 </layout> 233 </item> 234 </layout> 235 </widget> 236 <widget class="QWidget" name="mPageMedia" > 237 <layout class="QVBoxLayout" > 238 <item> 239 <widget class="QLabel" name="mPageMediaHdr" > 240 <property name="font" > 241 <font> 242 <family>Arial</family> 243 <pointsize>12</pointsize> 244 <weight>75</weight> 245 <bold>true</bold> 246 </font> 247 </property> 248 <property name="text" > 249 <string>Select Installation Media</string> 250 </property> 251 </widget> 252 </item> 253 <item> 254 <widget class="Line" name="line21" > 255 <property name="orientation" > 256 <enum>Qt::Horizontal</enum> 257 </property> 258 </widget> 259 </item> 260 <item> 261 <layout class="QHBoxLayout" > 262 <property name="spacing" > 263 <number>10</number> 264 </property> 265 <item> 266 <widget class="QLabel" name="mLogoType" > 267 <property name="sizePolicy" > 268 <sizepolicy vsizetype="Minimum" hsizetype="Maximum" > 269 <horstretch>0</horstretch> 270 <verstretch>0</verstretch> 271 </sizepolicy> 272 </property> 273 <property name="autoFillBackground" > 274 <bool>true</bool> 275 </property> 276 <property name="text" > 277 <string/> 278 </property> 279 <property name="pixmap" > 280 <pixmap resource="../VirtualBox1.qrc" >:/vmw_new_harddisk.png</pixmap> 281 </property> 282 <property name="alignment" > 283 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 284 </property> 285 </widget> 286 </item> 287 <item> 288 <layout class="QVBoxLayout" > 289 <property name="spacing" > 290 <number>10</number> 291 </property> 292 <item> 293 <widget class="QILabel" name="mTextType1" > 294 <property name="sizePolicy" > 295 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 296 <horstretch>0</horstretch> 297 <verstretch>0</verstretch> 298 </sizepolicy> 299 </property> 300 <property name="minimumSize" > 301 <size> 302 <width>300</width> 303 <height>0</height> 304 </size> 305 </property> 306 <property name="text" > 307 <string><p>Select the type of media you would like to use for installation.</p></string> 308 </property> 309 <property name="alignment" > 310 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 311 </property> 312 <property name="wordWrap" > 313 <bool>true</bool> 314 </property> 315 </widget> 316 </item> 317 <item> 318 <widget class="QILabel" name="mTextType2" > 319 <property name="sizePolicy" > 320 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 321 <horstretch>0</horstretch> 322 <verstretch>0</verstretch> 323 </sizepolicy> 324 </property> 325 <property name="minimumSize" > 326 <size> 327 <width>300</width> 328 <height>0</height> 329 </size> 330 </property> 331 <property name="text" > 332 <string><p>Select the type of media you would like to use for booting an operating system.</p></string> 333 </property> 334 <property name="wordWrap" > 335 <bool>true</bool> 336 </property> 337 </widget> 338 </item> 339 <item> 340 <widget class="QGroupBox" name="mGbType" > 341 <property name="sizePolicy" > 342 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 343 <horstretch>0</horstretch> 344 <verstretch>0</verstretch> 345 </sizepolicy> 346 </property> 347 <property name="title" > 348 <string>Media Type</string> 349 </property> 350 <layout class="QVBoxLayout" > 351 <property name="topMargin" > 352 <number>4</number> 353 </property> 354 <item> 355 <widget class="QRadioButton" name="mRbCdType" > 356 <property name="sizePolicy" > 357 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 358 <horstretch>0</horstretch> 359 <verstretch>0</verstretch> 360 </sizepolicy> 361 </property> 362 <property name="text" > 363 <string>&CD/DVD-ROM Device</string> 364 </property> 365 <property name="checked" > 366 <bool>true</bool> 367 </property> 368 </widget> 369 </item> 370 <item> 371 <widget class="QRadioButton" name="mRbFdType" > 372 <property name="sizePolicy" > 373 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 374 <horstretch>0</horstretch> 375 <verstretch>0</verstretch> 376 </sizepolicy> 377 </property> 378 <property name="text" > 379 <string>&Floppy Device</string> 380 </property> 381 </widget> 382 </item> 383 </layout> 384 </widget> 385 </item> 386 <item> 387 <widget class="QILabel" name="mTextSource1" > 388 <property name="sizePolicy" > 389 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 390 <horstretch>0</horstretch> 391 <verstretch>0</verstretch> 392 </sizepolicy> 393 </property> 394 <property name="minimumSize" > 395 <size> 396 <width>300</width> 397 <height>0</height> 398 </size> 399 </property> 400 <property name="text" > 401 <string><p>Select the media which contains the setup program of the operating system you want to install. This media must be bootable, otherwise the setup program will not be able to start.</p></string> 402 </property> 403 <property name="wordWrap" > 404 <bool>true</bool> 405 </property> 406 </widget> 407 </item> 408 <item> 409 <widget class="QILabel" name="mTextSource2" > 410 <property name="sizePolicy" > 411 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 412 <horstretch>0</horstretch> 413 <verstretch>0</verstretch> 414 </sizepolicy> 415 </property> 416 <property name="minimumSize" > 417 <size> 418 <width>300</width> 419 <height>0</height> 420 </size> 421 </property> 422 <property name="text" > 423 <string><p>Select the media that contains the operating system you want to work with. This media must be bootable, otherwise the operating system will not be able to start.</p></string> 424 </property> 425 <property name="wordWrap" > 426 <bool>true</bool> 427 </property> 428 </widget> 429 </item> 430 <item> 431 <widget class="QGroupBox" name="mGbSource" > 432 <property name="sizePolicy" > 433 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 434 <horstretch>0</horstretch> 435 <verstretch>0</verstretch> 436 </sizepolicy> 437 </property> 438 <property name="title" > 439 <string>Media Source</string> 440 </property> 441 <layout class="QHBoxLayout" > 442 <property name="topMargin" > 443 <number>4</number> 444 </property> 445 <item> 446 <widget class="VBoxMediaComboBox" name="mCbMedia" /> 447 </item> 448 <item> 449 <widget class="QToolButton" name="mTbVmm" > 450 <property name="icon" > 451 <iconset resource="../VirtualBox1.qrc" >:/select_file_16px.png</iconset> 452 </property> 453 </widget> 454 </item> 455 </layout> 456 </widget> 457 </item> 458 <item> 459 <spacer> 460 <property name="orientation" > 461 <enum>Qt::Vertical</enum> 462 </property> 463 <property name="sizeHint" > 464 <size> 465 <width>0</width> 466 <height>0</height> 467 </size> 468 </property> 469 </spacer> 470 </item> 471 </layout> 472 </item> 473 </layout> 474 </item> 475 <item> 476 <widget class="Line" name="line22" > 477 <property name="orientation" > 478 <enum>Qt::Horizontal</enum> 479 </property> 480 </widget> 481 </item> 482 <item> 483 <layout class="QHBoxLayout" > 484 <item> 485 <spacer> 486 <property name="orientation" > 487 <enum>Qt::Horizontal</enum> 488 </property> 489 <property name="sizeHint" > 490 <size> 491 <width>0</width> 492 <height>0</height> 493 </size> 494 </property> 495 </spacer> 496 </item> 497 <item> 498 <widget class="QPushButton" name="mBtnBack2" > 499 <property name="text" > 500 <string>< &Back</string> 501 </property> 502 </widget> 503 </item> 504 <item> 505 <widget class="QPushButton" name="mBtnNext2" > 506 <property name="text" > 507 <string>&Next ></string> 508 </property> 509 </widget> 510 </item> 511 <item> 512 <spacer> 513 <property name="orientation" > 514 <enum>Qt::Horizontal</enum> 515 </property> 516 <property name="sizeType" > 517 <enum>QSizePolicy::Fixed</enum> 518 </property> 519 <property name="sizeHint" > 520 <size> 521 <width>5</width> 522 <height>0</height> 523 </size> 524 </property> 525 </spacer> 526 </item> 527 <item> 528 <widget class="QPushButton" name="mBtnCancel2" > 529 <property name="text" > 530 <string>Cancel</string> 531 </property> 532 </widget> 533 </item> 534 </layout> 535 </item> 536 </layout> 537 </widget> 538 <widget class="QWidget" name="mPageSummary" > 539 <layout class="QVBoxLayout" > 540 <item> 541 <widget class="QLabel" name="mPageSummaryHdr" > 542 <property name="font" > 543 <font> 544 <family>Arial</family> 545 <pointsize>12</pointsize> 546 <weight>75</weight> 547 <bold>true</bold> 548 </font> 549 </property> 550 <property name="text" > 551 <string>Summary</string> 552 </property> 553 </widget> 554 </item> 555 <item> 556 <widget class="Line" name="line31" > 557 <property name="orientation" > 558 <enum>Qt::Horizontal</enum> 559 </property> 560 </widget> 561 </item> 562 <item> 563 <layout class="QHBoxLayout" > 564 <property name="spacing" > 565 <number>10</number> 566 </property> 567 <item> 568 <widget class="QLabel" name="mLogoSummary" > 569 <property name="sizePolicy" > 570 <sizepolicy vsizetype="Minimum" hsizetype="Maximum" > 571 <horstretch>0</horstretch> 572 <verstretch>0</verstretch> 573 </sizepolicy> 574 </property> 575 <property name="autoFillBackground" > 576 <bool>true</bool> 577 </property> 578 <property name="text" > 579 <string/> 580 </property> 581 <property name="pixmap" > 582 <pixmap resource="../VirtualBox1.qrc" >:/vmw_new_harddisk.png</pixmap> 583 </property> 584 <property name="alignment" > 585 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 586 </property> 587 </widget> 588 </item> 589 <item> 590 <layout class="QVBoxLayout" > 591 <property name="spacing" > 592 <number>10</number> 593 </property> 594 <item> 595 <widget class="QILabel" name="mTextSummaryHdr1" > 596 <property name="sizePolicy" > 597 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 598 <horstretch>0</horstretch> 599 <verstretch>0</verstretch> 600 </sizepolicy> 601 </property> 602 <property name="minimumSize" > 603 <size> 604 <width>300</width> 605 <height>0</height> 606 </size> 607 </property> 608 <property name="text" > 609 <string><p>You have selected the following media to boot from:</p></string> 610 </property> 611 <property name="alignment" > 612 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 613 </property> 614 <property name="wordWrap" > 615 <bool>true</bool> 616 </property> 617 </widget> 618 </item> 619 <item> 620 <widget class="QILabel" name="mTextSummaryHdr2" > 621 <property name="sizePolicy" > 622 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 623 <horstretch>0</horstretch> 624 <verstretch>0</verstretch> 625 </sizepolicy> 626 </property> 627 <property name="minimumSize" > 628 <size> 629 <width>300</width> 630 <height>0</height> 631 </size> 632 </property> 633 <property name="text" > 634 <string><p>You have selected the following media to boot an operating system from:</p></string> 635 </property> 636 <property name="wordWrap" > 637 <bool>true</bool> 638 </property> 639 </widget> 640 </item> 641 <item> 642 <widget class="QITextEdit" name="mTeSummary" > 643 <property name="sizePolicy" > 644 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 645 <horstretch>0</horstretch> 646 <verstretch>0</verstretch> 647 </sizepolicy> 648 </property> 649 <property name="minimumSize" > 650 <size> 651 <width>300</width> 652 <height>0</height> 653 </size> 654 </property> 655 <property name="frameShape" > 656 <enum>QFrame::NoFrame</enum> 657 </property> 658 <property name="autoFormatting" > 659 <set>QTextEdit::AutoAll</set> 660 </property> 661 <property name="readOnly" > 662 <bool>true</bool> 663 </property> 664 </widget> 665 </item> 666 <item> 667 <widget class="QILabel" name="mTextSummaryFtr1" > 668 <property name="sizePolicy" > 669 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 670 <horstretch>0</horstretch> 671 <verstretch>0</verstretch> 672 </sizepolicy> 673 </property> 674 <property name="minimumSize" > 675 <size> 676 <width>300</width> 677 <height>0</height> 678 </size> 679 </property> 680 <property name="text" > 681 <string><p>If the above is correct, press the <b>Finish</b> button. Once you press it, the selected media will be temporarily mounted on the virtual machine and the machine will start execution.</p><p>Please note that when you close the virtual machine, the specified media will be automatically unmounted and the boot device will be set back to the first hard disk.</p><p>Depending on the type of the setup program, you may need to manually unmount (eject) the media after the setup program reboots the virtual machine, to prevent the installation process from starting again. You can do this by selecting the corresponding <b>Unmount...</b> action in the <b>Devices</b> menu.</p></string> 682 </property> 683 <property name="alignment" > 684 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 685 </property> 686 <property name="wordWrap" > 687 <bool>true</bool> 688 </property> 689 </widget> 690 </item> 691 <item> 692 <widget class="QILabel" name="mTextSummaryFtr2" > 693 <property name="sizePolicy" > 694 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 695 <horstretch>0</horstretch> 696 <verstretch>0</verstretch> 697 </sizepolicy> 698 </property> 699 <property name="minimumSize" > 700 <size> 701 <width>300</width> 702 <height>0</height> 703 </size> 704 </property> 705 <property name="text" > 706 <string><p>If the above is correct, press the <b>Finish</b> button. Once you press it, the selected media will be mounted on the virtual machine and the machine will start execution.</p></string> 707 </property> 708 <property name="wordWrap" > 709 <bool>true</bool> 710 </property> 711 </widget> 712 </item> 713 <item> 714 <spacer> 715 <property name="orientation" > 716 <enum>Qt::Vertical</enum> 717 </property> 718 <property name="sizeType" > 719 <enum>QSizePolicy::Expanding</enum> 720 </property> 721 <property name="sizeHint" > 722 <size> 723 <width>0</width> 724 <height>0</height> 725 </size> 726 </property> 727 </spacer> 728 </item> 729 </layout> 730 </item> 731 </layout> 732 </item> 733 <item> 734 <widget class="Line" name="line32" > 735 <property name="orientation" > 736 <enum>Qt::Horizontal</enum> 737 </property> 738 </widget> 739 </item> 740 <item> 741 <layout class="QHBoxLayout" > 742 <item> 743 <spacer> 744 <property name="orientation" > 745 <enum>Qt::Horizontal</enum> 746 </property> 747 <property name="sizeHint" > 748 <size> 749 <width>0</width> 750 <height>0</height> 751 </size> 752 </property> 753 </spacer> 754 </item> 755 <item> 756 <widget class="QPushButton" name="mBtnBack4" > 757 <property name="text" > 758 <string>< &Back</string> 759 </property> 760 </widget> 761 </item> 762 <item> 763 <widget class="QPushButton" name="mBtnFinish" > 764 <property name="text" > 765 <string>&Finish</string> 766 </property> 767 </widget> 768 </item> 769 <item> 770 <spacer> 771 <property name="orientation" > 772 <enum>Qt::Horizontal</enum> 773 </property> 774 <property name="sizeType" > 775 <enum>QSizePolicy::Fixed</enum> 776 </property> 777 <property name="sizeHint" > 778 <size> 779 <width>5</width> 780 <height>0</height> 781 </size> 782 </property> 783 </spacer> 784 </item> 785 <item> 786 <widget class="QPushButton" name="mBtnCancel4" > 787 <property name="text" > 788 <string>Cancel</string> 789 </property> 790 </widget> 791 </item> 792 </layout> 793 </item> 794 </layout> 795 </widget> 45 <property name="wordWrap"> 46 <bool>true</bool> 47 </property> 796 48 </widget> 49 </item> 50 <item> 51 <widget class="QILabel" name="m_pPage3Text1Var2"> 52 <property name="text"> 53 <string><p>You have selected the following media to boot an operating system from:</p></string> 54 </property> 55 <property name="wordWrap"> 56 <bool>true</bool> 57 </property> 58 </widget> 59 </item> 60 <item> 61 <widget class="QTextEdit" name="m_pSummaryText"> 62 <property name="sizePolicy"> 63 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 64 <horstretch>0</horstretch> 65 <verstretch>0</verstretch> 66 </sizepolicy> 67 </property> 68 <property name="minimumSize"> 69 <size> 70 <width>300</width> 71 <height>0</height> 72 </size> 73 </property> 74 <property name="frameShape"> 75 <enum>QFrame::NoFrame</enum> 76 </property> 77 <property name="readOnly"> 78 <bool>true</bool> 79 </property> 80 </widget> 81 </item> 82 <item> 83 <widget class="QILabel" name="m_pPage3Text2Var1"> 84 <property name="text"> 85 <string><p>If the above is correct, press the <b>Finish</b> button. Once you press it, the selected media will be temporarily mounted on the virtual machine and the machine will start execution.</p><p>Please note that when you close the virtual machine, the specified media will be automatically unmounted and the boot device will be set back to the first hard disk.</p><p>Depending on the type of the setup program, you may need to manually unmount (eject) the media after the setup program reboots the virtual machine, to prevent the installation process from starting again. You can do this by selecting the corresponding <b>Unmount...</b> action in the <b>Devices</b> menu.</p></string> 86 </property> 87 <property name="wordWrap"> 88 <bool>true</bool> 89 </property> 90 </widget> 91 </item> 92 <item> 93 <widget class="QILabel" name="m_pPage3Text2Var2"> 94 <property name="text"> 95 <string><p>If the above is correct, press the <b>Finish</b> button. Once you press it, the selected media will be mounted on the virtual machine and the machine will start execution.</p></string> 96 </property> 97 <property name="wordWrap"> 98 <bool>true</bool> 99 </property> 100 </widget> 101 </item> 102 <item> 103 <spacer name="m_pSpacer1"> 104 <property name="sizeHint" stdset="0"> 105 <size> 106 <width>0</width> 107 <height>117</height> 108 </size> 109 </property> 110 </spacer> 797 111 </item> 798 112 </layout> … … 804 118 <header>QILabel.h</header> 805 119 </customwidget> 806 <customwidget>807 <class>VBoxMediaComboBox</class>808 <extends>QComboBox</extends>809 <header>VBoxMediaComboBox.h</header>810 </customwidget>811 <customwidget>812 <class>QITextEdit</class>813 <extends>QTextEdit</extends>814 <header>QIAbstractWizard.h</header>815 </customwidget>816 120 </customwidgets> 817 <tabstops> 818 <tabstop>mBtnNext1</tabstop> 819 <tabstop>mBtnCancel1</tabstop> 820 <tabstop>mBtnBack2</tabstop> 821 <tabstop>mBtnNext2</tabstop> 822 <tabstop>mBtnCancel2</tabstop> 823 <tabstop>mBtnBack4</tabstop> 824 <tabstop>mBtnFinish</tabstop> 825 <tabstop>mBtnCancel4</tabstop> 826 </tabstops> 827 <resources> 828 <include location="../VirtualBox1.qrc" /> 829 </resources> 121 <resources/> 830 122 <connections/> 831 123 </ui> -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/importappliance/UIImportApplianceWzd.cpp
r25432 r26079 2 2 * 3 3 * VBox frontends: Qt4 GUI ("VirtualBox"): 4 * VBoxImportApplianceclass implementation4 * UIImportApplianceWzd class implementation 5 5 */ 6 6 7 7 /* 8 * Copyright (C) 2009 Sun Microsystems, Inc.8 * Copyright (C) 2009-2010 Sun Microsystems, Inc. 9 9 * 10 10 * This file is part of VirtualBox Open Source Edition (OSE), as … … 21 21 */ 22 22 23 /* VBox includes */ 24 #include "VBoxGlobal.h" 25 #include "VBoxImportApplianceWzd.h" 26 #include "VBoxProblemReporter.h" 27 #include "QIFileDialog.h" 28 #include "QIWidgetValidator.h" 29 30 /* Qt includes */ 23 /* Global includes */ 31 24 #include <QDialogButtonBox> 32 25 #include <QFileInfo> 33 26 #include <QPrintDialog> 34 27 #include <QPrinter> 28 #include <QPushButton> 35 29 #include <QTextStream> 36 30 37 //////////////////////////////////////////////////////////////////////////////// 38 // VBoxImportLicenseViewer 39 40 VBoxImportLicenseViewer::VBoxImportLicenseViewer (QWidget *aParent /* = NULL */) 41 : QIDialog (aParent) 42 { 43 QVBoxLayout *pMainLayout = new QVBoxLayout (this); 44 pMainLayout->setMargin (12); 45 46 mCaption = new QLabel (this); 47 mCaption->setWordWrap (true); 48 pMainLayout->addWidget (mCaption); 49 50 mLicenseText = new QTextEdit (this); 51 mLicenseText->setReadOnly (true); 52 pMainLayout->addWidget (mLicenseText); 53 54 mButtonBox = new QDialogButtonBox (QDialogButtonBox::No | QDialogButtonBox::Yes, Qt::Horizontal, this); 55 mPrintBtn = new QPushButton (this); 56 mButtonBox->addButton (mPrintBtn, QDialogButtonBox::ActionRole); 57 mSaveBtn = new QPushButton (this); 58 mButtonBox->addButton (mSaveBtn, QDialogButtonBox::ActionRole); 59 mButtonBox->button (QDialogButtonBox::Yes)->setDefault (true); 60 connect (mButtonBox, SIGNAL (rejected()), 61 this, SLOT (reject())); 62 connect (mButtonBox, SIGNAL (accepted()), 63 this, SLOT (accept())); 64 connect (mPrintBtn, SIGNAL (clicked()), 65 this, SLOT (print())); 66 connect (mSaveBtn, SIGNAL (clicked()), 67 this, SLOT (save())); 68 pMainLayout->addWidget (mButtonBox); 69 70 retranslateUi(); 71 } 72 73 void VBoxImportLicenseViewer::setContent (const QString &aName, const QString &aText) 74 { 75 mName = aName; 76 mText = aText; 77 mCaption->setText (tr ("<b>The virtual system \"%1\" requires that you agree to the terms and conditions of the software license agreement shown below.</b><br /><br />Click <b>Agree</b> to continue or click <b>Disagree</b> to cancel the import.").arg (mName)); 78 mLicenseText->setText (mText); 79 80 } 81 82 void VBoxImportLicenseViewer::retranslateUi() 83 { 84 setWindowTitle (tr ("Software License Agreement")); 85 mButtonBox->button (QDialogButtonBox::No)->setText (tr ("&Disagree")); 86 mButtonBox->button (QDialogButtonBox::Yes)->setText (tr ("&Agree")); 87 mPrintBtn->setText (tr ("&Print...")); 88 mSaveBtn->setText (tr ("&Save...")); 89 90 setContent (mName, mText); 91 } 92 93 void VBoxImportLicenseViewer::print() 31 /* Local includes */ 32 #include "VBoxGlobal.h" 33 #include "UIImportApplianceWzd.h" 34 #include "QIFileDialog.h" 35 36 UIImportLicenseViewer::UIImportLicenseViewer(QWidget *pParent) : QIDialog(pParent) 37 { 38 QVBoxLayout *pMainLayout = new QVBoxLayout(this); 39 pMainLayout->setMargin(12); 40 41 m_pCaption = new QLabel(this); 42 m_pCaption->setWordWrap(true); 43 pMainLayout->addWidget(m_pCaption); 44 45 m_pLicenseText = new QTextEdit(this); 46 m_pLicenseText->setReadOnly(true); 47 pMainLayout->addWidget(m_pLicenseText); 48 49 m_pButtonBox = new QDialogButtonBox(QDialogButtonBox::No | QDialogButtonBox::Yes, Qt::Horizontal, this); 50 m_pPrintButton = new QPushButton(this); 51 m_pButtonBox->addButton(m_pPrintButton, QDialogButtonBox::ActionRole); 52 m_pSaveButton = new QPushButton(this); 53 m_pButtonBox->addButton(m_pSaveButton, QDialogButtonBox::ActionRole); 54 m_pButtonBox->button(QDialogButtonBox::Yes)->setDefault(true); 55 connect(m_pButtonBox, SIGNAL(rejected()), this, SLOT(reject())); 56 connect(m_pButtonBox, SIGNAL(accepted()), this, SLOT(accept())); 57 connect(m_pPrintButton, SIGNAL(clicked()), this, SLOT(sltPrint())); 58 connect(m_pSaveButton, SIGNAL(clicked()), this, SLOT(sltSave())); 59 pMainLayout->addWidget(m_pButtonBox); 60 61 retranslateUi(); 62 } 63 64 void UIImportLicenseViewer::setContents(const QString &strName, const QString &strText) 65 { 66 m_strName = strName; 67 m_strText = strText; 68 retranslateUi(); 69 } 70 71 void UIImportLicenseViewer::retranslateUi() 72 { 73 setWindowTitle(tr("Software License Agreement")); 74 m_pCaption->setText(tr("<b>The virtual system \"%1\" requires that you agree to the terms and conditions " 75 "of the software license agreement shown below.</b><br /><br />Click <b>Agree</b> " 76 "to continue or click <b>Disagree</b> to cancel the import.").arg(m_strName)); 77 m_pLicenseText->setText(m_strText); 78 m_pButtonBox->button(QDialogButtonBox::No)->setText(tr("&Disagree")); 79 m_pButtonBox->button(QDialogButtonBox::Yes)->setText(tr("&Agree")); 80 m_pPrintButton->setText(tr("&Print...")); 81 m_pSaveButton->setText(tr("&Save...")); 82 } 83 84 void UIImportLicenseViewer::sltPrint() 94 85 { 95 86 QPrinter printer; 96 QPrintDialog pd 87 QPrintDialog pd(&printer, this); 97 88 if (pd.exec() == QDialog::Accepted) 98 mLicenseText->print (&printer); 99 } 100 101 void VBoxImportLicenseViewer::save() 102 { 103 QString fileName = QIFileDialog::getSaveFileName (vboxGlobal().documentsPath(), tr("Text (*.txt)"), this, tr("Save license to file...")); 89 m_pLicenseText->print(&printer); 90 } 91 92 void UIImportLicenseViewer::sltSave() 93 { 94 QString fileName = QIFileDialog::getSaveFileName(vboxGlobal().documentsPath(), tr("Text (*.txt)"), 95 this, tr("Save license to file...")); 104 96 if (!fileName.isEmpty()) 105 97 { 106 QFile file 98 QFile file(fileName); 107 99 if (file.open(QFile::WriteOnly | QFile::Truncate)) 108 100 { 109 QTextStream out 110 out << m LicenseText->toPlainText();101 QTextStream out(&file); 102 out << m_pLicenseText->toPlainText(); 111 103 } 112 104 } 113 105 } 114 106 115 //////////////////////////////////////////////////////////////////////////////// 116 // VBoxImportApplianceWzd 117 118 VBoxImportApplianceWzd::VBoxImportApplianceWzd (QWidget *aParent /* = NULL */) 119 : QIWithRetranslateUI<QIAbstractWizard> (aParent) 120 { 121 /* Apply UI decorations */ 122 Ui::VBoxImportApplianceWzd::setupUi (this); 123 124 /* Initialize wizard hdr */ 125 initializeWizardHdr(); 126 127 /* Configure the file selector */ 128 mFileSelector->setMode (VBoxFilePathSelectorWidget::Mode_File_Open); 129 mFileSelector->setFileDialogTitle (tr ("Select an appliance to import")); 130 mFileSelector->setFileFilters (tr ("Open Virtualization Format (%1)").arg ("*.ovf")); 131 mFileSelector->setHomeDir (vboxGlobal().documentsPath()); 132 133 /* Validator for the file selector page */ 134 mWValFileSelector = new QIWidgetValidator (mFileSelectPage, this); 135 connect (mWValFileSelector, SIGNAL (validityChanged (const QIWidgetValidator *)), 136 this, SLOT (enableNext (const QIWidgetValidator *))); 137 connect (mWValFileSelector, SIGNAL (isValidRequested (QIWidgetValidator *)), 138 this, SLOT (revalidate (QIWidgetValidator *))); 139 connect (mFileSelector, SIGNAL (pathChanged (const QString &)), 140 mWValFileSelector, SLOT (revalidate())); 141 142 /* Connect the restore button with the settings widget */ 143 connect (mBtnRestore, SIGNAL (clicked()), 144 mImportSettingsWgt, SLOT (restoreDefaults())); 145 146 mWValFileSelector->revalidate(); 147 148 /* Initialize wizard ftr */ 149 initializeWizardFtr(); 150 151 retranslateUi(); 152 } 153 154 void VBoxImportApplianceWzd::retranslateUi() 107 UIImportApplianceWzd::UIImportApplianceWzd(QWidget *pParent) : QIWizard(pParent) 108 { 109 /* Create & add pages */ 110 addPage(new UIImportApplianceWzdPage1); 111 addPage(new UIImportApplianceWzdPage2); 112 113 /* Translate */ 114 retranslateUi(); 115 116 /* Resize to 'golden ratio' */ 117 resizeToGoldenRatio(); 118 119 /* Assign watermark */ 120 assignWatermark(":/vmw_ovf_import.png"); 121 122 /* Configure 'Restore Defaults' button */ 123 AssertMsg(!field("applianceWidget").value<ImportAppliancePointer>().isNull(), ("Appliance Widget is not set!\n")); 124 connect(this, SIGNAL(customButtonClicked(int)), field("applianceWidget").value<ImportAppliancePointer>(), SLOT(restoreDefaults())); 125 connect(this, SIGNAL(currentIdChanged(int)), this, SLOT(sltCurrentIdChanged(int))); 126 } 127 128 void UIImportApplianceWzd::retranslateUi() 129 { 130 /* Wizard title */ 131 setWindowTitle(tr("Appliance Import Wizard")); 132 133 /* Translate 'Restore Defaults' button */ 134 setButtonText(QWizard::CustomButton1, tr("Restore Defaults")); 135 } 136 137 void UIImportApplianceWzd::sltCurrentIdChanged(int iId) 138 { 139 setOption(QWizard::HaveCustomButton1, iId == 1 /* Page #2 */); 140 } 141 142 UIImportApplianceWzdPage1::UIImportApplianceWzdPage1() 143 { 144 /* Decorate page */ 145 Ui::UIImportApplianceWzdPage1::setupUi(this); 146 147 /* Setup file selector */ 148 m_pFileSelector->setMode(VBoxFilePathSelectorWidget::Mode_File_Open); 149 m_pFileSelector->setHomeDir(vboxGlobal().documentsPath()); 150 151 /* Setup validation */ 152 connect(m_pFileSelector, SIGNAL(pathChanged(const QString &)), this, SIGNAL(completeChanged())); 153 154 /* Translate */ 155 retranslateUi(); 156 } 157 158 void UIImportApplianceWzdPage1::retranslateUi() 155 159 { 156 160 /* Translate uic generated strings */ 157 Ui::VBoxImportApplianceWzd::retranslateUi (this); 158 } 159 160 void VBoxImportApplianceWzd::revalidate (QIWidgetValidator *aWval) 161 { 162 /* Do individual validations for pages */ 163 bool valid = aWval->isOtherValid(); 164 165 if (aWval == mWValFileSelector) 166 valid = mFileSelector->path().toLower().endsWith (".ovf") && 167 QFileInfo (mFileSelector->path()).exists(); 168 169 aWval->setOtherValid (valid); 170 } 171 172 void VBoxImportApplianceWzd::enableNext (const QIWidgetValidator *aWval) 173 { 174 nextButton (aWval->widget())->setEnabled (aWval->isValid()); 175 } 176 177 void VBoxImportApplianceWzd::accept() 178 { 179 /* Make sure the final values are puted back. */ 180 mImportSettingsWgt->prepareImport(); 161 Ui::UIImportApplianceWzdPage1::retranslateUi(this); 162 163 /* Translate the file selector */ 164 m_pFileSelector->setFileDialogTitle(tr("Select an appliance to import")); 165 m_pFileSelector->setFileFilters(tr("Open Virtualization Format (%1)").arg("*.ovf")); 166 167 /* Wizard page 1 title */ 168 setTitle(tr("Welcome to the Appliance Import Wizard!")); 169 } 170 171 bool UIImportApplianceWzdPage1::isComplete() const 172 { 173 return m_pFileSelector->path().toLower().endsWith(".ovf") && QFileInfo(m_pFileSelector->path()).exists(); 174 } 175 176 bool UIImportApplianceWzdPage1::validatePage() 177 { 178 AssertMsg(!field("applianceWidget").value<ImportAppliancePointer>().isNull(), ("Appliance Widget is not set!\n")); 179 VBoxImportApplianceWgt *applianceWidget = field("applianceWidget").value<ImportAppliancePointer>(); 180 181 /* Set the file path only if something had changed */ 182 if (m_pFileSelector->isModified()) 183 { 184 applianceWidget->setFile(m_pFileSelector->path()); 185 /* Reset the modified bit afterwards */ 186 m_pFileSelector->resetModified(); 187 } 188 189 /* If we have a valid ovf proceed to the appliance settings page */ 190 return applianceWidget->isValid(); 191 } 192 193 UIImportApplianceWzdPage2::UIImportApplianceWzdPage2() 194 { 195 /* Decorate page */ 196 Ui::UIImportApplianceWzdPage2::setupUi(this); 197 198 /* Register ImportAppliancePointer class */ 199 qRegisterMetaType<ImportAppliancePointer>(); 200 201 /* Register 'applianceWidget' field! */ 202 registerField("applianceWidget", this, "applianceWidget"); 203 m_pApplianceWidget = m_pSettingsCnt; 204 205 /* Translate */ 206 retranslateUi(); 207 } 208 209 void UIImportApplianceWzdPage2::retranslateUi() 210 { 211 /* Translate uic generated strings */ 212 Ui::UIImportApplianceWzdPage2::retranslateUi(this); 213 214 /* Wizard page 2 title */ 215 setTitle(tr("Appliance Import Settings")); 216 } 217 218 bool UIImportApplianceWzdPage2::validatePage() 219 { 220 /* Make sure the final values are puted back */ 221 m_pSettingsCnt->prepareImport(); 181 222 /* Check if there are license agreements the user must confirm */ 182 QList < QPair <QString, QString> > licAgreements = m ImportSettingsWgt->licenseAgreements();223 QList < QPair <QString, QString> > licAgreements = m_pSettingsCnt->licenseAgreements(); 183 224 if (!licAgreements.isEmpty()) 184 225 { 185 VBoxImportLicenseViewer ilv(this);186 for (int i =0; i < licAgreements.size(); ++i)226 UIImportLicenseViewer ilv(this); 227 for (int i = 0; i < licAgreements.size(); ++ i) 187 228 { 188 const QPair <QString, QString> &lic = licAgreements.at 189 ilv.setContent 229 const QPair <QString, QString> &lic = licAgreements.at(i); 230 ilv.setContents(lic.first, lic.second); 190 231 if (ilv.exec() == QDialog::Rejected) 191 return ;232 return false; 192 233 } 193 234 } 194 235 /* Now import all virtual systems */ 195 if (mImportSettingsWgt->import()) 196 QIAbstractWizard::accept(); 197 } 198 199 void VBoxImportApplianceWzd::showNextPage() 200 { 201 if (sender() == mBtnNext1) 202 { 203 if (mFileSelector->isModified()) 204 { 205 /* Set the file path only if something has changed */ 206 mImportSettingsWgt->setFile (mFileSelector->path()); 207 /* Reset the modified bit afterwards */ 208 mFileSelector->resetModified(); 209 } 210 211 /* If we have a valid ovf proceed to the appliance settings page */ 212 if (mImportSettingsWgt->isValid()) 213 QIAbstractWizard::showNextPage(); 214 } 215 else 216 QIAbstractWizard::showNextPage(); 217 } 218 219 void VBoxImportApplianceWzd::onPageShow() 220 { 221 /* Make sure all is properly translated & composed */ 222 retranslateUi(); 223 224 QWidget *page = mPageStack->currentWidget(); 225 226 if (page == mSettingsPage) 227 finishButton()->setDefault (true); 228 else 229 nextButton (page)->setDefault (true); 230 } 231 236 return m_pSettingsCnt->import(); 237 } -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/importappliance/UIImportApplianceWzd.h
r25432 r26079 2 2 * 3 3 * VBox frontends: Qt4 GUI ("VirtualBox"): 4 * VBoxImportApplianceWzd class declaration4 * UIImportApplianceWzd class declaration 5 5 */ 6 6 7 7 /* 8 * Copyright (C) 2009 Sun Microsystems, Inc.8 * Copyright (C) 2009-2010 Sun Microsystems, Inc. 9 9 * 10 10 * This file is part of VirtualBox Open Source Edition (OSE), as … … 21 21 */ 22 22 23 #ifndef __ VBoxImportApplianceWzd_h__24 #define __ VBoxImportApplianceWzd_h__23 #ifndef __UIImportApplianceWzd_h__ 24 #define __UIImportApplianceWzd_h__ 25 25 26 #include "VBoxImportApplianceWzd.gen.h" 27 #include "QIAbstractWizard.h" 28 #include "QIWithRetranslateUI.h" 26 /* Global includes */ 27 #include <QPointer> 28 29 /* Local includes */ 29 30 #include "QIDialog.h" 31 #include "QIWizard.h" 30 32 31 class QIWidgetValidator; 33 /* Generated includes */ 34 #include "UIImportApplianceWzdPage1.gen.h" 35 #include "UIImportApplianceWzdPage2.gen.h" 32 36 37 /* Global forwards */ 33 38 class QDialogButtonBox; 34 39 35 class VBoxImportLicenseViewer: public QIDialog 40 typedef QPointer<VBoxImportApplianceWgt> ImportAppliancePointer; 41 Q_DECLARE_METATYPE(ImportAppliancePointer); 42 43 class UIImportLicenseViewer : public QIDialog 36 44 { 37 45 Q_OBJECT; 38 46 39 47 public: 40 VBoxImportLicenseViewer (QWidget *aParent = NULL);41 48 42 void setContent (const QString &aName, const QString &aText); 49 UIImportLicenseViewer(QWidget *pParent); 50 51 void setContents(const QString &strName, const QString &strText); 43 52 44 53 protected: 54 45 55 void retranslateUi(); 46 56 47 57 private slots: 48 void print(); 49 void save(); 58 59 void sltPrint(); 60 void sltSave(); 50 61 51 62 private: 52 QLabel *mCaption; 53 QTextEdit *mLicenseText; 54 QDialogButtonBox *mButtonBox; 55 QPushButton *mPrintBtn; 56 QPushButton *mSaveBtn; 57 QString mName; 58 QString mText; 63 64 QLabel *m_pCaption; 65 QTextEdit *m_pLicenseText; 66 QDialogButtonBox *m_pButtonBox; 67 QPushButton *m_pPrintButton; 68 QPushButton *m_pSaveButton; 69 QString m_strName; 70 QString m_strText; 59 71 }; 60 72 61 class VBoxImportApplianceWzd : public QIWithRetranslateUI<QIAbstractWizard>, 62 public Ui::VBoxImportApplianceWzd 73 class UIImportApplianceWzd : public QIWizard 63 74 { 64 75 Q_OBJECT; 65 76 66 77 public: 67 VBoxImportApplianceWzd (QWidget* aParent = NULL); 78 79 UIImportApplianceWzd(QWidget *pParent); 68 80 69 81 protected: 82 70 83 void retranslateUi(); 71 84 72 85 private slots: 73 void revalidate (QIWidgetValidator *aWval);74 void enableNext (const QIWidgetValidator *aWval);75 86 76 void accept(); 87 void sltCurrentIdChanged(int iId); 88 }; 77 89 78 void showNextPage(); 79 void onPageShow(); 90 class UIImportApplianceWzdPage1 : public QIWizardPage, public Ui::UIImportApplianceWzdPage1 91 { 92 Q_OBJECT; 93 94 public: 95 96 UIImportApplianceWzdPage1(); 97 98 protected: 99 100 void retranslateUi(); 101 102 bool isComplete() const; 103 bool validatePage(); 104 }; 105 106 class UIImportApplianceWzdPage2 : public QIWizardPage, public Ui::UIImportApplianceWzdPage2 107 { 108 Q_OBJECT; 109 Q_PROPERTY(ImportAppliancePointer applianceWidget READ applianceWidget WRITE setApplianceWidget); 110 111 public: 112 113 UIImportApplianceWzdPage2(); 114 115 protected: 116 117 void retranslateUi(); 118 119 bool validatePage(); 80 120 81 121 private: 82 /* Private member vars */ 83 QIWidgetValidator *mWValFileSelector; 122 123 ImportAppliancePointer applianceWidget() const { return m_pApplianceWidget; } 124 void setApplianceWidget(const ImportAppliancePointer &pApplianceWidget) { m_pApplianceWidget = pApplianceWidget; } 125 ImportAppliancePointer m_pApplianceWidget; 84 126 }; 85 127 86 #endif /* __VBoxImportApplianceWzd_h__ */ 87 128 #endif /* __UIImportApplianceWzd_h__ */ -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/importappliance/UIImportApplianceWzdPage1.ui
r25432 r26079 2 2 <ui version="4.0"> 3 3 <comment> 4 VBox frontends: Qt4 GUI ( "VirtualBox"):4 VBox frontends: Qt4 GUI ("VirtualBox"): 5 5 6 Copyright (C) 2009 Sun Microsystems, Inc.6 Copyright (C) 2009-2010 Sun Microsystems, Inc. 7 7 8 8 This file is part of VirtualBox Open Source Edition (OSE), as … … 18 18 additional information or have any questions. 19 19 </comment> 20 <class> VBoxImportApplianceWzd</class>21 <widget class="Q Dialog" name="VBoxImportApplianceWzd">20 <class>UIImportApplianceWzdPage1</class> 21 <widget class="QWidget" name="UIImportApplianceWzdPage1"> 22 22 <property name="geometry"> 23 23 <rect> 24 24 <x>0</x> 25 25 <y>0</y> 26 <width> 547</width>27 <height>4 30</height>26 <width>600</width> 27 <height>400</height> 28 28 </rect> 29 29 </property> 30 <property name="windowTitle"> 31 <string>Appliance Import Wizard</string> 30 <property name="sizePolicy"> 31 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 32 <horstretch>0</horstretch> 33 <verstretch>0</verstretch> 34 </sizepolicy> 32 35 </property> 33 <layout class="QVBoxLayout" name=" verticalLayout">34 <property name=" margin">36 <layout class="QVBoxLayout" name="m_pLayout1"> 37 <property name="bottomMargin"> 35 38 <number>0</number> 36 39 </property> 37 40 <item> 38 <widget class="Q StackedWidget" name="mPageStack">39 <property name=" currentIndex">40 < number>0</number>41 <widget class="QILabel" name="m_pPage1Text1"> 42 <property name="text"> 43 <string><p>This wizard will guide you through importing an appliance.</p><p>Use the <b>Next</b> button to go the next page of the wizard and the <b>Back</b> button to return to the previous page.</p><p>VirtualBox currently supports importing appliances saved in the Open Virtualization Format (OVF). To continue, select the file to import below:</p></string> 41 44 </property> 42 <widget class="QWidget" name="mFileSelectPage"> 43 <layout class="QVBoxLayout" name="verticalLayout_2"> 44 <item> 45 <widget class="QLabel" name="mPageWelcomeHdr"> 46 <property name="font"> 47 <font> 48 <family>Arial</family> 49 <pointsize>12</pointsize> 50 <weight>75</weight> 51 <bold>true</bold> 52 </font> 53 </property> 54 <property name="text"> 55 <string>Welcome to the Appliance Import Wizard!</string> 56 </property> 57 </widget> 58 </item> 59 <item> 60 <widget class="Line" name="line11"> 61 <property name="orientation"> 62 <enum>Qt::Horizontal</enum> 63 </property> 64 </widget> 65 </item> 66 <item> 67 <layout class="QGridLayout" name="gridLayout"> 68 <item row="0" column="0" rowspan="3"> 69 <widget class="QLabel" name="mLogoWelcome"> 70 <property name="sizePolicy"> 71 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 72 <horstretch>0</horstretch> 73 <verstretch>0</verstretch> 74 </sizepolicy> 75 </property> 76 <property name="autoFillBackground"> 77 <bool>true</bool> 78 </property> 79 <property name="text"> 80 <string/> 81 </property> 82 <property name="pixmap"> 83 <pixmap resource="../VirtualBox1.qrc">:/vmw_ovf_import.png</pixmap> 84 </property> 85 <property name="alignment"> 86 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 87 </property> 88 </widget> 89 </item> 90 <item row="0" column="1"> 91 <widget class="QILabel" name="mTextWelcome"> 92 <property name="sizePolicy"> 93 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 94 <horstretch>0</horstretch> 95 <verstretch>0</verstretch> 96 </sizepolicy> 97 </property> 98 <property name="minimumSize"> 99 <size> 100 <width>300</width> 101 <height>0</height> 102 </size> 103 </property> 104 <property name="text"> 105 <string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> 106 <html><head><meta name="qrichtext" content="1" /><style type="text/css"> 107 p, li { white-space: pre-wrap; } 108 </style></head><body> 109 <p style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">This wizard will guide you through importing an appliance. </p> 110 <p style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Use the <span style=" font-weight:600;">Next</span> button to go the next page of the wizard and the <span style=" font-weight:600;">Back</span> button to return to the previous page.</p> 111 <p style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">VirtualBox currently supports importing appliances saved in the Open Virtualization Format (OVF). To continue, select the file to import below:</p></body></html></string> 112 </property> 113 <property name="wordWrap"> 114 <bool>true</bool> 115 </property> 116 </widget> 117 </item> 118 <item row="1" column="1"> 119 <widget class="VBoxEmptyFileSelector" name="mFileSelector" native="true"/> 120 </item> 121 <item row="2" column="1"> 122 <spacer name="spacer"> 123 <property name="orientation"> 124 <enum>Qt::Vertical</enum> 125 </property> 126 <property name="sizeHint" stdset="0"> 127 <size> 128 <width>406</width> 129 <height>68</height> 130 </size> 131 </property> 132 </spacer> 133 </item> 134 </layout> 135 </item> 136 <item> 137 <widget class="Line" name="line12"> 138 <property name="orientation"> 139 <enum>Qt::Horizontal</enum> 140 </property> 141 </widget> 142 </item> 143 <item> 144 <layout class="QHBoxLayout"> 145 <item> 146 <spacer> 147 <property name="orientation"> 148 <enum>Qt::Horizontal</enum> 149 </property> 150 <property name="sizeHint" stdset="0"> 151 <size> 152 <width>0</width> 153 <height>0</height> 154 </size> 155 </property> 156 </spacer> 157 </item> 158 <item> 159 <widget class="QPushButton" name="mBtnBack1"> 160 <property name="enabled"> 161 <bool>false</bool> 162 </property> 163 <property name="text"> 164 <string>< &Back</string> 165 </property> 166 </widget> 167 </item> 168 <item> 169 <widget class="QPushButton" name="mBtnNext1"> 170 <property name="text"> 171 <string>&Next ></string> 172 </property> 173 </widget> 174 </item> 175 <item> 176 <spacer> 177 <property name="orientation"> 178 <enum>Qt::Horizontal</enum> 179 </property> 180 <property name="sizeType"> 181 <enum>QSizePolicy::Fixed</enum> 182 </property> 183 <property name="sizeHint" stdset="0"> 184 <size> 185 <width>5</width> 186 <height>0</height> 187 </size> 188 </property> 189 </spacer> 190 </item> 191 <item> 192 <widget class="QPushButton" name="mBtnCancel1"> 193 <property name="text"> 194 <string>Cancel</string> 195 </property> 196 </widget> 197 </item> 198 </layout> 199 </item> 200 </layout> 201 </widget> 202 <widget class="QWidget" name="mSettingsPage"> 203 <layout class="QVBoxLayout" name="verticalLayout_3"> 204 <item> 205 <widget class="QLabel" name="mPageSettingsHdr"> 206 <property name="font"> 207 <font> 208 <family>Arial</family> 209 <pointsize>12</pointsize> 210 <weight>75</weight> 211 <bold>true</bold> 212 </font> 213 </property> 214 <property name="text"> 215 <string>Appliance Import Settings</string> 216 </property> 217 </widget> 218 </item> 219 <item> 220 <widget class="Line" name="line21"> 221 <property name="orientation"> 222 <enum>Qt::Horizontal</enum> 223 </property> 224 </widget> 225 </item> 226 <item> 227 <layout class="QGridLayout" name="gridLayout_2"> 228 <item row="0" column="0" rowspan="2"> 229 <widget class="QLabel" name="mLogoSettings"> 230 <property name="sizePolicy"> 231 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 232 <horstretch>0</horstretch> 233 <verstretch>0</verstretch> 234 </sizepolicy> 235 </property> 236 <property name="autoFillBackground"> 237 <bool>true</bool> 238 </property> 239 <property name="text"> 240 <string/> 241 </property> 242 <property name="pixmap"> 243 <pixmap resource="../VirtualBox1.qrc">:/vmw_ovf_import.png</pixmap> 244 </property> 245 <property name="alignment"> 246 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 247 </property> 248 </widget> 249 </item> 250 <item row="0" column="1"> 251 <widget class="QILabel" name="mTextSettings"> 252 <property name="sizePolicy"> 253 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 254 <horstretch>0</horstretch> 255 <verstretch>0</verstretch> 256 </sizepolicy> 257 </property> 258 <property name="minimumSize"> 259 <size> 260 <width>300</width> 261 <height>0</height> 262 </size> 263 </property> 264 <property name="text"> 265 <string>These are the virtual machines contained in the appliance and the suggested settings of the imported VirtualBox machines. You can change many of the properties shown by double-clicking on the items and disable others using the check boxes below.</string> 266 </property> 267 <property name="wordWrap"> 268 <bool>true</bool> 269 </property> 270 </widget> 271 </item> 272 <item row="1" column="1"> 273 <widget class="VBoxImportApplianceWgt" name="mImportSettingsWgt" native="true"> 274 <property name="enabled"> 275 <bool>true</bool> 276 </property> 277 <property name="sizePolicy"> 278 <sizepolicy hsizetype="Preferred" vsizetype="MinimumExpanding"> 279 <horstretch>0</horstretch> 280 <verstretch>0</verstretch> 281 </sizepolicy> 282 </property> 283 <property name="minimumSize"> 284 <size> 285 <width>0</width> 286 <height>0</height> 287 </size> 288 </property> 289 <property name="baseSize"> 290 <size> 291 <width>0</width> 292 <height>0</height> 293 </size> 294 </property> 295 </widget> 296 </item> 297 </layout> 298 </item> 299 <item> 300 <widget class="Line" name="line22"> 301 <property name="orientation"> 302 <enum>Qt::Horizontal</enum> 303 </property> 304 </widget> 305 </item> 306 <item> 307 <layout class="QHBoxLayout" name="_3"> 308 <item> 309 <widget class="QPushButton" name="mBtnRestore"> 310 <property name="text"> 311 <string>Restore Defaults</string> 312 </property> 313 </widget> 314 </item> 315 <item> 316 <spacer> 317 <property name="orientation"> 318 <enum>Qt::Horizontal</enum> 319 </property> 320 <property name="sizeHint" stdset="0"> 321 <size> 322 <width>0</width> 323 <height>0</height> 324 </size> 325 </property> 326 </spacer> 327 </item> 328 <item> 329 <widget class="QPushButton" name="mBtnBack2"> 330 <property name="text"> 331 <string>< &Back</string> 332 </property> 333 </widget> 334 </item> 335 <item> 336 <widget class="QPushButton" name="mBtnFinish"> 337 <property name="text"> 338 <string>&Import ></string> 339 </property> 340 </widget> 341 </item> 342 <item> 343 <spacer> 344 <property name="orientation"> 345 <enum>Qt::Horizontal</enum> 346 </property> 347 <property name="sizeType"> 348 <enum>QSizePolicy::Fixed</enum> 349 </property> 350 <property name="sizeHint" stdset="0"> 351 <size> 352 <width>5</width> 353 <height>0</height> 354 </size> 355 </property> 356 </spacer> 357 </item> 358 <item> 359 <widget class="QPushButton" name="mBtnCancel2"> 360 <property name="text"> 361 <string>Cancel</string> 362 </property> 363 </widget> 364 </item> 365 </layout> 366 </item> 367 </layout> 368 </widget> 45 <property name="wordWrap"> 46 <bool>true</bool> 47 </property> 369 48 </widget> 49 </item> 50 <item> 51 <widget class="VBoxEmptyFileSelector" name="m_pFileSelector" native="true"/> 52 </item> 53 <item> 54 <spacer name="m_pSpacer1"> 55 <property name="sizeHint" stdset="0"> 56 <size> 57 <width>0</width> 58 <height>252</height> 59 </size> 60 </property> 61 </spacer> 370 62 </item> 371 63 </layout> … … 378 70 </customwidget> 379 71 <customwidget> 380 <class>VBoxImportApplianceWgt</class>381 <extends>QWidget</extends>382 <header>VBoxImportApplianceWgt.h</header>383 <container>1</container>384 </customwidget>385 <customwidget>386 72 <class>VBoxEmptyFileSelector</class> 387 73 <extends>QWidget</extends> … … 390 76 </customwidget> 391 77 </customwidgets> 392 <resources> 393 <include location="../VirtualBox1.qrc"/> 394 </resources> 78 <resources/> 395 79 <connections/> 396 80 </ui> -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/importappliance/UIImportApplianceWzdPage2.ui
r25432 r26079 2 2 <ui version="4.0"> 3 3 <comment> 4 VBox frontends: Qt4 GUI ( "VirtualBox"):4 VBox frontends: Qt4 GUI ("VirtualBox"): 5 5 6 Copyright (C) 2009 Sun Microsystems, Inc.6 Copyright (C) 2009-2010 Sun Microsystems, Inc. 7 7 8 8 This file is part of VirtualBox Open Source Edition (OSE), as … … 18 18 additional information or have any questions. 19 19 </comment> 20 <class> VBoxImportApplianceWzd</class>21 <widget class="Q Dialog" name="VBoxImportApplianceWzd">20 <class>UIImportApplianceWzdPage2</class> 21 <widget class="QWidget" name="UIImportApplianceWzdPage2"> 22 22 <property name="geometry"> 23 23 <rect> 24 24 <x>0</x> 25 25 <y>0</y> 26 <width> 547</width>27 <height>4 30</height>26 <width>600</width> 27 <height>400</height> 28 28 </rect> 29 29 </property> 30 <property name="windowTitle"> 31 <string>Appliance Import Wizard</string> 30 <property name="sizePolicy"> 31 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 32 <horstretch>0</horstretch> 33 <verstretch>0</verstretch> 34 </sizepolicy> 32 35 </property> 33 <layout class="QVBoxLayout" name=" verticalLayout">34 <property name=" margin">36 <layout class="QVBoxLayout" name="m_pLayout1"> 37 <property name="bottomMargin"> 35 38 <number>0</number> 36 39 </property> 37 40 <item> 38 <widget class="Q StackedWidget" name="mPageStack">39 <property name=" currentIndex">40 < number>0</number>41 <widget class="QILabel" name="m_pPage2Text1"> 42 <property name="text"> 43 <string>These are the virtual machines contained in the appliance and the suggested settings of the imported VirtualBox machines. You can change many of the properties shown by double-clicking on the items and disable others using the check boxes below.</string> 41 44 </property> 42 <widget class="QWidget" name="mFileSelectPage"> 43 <layout class="QVBoxLayout" name="verticalLayout_2"> 44 <item> 45 <widget class="QLabel" name="mPageWelcomeHdr"> 46 <property name="font"> 47 <font> 48 <family>Arial</family> 49 <pointsize>12</pointsize> 50 <weight>75</weight> 51 <bold>true</bold> 52 </font> 53 </property> 54 <property name="text"> 55 <string>Welcome to the Appliance Import Wizard!</string> 56 </property> 57 </widget> 58 </item> 59 <item> 60 <widget class="Line" name="line11"> 61 <property name="orientation"> 62 <enum>Qt::Horizontal</enum> 63 </property> 64 </widget> 65 </item> 66 <item> 67 <layout class="QGridLayout" name="gridLayout"> 68 <item row="0" column="0" rowspan="3"> 69 <widget class="QLabel" name="mLogoWelcome"> 70 <property name="sizePolicy"> 71 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 72 <horstretch>0</horstretch> 73 <verstretch>0</verstretch> 74 </sizepolicy> 75 </property> 76 <property name="autoFillBackground"> 77 <bool>true</bool> 78 </property> 79 <property name="text"> 80 <string/> 81 </property> 82 <property name="pixmap"> 83 <pixmap resource="../VirtualBox1.qrc">:/vmw_ovf_import.png</pixmap> 84 </property> 85 <property name="alignment"> 86 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 87 </property> 88 </widget> 89 </item> 90 <item row="0" column="1"> 91 <widget class="QILabel" name="mTextWelcome"> 92 <property name="sizePolicy"> 93 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 94 <horstretch>0</horstretch> 95 <verstretch>0</verstretch> 96 </sizepolicy> 97 </property> 98 <property name="minimumSize"> 99 <size> 100 <width>300</width> 101 <height>0</height> 102 </size> 103 </property> 104 <property name="text"> 105 <string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> 106 <html><head><meta name="qrichtext" content="1" /><style type="text/css"> 107 p, li { white-space: pre-wrap; } 108 </style></head><body> 109 <p style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">This wizard will guide you through importing an appliance. </p> 110 <p style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Use the <span style=" font-weight:600;">Next</span> button to go the next page of the wizard and the <span style=" font-weight:600;">Back</span> button to return to the previous page.</p> 111 <p style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">VirtualBox currently supports importing appliances saved in the Open Virtualization Format (OVF). To continue, select the file to import below:</p></body></html></string> 112 </property> 113 <property name="wordWrap"> 114 <bool>true</bool> 115 </property> 116 </widget> 117 </item> 118 <item row="1" column="1"> 119 <widget class="VBoxEmptyFileSelector" name="mFileSelector" native="true"/> 120 </item> 121 <item row="2" column="1"> 122 <spacer name="spacer"> 123 <property name="orientation"> 124 <enum>Qt::Vertical</enum> 125 </property> 126 <property name="sizeHint" stdset="0"> 127 <size> 128 <width>406</width> 129 <height>68</height> 130 </size> 131 </property> 132 </spacer> 133 </item> 134 </layout> 135 </item> 136 <item> 137 <widget class="Line" name="line12"> 138 <property name="orientation"> 139 <enum>Qt::Horizontal</enum> 140 </property> 141 </widget> 142 </item> 143 <item> 144 <layout class="QHBoxLayout"> 145 <item> 146 <spacer> 147 <property name="orientation"> 148 <enum>Qt::Horizontal</enum> 149 </property> 150 <property name="sizeHint" stdset="0"> 151 <size> 152 <width>0</width> 153 <height>0</height> 154 </size> 155 </property> 156 </spacer> 157 </item> 158 <item> 159 <widget class="QPushButton" name="mBtnBack1"> 160 <property name="enabled"> 161 <bool>false</bool> 162 </property> 163 <property name="text"> 164 <string>< &Back</string> 165 </property> 166 </widget> 167 </item> 168 <item> 169 <widget class="QPushButton" name="mBtnNext1"> 170 <property name="text"> 171 <string>&Next ></string> 172 </property> 173 </widget> 174 </item> 175 <item> 176 <spacer> 177 <property name="orientation"> 178 <enum>Qt::Horizontal</enum> 179 </property> 180 <property name="sizeType"> 181 <enum>QSizePolicy::Fixed</enum> 182 </property> 183 <property name="sizeHint" stdset="0"> 184 <size> 185 <width>5</width> 186 <height>0</height> 187 </size> 188 </property> 189 </spacer> 190 </item> 191 <item> 192 <widget class="QPushButton" name="mBtnCancel1"> 193 <property name="text"> 194 <string>Cancel</string> 195 </property> 196 </widget> 197 </item> 198 </layout> 199 </item> 200 </layout> 201 </widget> 202 <widget class="QWidget" name="mSettingsPage"> 203 <layout class="QVBoxLayout" name="verticalLayout_3"> 204 <item> 205 <widget class="QLabel" name="mPageSettingsHdr"> 206 <property name="font"> 207 <font> 208 <family>Arial</family> 209 <pointsize>12</pointsize> 210 <weight>75</weight> 211 <bold>true</bold> 212 </font> 213 </property> 214 <property name="text"> 215 <string>Appliance Import Settings</string> 216 </property> 217 </widget> 218 </item> 219 <item> 220 <widget class="Line" name="line21"> 221 <property name="orientation"> 222 <enum>Qt::Horizontal</enum> 223 </property> 224 </widget> 225 </item> 226 <item> 227 <layout class="QGridLayout" name="gridLayout_2"> 228 <item row="0" column="0" rowspan="2"> 229 <widget class="QLabel" name="mLogoSettings"> 230 <property name="sizePolicy"> 231 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 232 <horstretch>0</horstretch> 233 <verstretch>0</verstretch> 234 </sizepolicy> 235 </property> 236 <property name="autoFillBackground"> 237 <bool>true</bool> 238 </property> 239 <property name="text"> 240 <string/> 241 </property> 242 <property name="pixmap"> 243 <pixmap resource="../VirtualBox1.qrc">:/vmw_ovf_import.png</pixmap> 244 </property> 245 <property name="alignment"> 246 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 247 </property> 248 </widget> 249 </item> 250 <item row="0" column="1"> 251 <widget class="QILabel" name="mTextSettings"> 252 <property name="sizePolicy"> 253 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 254 <horstretch>0</horstretch> 255 <verstretch>0</verstretch> 256 </sizepolicy> 257 </property> 258 <property name="minimumSize"> 259 <size> 260 <width>300</width> 261 <height>0</height> 262 </size> 263 </property> 264 <property name="text"> 265 <string>These are the virtual machines contained in the appliance and the suggested settings of the imported VirtualBox machines. You can change many of the properties shown by double-clicking on the items and disable others using the check boxes below.</string> 266 </property> 267 <property name="wordWrap"> 268 <bool>true</bool> 269 </property> 270 </widget> 271 </item> 272 <item row="1" column="1"> 273 <widget class="VBoxImportApplianceWgt" name="mImportSettingsWgt" native="true"> 274 <property name="enabled"> 275 <bool>true</bool> 276 </property> 277 <property name="sizePolicy"> 278 <sizepolicy hsizetype="Preferred" vsizetype="MinimumExpanding"> 279 <horstretch>0</horstretch> 280 <verstretch>0</verstretch> 281 </sizepolicy> 282 </property> 283 <property name="minimumSize"> 284 <size> 285 <width>0</width> 286 <height>0</height> 287 </size> 288 </property> 289 <property name="baseSize"> 290 <size> 291 <width>0</width> 292 <height>0</height> 293 </size> 294 </property> 295 </widget> 296 </item> 297 </layout> 298 </item> 299 <item> 300 <widget class="Line" name="line22"> 301 <property name="orientation"> 302 <enum>Qt::Horizontal</enum> 303 </property> 304 </widget> 305 </item> 306 <item> 307 <layout class="QHBoxLayout" name="_3"> 308 <item> 309 <widget class="QPushButton" name="mBtnRestore"> 310 <property name="text"> 311 <string>Restore Defaults</string> 312 </property> 313 </widget> 314 </item> 315 <item> 316 <spacer> 317 <property name="orientation"> 318 <enum>Qt::Horizontal</enum> 319 </property> 320 <property name="sizeHint" stdset="0"> 321 <size> 322 <width>0</width> 323 <height>0</height> 324 </size> 325 </property> 326 </spacer> 327 </item> 328 <item> 329 <widget class="QPushButton" name="mBtnBack2"> 330 <property name="text"> 331 <string>< &Back</string> 332 </property> 333 </widget> 334 </item> 335 <item> 336 <widget class="QPushButton" name="mBtnFinish"> 337 <property name="text"> 338 <string>&Import ></string> 339 </property> 340 </widget> 341 </item> 342 <item> 343 <spacer> 344 <property name="orientation"> 345 <enum>Qt::Horizontal</enum> 346 </property> 347 <property name="sizeType"> 348 <enum>QSizePolicy::Fixed</enum> 349 </property> 350 <property name="sizeHint" stdset="0"> 351 <size> 352 <width>5</width> 353 <height>0</height> 354 </size> 355 </property> 356 </spacer> 357 </item> 358 <item> 359 <widget class="QPushButton" name="mBtnCancel2"> 360 <property name="text"> 361 <string>Cancel</string> 362 </property> 363 </widget> 364 </item> 365 </layout> 366 </item> 367 </layout> 368 </widget> 45 <property name="wordWrap"> 46 <bool>true</bool> 47 </property> 48 </widget> 49 </item> 50 <item> 51 <widget class="VBoxImportApplianceWgt" name="m_pSettingsCnt" native="true"> 52 <property name="sizePolicy"> 53 <sizepolicy hsizetype="Preferred" vsizetype="MinimumExpanding"> 54 <horstretch>0</horstretch> 55 <verstretch>0</verstretch> 56 </sizepolicy> 57 </property> 369 58 </widget> 370 59 </item> … … 383 72 <container>1</container> 384 73 </customwidget> 385 <customwidget>386 <class>VBoxEmptyFileSelector</class>387 <extends>QWidget</extends>388 <header>VBoxFilePathSelectorWidget.h</header>389 <container>1</container>390 </customwidget>391 74 </customwidgets> 392 <resources> 393 <include location="../VirtualBox1.qrc"/> 394 </resources> 75 <resources/> 395 76 <connections/> 396 77 </ui> -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/newhd/UINewHDWzd.cpp
r25356 r26079 2 2 * 3 3 * VBox frontends: Qt4 GUI ("VirtualBox"): 4 * VBoxNewHDWzd class implementation4 * UINewHDWzd class implementation 5 5 */ 6 6 7 7 /* 8 * Copyright (C) 2006-20 08Sun Microsystems, Inc.8 * Copyright (C) 2006-2010 Sun Microsystems, Inc. 9 9 * 10 10 * This file is part of VirtualBox Open Source Edition (OSE), as … … 21 21 */ 22 22 23 #include "VBoxNewHDWzd.h" 23 /* Global includes */ 24 #include <QFileDialog> 25 #include <QRegExpValidator> 26 27 /* Local includes */ 28 #include "UINewHDWzd.h" 24 29 #include "VBoxGlobal.h" 25 30 #include "VBoxProblemReporter.h" 26 31 #include "iprt/path.h" 27 32 28 /* Qt includes */ 29 #include <QFileDialog> 30 #include <QToolTip> 31 32 /** Minimum VDI size in MB */ 33 static const quint64 MinVDISize = 4; 34 35 /** Initial VDI size in MB */ 36 static const quint64 InitialVDISize = 2 * _1K; 37 38 /** 39 * Composes a file name from the given relative or full file name based on the 40 * home directory and the default VDI directory. See IMedum::location for 41 * details. 42 */ 43 static QString composeFullFileName (const QString &aName) 33 UINewHDWzd::UINewHDWzd(QWidget *pParent) : QIWizard(pParent) 34 { 35 /* Create & add pages */ 36 addPage(new UINewHDWzdPage1); 37 addPage(new UINewHDWzdPage2); 38 addPage(new UINewHDWzdPage3); 39 addPage(new UINewHDWzdPage4); 40 41 /* Translate */ 42 retranslateUi(); 43 44 /* Resize to 'golden ratio' */ 45 resizeToGoldenRatio(); 46 47 /* Assign watermark */ 48 assignWatermark(":/vmw_new_harddisk.png"); 49 } 50 51 CMedium UINewHDWzd::hardDisk() const 52 { 53 /* Get 'hardDisk' field value from page 4 */ 54 return field("hardDisk").value<CMedium>(); 55 } 56 57 void UINewHDWzd::setRecommendedName(const QString &strName) 58 { 59 /* Set 'initialName' field value for page 3 */ 60 setField("initialName", strName); 61 } 62 63 void UINewHDWzd::setRecommendedSize(qulonglong uSize) 64 { 65 /* Set 'initialSize' field value for page 3 */ 66 setField("initialSize", uSize); 67 } 68 69 QString UINewHDWzd::composeFullFileName(const QString &strFileName) 44 70 { 45 71 CVirtualBox vbox = vboxGlobal().virtualBox(); 46 QString homeFolder = vbox.GetHomeFolder(); 47 QString defaultFolder = vbox.GetSystemProperties().GetDefaultHardDiskFolder(); 48 49 /* Note: the logic below must match the logic of the IMedum::location 50 * setter, otherwise the returned path may differ from the path actually 51 * set for the hard disk by the VirtualBox API */ 52 53 QFileInfo fi (aName); 54 if (fi.fileName() == aName) 55 { 56 /* no path info at all, use defaultFolder */ 57 fi = QFileInfo (defaultFolder, aName); 72 QString strHomeFolder = vbox.GetHomeFolder(); 73 QString strDefaultFolder = vbox.GetSystemProperties().GetDefaultHardDiskFolder(); 74 75 QFileInfo fi(strFileName); 76 if (fi.fileName() == strFileName) 77 { 78 /* No path info at all, use strDefaultFolder */ 79 fi = QFileInfo(strDefaultFolder, strFileName); 58 80 } 59 81 else if (fi.isRelative()) 60 82 { 61 /* resolve relatively to homeFolder */ 62 fi = QFileInfo (homeFolder, aName); 63 } 64 65 return QDir::toNativeSeparators (fi.absoluteFilePath()); 66 } 67 68 static inline int log2i (quint64 val) 69 { 70 quint64 n = val; 71 int pow = -1; 72 while (n) 73 { 74 ++ pow; 75 n >>= 1; 76 } 77 return pow; 78 } 79 80 static inline int sizeMBToSlider (quint64 val, int aSliderScale) 81 { 82 int pow = log2i (val); 83 quint64 tickMB = quint64 (1) << pow; 84 quint64 tickMBNext = quint64 (1) << (pow + 1); 85 int step = (val - tickMB) * aSliderScale / (tickMBNext - tickMB); 86 return pow * aSliderScale + step; 87 } 88 89 static inline quint64 sliderToSizeMB (int val, int aSliderScale) 90 { 91 int pow = val / aSliderScale; 92 int step = val % aSliderScale; 93 quint64 tickMB = quint64 (1) << pow; 94 quint64 tickMBNext = quint64 (1) << (pow + 1); 95 return tickMB + (tickMBNext - tickMB) * step / aSliderScale; 96 } 97 98 99 //////////////////////////////////////////////////////////////////////////////// 100 101 102 VBoxNewHDWzd::VBoxNewHDWzd (QWidget *aParent) 103 : QIWithRetranslateUI<QIAbstractWizard> (aParent) 104 { 105 /* Apply UI decorations */ 106 Ui::VBoxNewHDWzd::setupUi (this); 107 108 /* Initialize wizard hdr */ 109 initializeWizardHdr(); 110 111 /* Storage type page */ 112 113 /* Name and Size page */ 114 CSystemProperties sysProps = vboxGlobal().virtualBox().GetSystemProperties(); 115 mMaxVDISize = sysProps.GetMaxVDISize(); 83 /* Resolve relatively to strHomeFolder */ 84 fi = QFileInfo(strHomeFolder, strFileName); 85 } 86 87 return QDir::toNativeSeparators(fi.absoluteFilePath()); 88 } 89 90 void UINewHDWzd::retranslateUi() 91 { 92 /* Wizard title */ 93 setWindowTitle(tr("Create New Virtual Disk")); 94 } 95 96 UINewHDWzdPage1::UINewHDWzdPage1() 97 { 98 /* Decorate page */ 99 Ui::UINewHDWzdPage1::setupUi(this); 100 101 /* Translate */ 102 retranslateUi(); 103 } 104 105 void UINewHDWzdPage1::retranslateUi() 106 { 107 /* Translate uic generated strings */ 108 Ui::UINewHDWzdPage1::retranslateUi(this); 109 110 /* Wizard page 1 title */ 111 setTitle(tr("Welcome to the Create New Virtual Disk Wizard!")); 112 } 113 114 UINewHDWzdPage2::UINewHDWzdPage2() 115 : m_strType(QString()) 116 , m_bFixed(false) 117 { 118 /* Decorate page */ 119 Ui::UINewHDWzdPage2::setupUi(this); 120 121 /* Register 'type', 'fixed' fields */ 122 registerField("type*", this, "type"); 123 registerField("fixed", this, "fixed"); 124 125 /* Setup connections */ 126 connect (m_pTypeDynamic, SIGNAL(clicked(bool)), this, SLOT(onTypeChanged())); 127 connect (m_pTypeFixed, SIGNAL(clicked(bool)), this, SLOT(onTypeChanged())); 128 129 /* Translate */ 130 retranslateUi(); 131 } 132 void UINewHDWzdPage2::retranslateUi() 133 { 134 /* Translate uic generated strings */ 135 Ui::UINewHDWzdPage2::retranslateUi(this); 136 137 /* Wizard page 2 title */ 138 setTitle(tr("Hard Disk Storage Type")); 139 } 140 141 void UINewHDWzdPage2::initializePage() 142 { 143 /* Translate */ 144 retranslateUi(); 145 146 /* Prepare initial choice */ 147 m_pTypeDynamic->click(); 148 149 /* 'Dynamic' choice should have focus initially */ 150 m_pTypeDynamic->setFocus(); 151 } 152 153 void UINewHDWzdPage2::onTypeChanged() 154 { 155 if (m_pTypeDynamic->isChecked()) 156 { 157 /* 'Dynamic' storage type */ 158 m_strType = VBoxGlobal::removeAccelMark(m_pTypeDynamic->text()); 159 m_bFixed = false; 160 } 161 else if (m_pTypeFixed->isChecked()) 162 { 163 /* 'Fixed' storage type */ 164 m_strType = VBoxGlobal::removeAccelMark(m_pTypeFixed->text()); 165 m_bFixed = true; 166 } 167 else 168 { 169 /* Not complete */ 170 m_strType.clear(); 171 m_bFixed = false; 172 } 173 emit completeChanged(); 174 } 175 176 UINewHDWzdPage3::UINewHDWzdPage3() 177 : m_strInitialName("NewHardDisk1.vdi") 178 , m_strCurrentName(QString()) 179 , m_strLocation(QString()) 180 , m_uInitialSize(2 * _1K) 181 , m_uCurrentSize(0) 182 , m_uMinVDISize(4) 183 , m_uMaxVDISize(vboxGlobal().virtualBox().GetSystemProperties().GetMaxVDISize()) 184 , m_iSliderScale(0) 185 { 186 /* Decorate page */ 187 Ui::UINewHDWzdPage3::setupUi(this); 188 189 /* Register 'initialName', 'currentName', 'location' & 190 * 'initialSize', 'currentSize' fields */ 191 registerField("initialName", this, "initialName"); 192 registerField("currentName", this, "currentName"); 193 registerField("location", this, "location"); 194 registerField("initialSize", this, "initialSize"); 195 registerField("currentSize", this, "currentSize"); 196 116 197 /* Detect how many steps to recognize between adjacent powers of 2 117 * to ensure that the last slider step is exactly mMaxVDISize */ 118 mSliderScale = 0; 119 { 120 int pow = log2i (mMaxVDISize); 121 quint64 tickMB = quint64 (1) << pow; 122 if (tickMB < mMaxVDISize) 123 { 124 quint64 tickMBNext = quint64 (1) << (pow + 1); 125 quint64 gap = tickMBNext - mMaxVDISize; 126 mSliderScale = (int) ((tickMBNext - tickMB) / gap); 127 } 128 } 129 mSliderScale = qMax (mSliderScale, 8); 130 mLeName->setValidator (new QRegExpValidator (QRegExp (".+"), this)); 131 mLeSize->setValidator (new QRegExpValidator (QRegExp (vboxGlobal().sizeRegexp()), this)); 132 mLeSize->setAlignment (Qt::AlignRight); 133 mWValNameAndSize = new QIWidgetValidator (mPageNameAndSize, this); 134 connect (mWValNameAndSize, SIGNAL (validityChanged (const QIWidgetValidator *)), 135 this, SLOT (enableNext (const QIWidgetValidator *))); 136 connect (mWValNameAndSize, SIGNAL (isValidRequested (QIWidgetValidator *)), 137 this, SLOT (revalidate (QIWidgetValidator *))); 138 connect (mLeSize, SIGNAL (textChanged (const QString &)), 139 mWValNameAndSize, SLOT (revalidate())); 140 connect (mTbNameSelect, SIGNAL (clicked()), this, SLOT (tbNameSelectClicked())); 141 connect (mSlSize, SIGNAL (valueChanged (int)), this, SLOT (slSizeValueChanged (int))); 142 connect (mLeSize, SIGNAL (textChanged (const QString&)), 143 this, SLOT (leSizeTextChanged (const QString&))); 144 145 /* Summary page */ 146 147 /* Image type page */ 148 149 /* Name and Size page */ 150 /// @todo NEWMEDIA use extension as reported by CMediumFormat 151 static ulong HDNumber = 0; 152 mLeName->setText (QString ("NewHardDisk%1.vdi").arg (++ HDNumber)); 153 mSlSize->setFocusPolicy (Qt::StrongFocus); 154 mSlSize->setPageStep (mSliderScale); 155 mSlSize->setSingleStep (mSliderScale / 8); 156 mSlSize->setTickInterval (0); 157 mSlSize->setMinimum (sizeMBToSlider (MinVDISize, mSliderScale)); 158 mSlSize->setMaximum (sizeMBToSlider (mMaxVDISize, mSliderScale)); 159 mTxSizeMin->setText (vboxGlobal().formatSize (MinVDISize * _1M)); 160 mTxSizeMax->setText (vboxGlobal().formatSize (mMaxVDISize * _1M)); 161 /* limit the max. size of QILineEdit */ 162 mLeSize->setFixedWidthByText ("88888.88 MB"); 163 setRecommendedSize (InitialVDISize); 164 165 /* Summary page */ 166 /* Update the next button state for pages with validation 167 * (validityChanged() connected to enableNext() will do the job) */ 168 mWValNameAndSize->revalidate(); 169 170 /* Initialize wizard ftr */ 171 initializeWizardFtr(); 172 173 retranslateUi(); 174 } 175 176 void VBoxNewHDWzd::setRecommendedFileName (const QString &aName) 177 { 178 mLeName->setText (aName); 179 } 180 181 void VBoxNewHDWzd::setRecommendedSize (quint64 aSize) 182 { 183 AssertReturnVoid (aSize >= MinVDISize && aSize <= mMaxVDISize); 184 mCurrentSize = aSize; 185 mSlSize->setValue (sizeMBToSlider (mCurrentSize, mSliderScale)); 186 mLeSize->setText (vboxGlobal().formatSize (mCurrentSize * _1M)); 187 updateSizeToolTip (mCurrentSize * _1M); 188 } 189 190 void VBoxNewHDWzd::retranslateUi() 191 { 192 /* Translate uic generated strings */ 193 Ui::VBoxNewHDWzd::retranslateUi (this); 194 195 QWidget *page = mPageStack->currentWidget(); 196 197 if (page == mPageSummary) 198 { 199 QString type = mRbDynamicType->isChecked() ? mRbDynamicType->text() 200 : mRbFixedType->text(); 201 type = VBoxGlobal::removeAccelMark (type); 202 203 quint64 sizeB = mCurrentSize * _1M; 204 205 /* compose summary */ 206 QString summary = QString ( 207 "<table>" 208 "<tr><td><nobr>%1: </nobr></td><td><nobr>%2</nobr></td></tr>" 209 "<tr><td><nobr>%3: </nobr></td><td><nobr>%4</nobr></td></tr>" 210 "<tr><td><nobr>%5: </nobr></td><td><nobr>%6 (%7 %8)</nobr></td></tr>" 211 "</table>" 212 ) 213 .arg (tr ("Type", "summary")).arg (type) 214 .arg (tr ("Location", "summary")).arg (composeFullFileName (location())) 215 .arg (tr ("Size", "summary")).arg (VBoxGlobal::formatSize (sizeB)) 216 .arg (sizeB).arg (tr ("Bytes", "summary")); 217 218 mTeSummary->setText (summary); 219 } 220 } 221 222 void VBoxNewHDWzd::accept() 223 { 224 /* Try to create the hard disk when the Finish button is pressed. 225 * On failure, the wisard will remain open to give it another try. */ 226 if (createHardDisk()) 227 QIAbstractWizard::accept(); 228 } 229 230 void VBoxNewHDWzd::slSizeValueChanged (int aVal) 231 { 232 if (focusWidget() == mSlSize) 233 { 234 mCurrentSize = sliderToSizeMB (aVal, mSliderScale); 235 mLeSize->setText (vboxGlobal().formatSize (mCurrentSize * _1M)); 236 updateSizeToolTip (mCurrentSize * _1M); 237 } 238 } 239 240 void VBoxNewHDWzd::leSizeTextChanged (const QString &aText) 241 { 242 if (focusWidget() == mLeSize) 243 { 244 mCurrentSize = vboxGlobal().parseSize (aText); 245 updateSizeToolTip (mCurrentSize); 246 mCurrentSize /= _1M; 247 mSlSize->setValue (sizeMBToSlider (mCurrentSize, mSliderScale)); 248 } 249 } 250 251 void VBoxNewHDWzd::tbNameSelectClicked() 252 { 253 /* set the first parent directory that exists as the current */ 254 QFileInfo fld (composeFullFileName (mLeName->text())); 255 do 256 { 257 QString dp = fld.path (); 258 fld = QFileInfo (dp); 259 } 260 while (!fld.exists() && !QDir (fld.absoluteFilePath()).isRoot()); 261 262 if (!fld.exists()) 198 * to ensure that the last slider step is exactly m_uMaxVDISize */ 199 int iPower = log2i(m_uMaxVDISize); 200 qulonglong uTickMB = qulonglong (1) << iPower; 201 if (uTickMB < m_uMaxVDISize) 202 { 203 qulonglong uTickMBNext = qulonglong (1) << (iPower + 1); 204 qulonglong uGap = uTickMBNext - m_uMaxVDISize; 205 m_iSliderScale = (int)((uTickMBNext - uTickMB) / uGap); 206 } 207 m_iSliderScale = qMax(m_iSliderScale, 8); 208 209 /* Setup size-editor field */ 210 m_pSizeEditor->setFixedWidthByText("88888.88 MB"); 211 m_pSizeEditor->setAlignment(Qt::AlignRight); 212 m_pSizeEditor->setValidator(new QRegExpValidator(QRegExp(vboxGlobal().sizeRegexp()), this)); 213 214 /* Setup size-slider */ 215 m_pSizeSlider->setFocusPolicy(Qt::StrongFocus); 216 m_pSizeSlider->setPageStep(m_iSliderScale); 217 m_pSizeSlider->setSingleStep(m_iSliderScale / 8); 218 m_pSizeSlider->setTickInterval(0); 219 m_pSizeSlider->setMinimum(sizeMBToSlider(m_uMinVDISize, m_iSliderScale)); 220 m_pSizeSlider->setMaximum(sizeMBToSlider (m_uMaxVDISize, m_iSliderScale)); 221 m_pSizeMin->setText(vboxGlobal().formatSize(m_uMinVDISize * _1M)); 222 m_pSizeMax->setText(vboxGlobal().formatSize(m_uMaxVDISize * _1M)); 223 224 /* Attach button icon */ 225 m_pLocationSelector->setIcon(vboxGlobal().iconSet(":/select_file_16px.png", "select_file_dis_16px.png")); 226 227 /* Setup page connections */ 228 connect(m_pLocationEditor, SIGNAL(textChanged(const QString &)), this, SLOT(onLocationEditorTextChanged(const QString &))); 229 connect(m_pLocationSelector, SIGNAL(clicked()), this, SLOT(onSelectLocationButtonClicked())); 230 connect(m_pSizeSlider, SIGNAL(valueChanged(int)), this, SLOT(onSizeSliderValueChanged(int))); 231 connect(m_pSizeEditor, SIGNAL(textChanged(const QString &)), this, SLOT(onSizeEditorTextChanged(const QString &))); 232 233 /* Translate */ 234 retranslateUi(); 235 } 236 237 void UINewHDWzdPage3::retranslateUi() 238 { 239 /* Translate uic generated strings */ 240 Ui::UINewHDWzdPage3::retranslateUi(this); 241 242 /* Wizard page 3 title */ 243 setTitle(tr("Virtual Disk Location and Size")); 244 } 245 246 void UINewHDWzdPage3::initializePage() 247 { 248 /* Translate */ 249 retranslateUi(); 250 251 /* Initialise location */ 252 m_pLocationEditor->setText(m_strInitialName); 253 254 /* Initialise size */ 255 m_pSizeSlider->setValue(sizeMBToSlider(m_uInitialSize, m_iSliderScale)); 256 257 /* 'Size' editor should have focus initially */ 258 m_pSizeEditor->setFocus(); 259 } 260 261 void UINewHDWzdPage3::cleanupPage() 262 { 263 /* Do not call superclass method! */ 264 } 265 266 bool UINewHDWzdPage3::isComplete() const 267 { 268 /* Check what 'currentSize' field value feats the bounds & 269 * what 'currentName' field text is not empty! */ 270 return field("currentSize").toULongLong() >= m_uMinVDISize && 271 field("currentSize").toULongLong() <= m_uMaxVDISize && 272 !field("currentName").toString().trimmed().isEmpty(); 273 } 274 275 bool UINewHDWzdPage3::validatePage() 276 { 277 QString location = UINewHDWzd::composeFullFileName(m_strLocation); 278 if (QFileInfo(location).exists()) 279 { 280 vboxProblem().sayCannotOverwriteHardDiskStorage(this, location); 281 return false; 282 } 283 return true; 284 } 285 286 void UINewHDWzdPage3::onLocationEditorTextChanged(const QString &strText) 287 { 288 /* Set current name */ 289 m_strCurrentName = strText; 290 291 /* Set current fileName */ 292 m_strLocation = toFileName(strText); 293 } 294 295 void UINewHDWzdPage3::onSelectLocationButtonClicked() 296 { 297 /* Set the first parent directory that exists as the current */ 298 QFileInfo fullFilePath(UINewHDWzd::composeFullFileName(m_strLocation)); 299 QDir folder = fullFilePath.path(); 300 QString fileName = fullFilePath.fileName(); 301 302 while (!folder.exists() && !folder.isRoot()) 303 folder = QFileInfo(folder.absolutePath()).dir(); 304 305 if (!folder.exists() || folder.isRoot()) 263 306 { 264 307 CVirtualBox vbox = vboxGlobal().virtualBox(); 265 fld = QFileInfo (vbox.GetSystemProperties().GetDefaultHardDiskFolder()); 266 if (!fld.exists()) 267 fld = vbox.GetHomeFolder(); 268 } 269 270 QString selected = QFileDialog::getSaveFileName ( 271 this, 272 tr ("Select a file for the new hard disk image file"), 273 fld.absoluteFilePath(), 274 tr ("Hard disk images (*.vdi)")); 308 folder = vbox.GetSystemProperties().GetDefaultHardDiskFolder(); 309 if (!folder.exists()) 310 folder = vbox.GetHomeFolder(); 311 } 312 313 QString selected = QFileDialog::getSaveFileName(this, tr("Select a file for the new hard disk image file"), 314 folder.absoluteFilePath(fileName), tr("Hard disk images (*.vdi)")); 275 315 276 316 if (!selected.isEmpty()) 277 317 { 278 if (QFileInfo 318 if (QFileInfo(selected).completeSuffix().isEmpty()) 279 319 selected += ".vdi"; 280 mLeName->setText (QDir::toNativeSeparators (selected)); 281 mLeName->selectAll(); 282 mLeName->setFocus(); 283 } 284 } 285 286 void VBoxNewHDWzd::revalidate (QIWidgetValidator *aWval) 287 { 288 /* do individual validations for pages */ 289 bool valid = aWval->isOtherValid(); 290 291 if (aWval == mWValNameAndSize) 292 valid = mCurrentSize >= MinVDISize && mCurrentSize <= mMaxVDISize; 293 294 aWval->setOtherValid (valid); 295 } 296 297 void VBoxNewHDWzd::enableNext (const QIWidgetValidator *aWval) 298 { 299 nextButton (aWval->widget())->setEnabled (aWval->isValid()); 300 } 301 302 void VBoxNewHDWzd::onPageShow() 303 { 304 /* Make sure all is properly translated & composed */ 305 retranslateUi(); 306 307 QWidget *page = mPageStack->currentWidget(); 308 309 if (page == mPageWelcome) 310 nextButton (page)->setFocus(); 311 else if (page == mPageType) 312 mRbDynamicType->isChecked() ? mRbDynamicType->setFocus() : 313 mRbFixedType->setFocus(); 314 else if (page == mPageNameAndSize) 315 mLeName->setFocus(); 316 else if (page == mPageSummary) 317 mTeSummary->setFocus(); 318 319 if (page == mPageSummary) 320 finishButton()->setDefault (true); 321 else 322 nextButton (page)->setDefault (true); 323 } 324 325 void VBoxNewHDWzd::showNextPage() 326 { 327 /* Warn user about already present hard-disk */ 328 if (sender() == mBtnNext3 && 329 QFileInfo (location()).exists()) 330 { 331 vboxProblem().sayCannotOverwriteHardDiskStorage (this, location()); 332 return; 333 } 334 335 /* Switch to the next page */ 336 QIAbstractWizard::showNextPage(); 337 } 338 339 340 QString VBoxNewHDWzd::location() 341 { 342 QString name = QDir::toNativeSeparators (mLeName->text()); 343 344 /* remove all trailing dots to avoid multiple dots before .vdi */ 320 m_pSizeEditor->setText(QDir::toNativeSeparators(selected)); 321 m_pSizeEditor->selectAll(); 322 m_pSizeEditor->setFocus(); 323 } 324 } 325 326 void UINewHDWzdPage3::onSizeSliderValueChanged(int iValue) 327 { 328 m_uCurrentSize = sliderToSizeMB(iValue, m_iSliderScale); 329 m_pSizeEditor->setText(vboxGlobal().formatSize(m_uCurrentSize * _1M)); 330 updateSizeToolTip(m_uCurrentSize * _1M); 331 } 332 333 void UINewHDWzdPage3::onSizeEditorTextChanged(const QString &strValue) 334 { 335 updateSizeToolTip(vboxGlobal().parseSize(strValue)); 336 m_uCurrentSize = vboxGlobal().parseSize(strValue) / _1M; 337 m_pSizeSlider->setValue(sizeMBToSlider(m_uCurrentSize, m_iSliderScale)); 338 } 339 340 QString UINewHDWzdPage3::toFileName(const QString &strName) 341 { 342 QString fileName = QDir::toNativeSeparators(strName); 343 344 /* Remove all trailing dots to avoid multiple dots before .vdi */ 345 345 int len; 346 while (len = name.length(), len > 0 && name [len - 1] == '.') 347 name.truncate (len - 1); 348 349 QString ext = QFileInfo (name).completeSuffix(); 350 351 if (RTPathCompare (ext.toUtf8(), "vdi") != 0) 352 name += ".vdi"; 353 354 return name; 355 } 356 357 bool VBoxNewHDWzd::isDynamicStorage() 358 { 359 return mRbDynamicType->isChecked(); 360 } 361 362 void VBoxNewHDWzd::updateSizeToolTip (quint64 aSizeB) 363 { 364 QString tip = tr ("<nobr>%1 Bytes</nobr>").arg (aSizeB); 365 mSlSize->setToolTip (tip); 366 mLeSize->setToolTip (tip); 367 } 368 369 /** 370 * Performs steps necessary to create a hard disk. This method handles all 371 * errors and shows the corresponding messages when appropriate. 372 * 373 * @return Wheter the creation was successful or not. 374 */ 375 bool VBoxNewHDWzd::createHardDisk() 346 while (len = fileName.length(), len > 0 && fileName [len - 1] == '.') 347 fileName.truncate(len - 1); 348 349 QString ext = QFileInfo(fileName).completeSuffix(); 350 351 if (RTPathCompare(ext.toUtf8(), "vdi") != 0) 352 fileName += ".vdi"; 353 354 return fileName; 355 } 356 357 int UINewHDWzdPage3::log2i(qulonglong uValue) 358 { 359 int iPower = -1; 360 while (uValue) 361 { 362 ++ iPower; 363 uValue >>= 1; 364 } 365 return iPower; 366 } 367 368 int UINewHDWzdPage3::sizeMBToSlider(qulonglong uValue, int iSliderScale) 369 { 370 int iPower = log2i(uValue); 371 qulonglong uTickMB = qulonglong (1) << iPower; 372 qulonglong uTickMBNext = qulonglong (1) << (iPower + 1); 373 int iStep = (uValue - uTickMB) * iSliderScale / (uTickMBNext - uTickMB); 374 return iPower * iSliderScale + iStep; 375 } 376 377 qulonglong UINewHDWzdPage3::sliderToSizeMB(int uValue, int iSliderScale) 378 { 379 int iPower = uValue / iSliderScale; 380 int iStep = uValue % iSliderScale; 381 qulonglong uTickMB = qulonglong (1) << iPower; 382 qulonglong uTickMBNext = qulonglong (1) << (iPower + 1); 383 return uTickMB + (uTickMBNext - uTickMB) * iStep / iSliderScale; 384 } 385 386 void UINewHDWzdPage3::updateSizeToolTip(qulonglong uSize) 387 { 388 QString strToolTip = tr("<nobr>%1 (%2 B)</nobr>").arg(vboxGlobal().formatSize(uSize)).arg(uSize); 389 m_pSizeSlider->setToolTip(strToolTip); 390 m_pSizeEditor->setToolTip(strToolTip); 391 } 392 393 UINewHDWzdPage4::UINewHDWzdPage4() 394 { 395 /* Decorate page */ 396 Ui::UINewHDWzdPage4::setupUi(this); 397 398 /* Register CMedium class */ 399 qRegisterMetaType<CMedium>(); 400 401 /* Register 'hardDisk' field */ 402 registerField("hardDisk", this, "hardDisk"); 403 404 /* Disable the background painting of the summary widget */ 405 m_pSummaryText->viewport()->setAutoFillBackground (false); 406 /* Make the summary field read-only */ 407 m_pSummaryText->setReadOnly (true); 408 409 /* Translate */ 410 retranslateUi(); 411 } 412 413 void UINewHDWzdPage4::retranslateUi() 414 { 415 /* Translate uic generated strings */ 416 Ui::UINewHDWzdPage4::retranslateUi(this); 417 418 /* Wizard page 4 title */ 419 setTitle(tr("Summary")); 420 421 /* Compose common summary */ 422 QString summary; 423 424 QString type = field("type").toString(); 425 QString location = UINewHDWzd::composeFullFileName(field("location").toString()); 426 QString sizeFormatted = VBoxGlobal::formatSize(field("currentSize").toULongLong() * _1M); 427 QString sizeUnformatted = tr("%1 B").arg(field("currentSize").toULongLong() * _1M); 428 429 summary += QString 430 ( 431 "<tr><td><nobr>%1: </nobr></td><td><nobr>%2</nobr></td></tr>" 432 "<tr><td><nobr>%3: </nobr></td><td><nobr>%4</nobr></td></tr>" 433 "<tr><td><nobr>%5: </nobr></td><td><nobr>%6 (%7)</nobr></td></tr>" 434 ) 435 .arg (tr("Type", "summary"), type) 436 .arg (tr("Location", "summary"), location) 437 .arg (tr("Size", "summary"), sizeFormatted, sizeUnformatted) 438 ; 439 /* Feat summary to 3 lines */ 440 setSummaryFieldLinesNumber(m_pSummaryText, 3); 441 442 m_pSummaryText->setText("<table cellspacing=0 cellpadding=0>" + summary + "</table>"); 443 } 444 445 void UINewHDWzdPage4::initializePage() 446 { 447 /* Translate */ 448 retranslateUi(); 449 450 /* Summary should have focus initially */ 451 m_pSummaryText->setFocus(); 452 } 453 454 bool UINewHDWzdPage4::validatePage() 455 { 456 /* Try to construct hard disk */ 457 return createHardDisk(); 458 } 459 460 bool UINewHDWzdPage4::createHardDisk() 376 461 { 377 462 KMediumVariant variant = KMediumVariant_Standard; 378 QString loc = location(); 379 380 AssertReturn (!loc.isEmpty(), false); 381 AssertReturn (mCurrentSize > 0, false); 463 QString loc = field("location").toString(); 464 qulonglong size = field("currentSize").toULongLong(); 465 bool isFixed = field("fixed").toBool(); 466 467 AssertReturn(!loc.isNull(), false); 468 AssertReturn(size > 0, false); 382 469 383 470 CVirtualBox vbox = vboxGlobal().virtualBox(); … … 385 472 CProgress progress; 386 473 387 CMedium h d = vbox.CreateHardDisk(QString("VDI"), loc);474 CMedium hardDisk = vbox.CreateHardDisk(QString("VDI"), loc); 388 475 389 476 if (!vbox.isOk()) 390 477 { 391 vboxProblem().cannotCreateHardDiskStorage (this, vbox, loc, hd, 392 progress); 478 vboxProblem().cannotCreateHardDiskStorage(this, vbox, loc, hardDisk, progress); 393 479 return false; 394 480 } 395 481 396 if ( !isDynamicStorage())482 if (isFixed) 397 483 variant = (KMediumVariant)(KMediumVariant_Standard | KMediumVariant_Fixed); 398 484 399 progress = hd.CreateBaseStorage (mCurrentSize, variant); 400 401 if (!hd.isOk()) 402 { 403 vboxProblem().cannotCreateHardDiskStorage (this, vbox, loc, hd, 404 progress); 485 progress = hardDisk.CreateBaseStorage(size, variant); 486 487 if (!hardDisk.isOk()) 488 { 489 vboxProblem().cannotCreateHardDiskStorage(this, vbox, loc, hardDisk, progress); 405 490 return false; 406 491 } 407 492 408 vboxProblem().showModalProgressDialog 493 vboxProblem().showModalProgressDialog(progress, windowTitle(), parentWidget()); 409 494 410 495 if (progress.GetCanceled()) … … 413 498 if (!progress.isOk() || progress.GetResultCode() != 0) 414 499 { 415 vboxProblem().cannotCreateHardDiskStorage (this, vbox, loc, hd, 416 progress); 500 vboxProblem().cannotCreateHardDiskStorage(this, vbox, loc, hardDisk, progress); 417 501 return false; 418 502 } 419 503 420 504 /* Inform everybody there is a new medium */ 421 vboxGlobal().addMedium (VBoxMedium (CMedium (hd), 422 VBoxDefs::MediumType_HardDisk, 423 KMediumState_Created)); 424 425 mHD = hd; 505 vboxGlobal().addMedium(VBoxMedium(CMedium(hardDisk), VBoxDefs::MediumType_HardDisk, KMediumState_Created)); 506 507 m_HardDisk = hardDisk; 426 508 return true; 427 509 } 428 -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/newhd/UINewHDWzd.h
r25356 r26079 2 2 * 3 3 * VBox frontends: Qt4 GUI ("VirtualBox"): 4 * VBoxNewHDWzd class declaration4 * UINewHDWzd class declaration 5 5 */ 6 6 7 7 /* 8 * Copyright (C) 2006-20 08Sun Microsystems, Inc.8 * Copyright (C) 2006-2010 Sun Microsystems, Inc. 9 9 * 10 10 * This file is part of VirtualBox Open Source Edition (OSE), as … … 21 21 */ 22 22 23 #ifndef __ VBoxNewHDWzd_h__24 #define __ VBoxNewHDWzd_h__23 #ifndef __UINewHDWzd_h__ 24 #define __UINewHDWzd_h__ 25 25 26 #include "QIAbstractWizard.h" 27 #include " VBoxNewHDWzd.gen.h"26 /* Local includes */ 27 #include "QIWizard.h" 28 28 #include "COMDefs.h" 29 #include "QIWidgetValidator.h"30 #include "QIWithRetranslateUI.h"31 29 32 class VBoxNewHDWzd : public QIWithRetranslateUI<QIAbstractWizard>, 33 public Ui::VBoxNewHDWzd 30 /* Generated includes */ 31 #include "UINewHDWzdPage1.gen.h" 32 #include "UINewHDWzdPage2.gen.h" 33 #include "UINewHDWzdPage3.gen.h" 34 #include "UINewHDWzdPage4.gen.h" 35 36 class UINewHDWzd : public QIWizard 34 37 { 35 38 Q_OBJECT; … … 37 40 public: 38 41 39 VBoxNewHDWzd (QWidget *aParent = 0);42 UINewHDWzd(QWidget *pParent); 40 43 41 CMedium hardDisk() { return mHD; } 42 void setRecommendedFileName (const QString &aName); 43 void setRecommendedSize (quint64 aSize); 44 CMedium hardDisk() const; 45 46 void setRecommendedName(const QString &strName); 47 void setRecommendedSize(qulonglong uSize); 48 49 static QString composeFullFileName(const QString &strFileName); 50 51 protected: 52 53 void retranslateUi(); 54 }; 55 56 class UINewHDWzdPage1 : public QIWizardPage, public Ui::UINewHDWzdPage1 57 { 58 Q_OBJECT; 59 60 public: 61 62 UINewHDWzdPage1(); 63 64 protected: 65 66 void retranslateUi(); 67 }; 68 69 class UINewHDWzdPage2 : public QIWizardPage, public Ui::UINewHDWzdPage2 70 { 71 Q_OBJECT; 72 Q_PROPERTY(QString type READ type WRITE setType); 73 Q_PROPERTY(bool fixed READ fixed WRITE setFixed); 74 75 public: 76 77 UINewHDWzdPage2(); 44 78 45 79 protected: … … 47 81 void retranslateUi(); 48 82 83 void initializePage(); 84 49 85 private slots: 50 86 51 void accept(); 52 void slSizeValueChanged (int aVal); 53 void leSizeTextChanged (const QString &aText); 54 void tbNameSelectClicked(); 55 void revalidate (QIWidgetValidator *aWval); 56 void enableNext (const QIWidgetValidator *aWval); 57 void onPageShow(); 58 void showNextPage(); 87 void onTypeChanged(); 59 88 60 89 private: 61 90 62 QString location(); 63 bool isDynamicStorage(); 64 void updateSizeToolTip (quint64 aSizeB); 91 QString type() const { return m_strType; } 92 void setType(const QString &strType) { m_strType = strType; } 93 QString m_strType; 94 95 bool fixed() const { return m_bFixed; } 96 void setFixed(bool bFixed) { m_bFixed = bFixed; } 97 bool m_bFixed; 98 }; 99 100 class UINewHDWzdPage3 : public QIWizardPage, public Ui::UINewHDWzdPage3 101 { 102 Q_OBJECT; 103 Q_PROPERTY(QString initialName READ initialName WRITE setInitialName); 104 Q_PROPERTY(QString currentName READ currentName WRITE setCurrentName); 105 Q_PROPERTY(QString location READ location WRITE setLocation); 106 Q_PROPERTY(qulonglong initialSize READ initialSize WRITE setInitialSize); 107 Q_PROPERTY(qulonglong currentSize READ currentSize WRITE setCurrentSize); 108 109 public: 110 111 UINewHDWzdPage3(); 112 113 protected: 114 115 void retranslateUi(); 116 117 void initializePage(); 118 void cleanupPage(); 119 120 bool isComplete() const; 121 bool validatePage(); 122 123 private slots: 124 125 void onLocationEditorTextChanged(const QString &strName); 126 void onSelectLocationButtonClicked(); 127 128 void onSizeSliderValueChanged(int iValue); 129 void onSizeEditorTextChanged(const QString &strValue); 130 131 private: 132 133 static QString toFileName(const QString &strName); 134 135 static int log2i(qulonglong uValue); 136 static int sizeMBToSlider(qulonglong uValue, int iSliderScale); 137 static qulonglong sliderToSizeMB(int uValue, int iSliderScale); 138 139 void updateSizeToolTip(qulonglong uSize); 140 141 QString initialName() const { return m_strInitialName; } 142 void setInitialName(const QString &strInitialName) { m_strInitialName = strInitialName; } 143 QString m_strInitialName; 144 145 QString currentName() const { return m_strCurrentName; } 146 void setCurrentName(const QString &strCurrentName) { m_strCurrentName = strCurrentName; } 147 QString m_strCurrentName; 148 149 QString location() const { return m_strLocation; } 150 void setLocation(const QString &strLocation) { m_strLocation = strLocation; } 151 QString m_strLocation; 152 153 qulonglong initialSize() const { return m_uInitialSize; } 154 void setInitialSize(qulonglong uInitialSize) { m_uInitialSize = uInitialSize; } 155 qulonglong m_uInitialSize; 156 157 qulonglong currentSize() const { return m_uCurrentSize; } 158 void setCurrentSize(qulonglong uCurrentSize) { m_uCurrentSize = uCurrentSize; } 159 qulonglong m_uCurrentSize; 160 161 qulonglong m_uMinVDISize; 162 qulonglong m_uMaxVDISize; 163 int m_iSliderScale; 164 }; 165 166 class UINewHDWzdPage4 : public QIWizardPage, public Ui::UINewHDWzdPage4 167 { 168 Q_OBJECT; 169 Q_PROPERTY(CMedium hardDisk READ hardDisk WRITE setHardDisk); 170 171 public: 172 173 UINewHDWzdPage4(); 174 175 protected: 176 177 void retranslateUi(); 178 179 void initializePage(); 180 181 bool validatePage(); 182 183 private: 184 65 185 bool createHardDisk(); 66 186 67 QIWidgetValidator *mWValNameAndSize; 68 CMedium mHD; 69 int mSliderScale; 70 quint64 mMaxVDISize; 71 quint64 mCurrentSize; 187 CMedium hardDisk() const { return m_HardDisk; } 188 void setHardDisk(const CMedium &hardDisk) { m_HardDisk = hardDisk; } 189 CMedium m_HardDisk; 72 190 }; 73 191 74 #endif // __VBoxNewHDWzd_h__ 192 Q_DECLARE_METATYPE(CMedium); 75 193 194 #endif // __UINewHDWzd_h__ -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/newhd/UINewHDWzdPage1.ui
r25356 r26079 1 <ui version="4.0" > 1 <?xml version="1.0" encoding="UTF-8"?> 2 <ui version="4.0"> 2 3 <comment> 3 4 VBox frontends: Qt4 GUI ("VirtualBox"): 4 5 5 Copyright (C) 200 8Sun Microsystems, Inc.6 Copyright (C) 2009-2010 Sun Microsystems, Inc. 6 7 7 8 This file is part of VirtualBox Open Source Edition (OSE), as … … 17 18 additional information or have any questions. 18 19 </comment> 19 <class> VBoxNewHDWzd</class>20 <widget class="Q Dialog" name="VBoxNewHDWzd">21 <property name="geometry" 20 <class>UINewHDWzdPage1</class> 21 <widget class="QWidget" name="UINewHDWzdPage1"> 22 <property name="geometry"> 22 23 <rect> 23 24 <x>0</x> 24 25 <y>0</y> 25 <width> 506</width>26 <height>4 13</height>26 <width>600</width> 27 <height>400</height> 27 28 </rect> 28 29 </property> 29 <property name="windowTitle" > 30 <string>Create New Virtual Disk</string> 30 <property name="sizePolicy"> 31 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 32 <horstretch>0</horstretch> 33 <verstretch>0</verstretch> 34 </sizepolicy> 31 35 </property> 32 <layout class="QVBoxLayout" > 33 <property name="leftMargin" > 34 <number>0</number> 35 </property> 36 <property name="topMargin" > 37 <number>0</number> 38 </property> 39 <property name="rightMargin" > 40 <number>0</number> 41 </property> 36 <layout class="QVBoxLayout" name="m_pLayout1"> 42 37 <property name="bottomMargin" > 43 38 <number>0</number> 44 39 </property> 45 40 <item> 46 <widget class="Q StackedWidget" name="mPageStack">47 <property name=" currentIndex">48 < number>0</number>41 <widget class="QILabel" name="m_pPage1Text1"> 42 <property name="text"> 43 <string><p>This wizard will help you to create a new virtual hard disk for your virtual machine.</p><p>Use the <b>Next</b> button to go to the next page of the wizard and the <b>Back</b> button to return to the previous page.</p></string> 49 44 </property> 50 <widget class="QWidget" name="mPageWelcome" > 51 <layout class="QVBoxLayout" > 52 <item> 53 <widget class="QLabel" name="mPageWelcomeHdr" > 54 <property name="font" > 55 <font> 56 <family>Arial</family> 57 <pointsize>12</pointsize> 58 <weight>75</weight> 59 <bold>true</bold> 60 </font> 61 </property> 62 <property name="text" > 63 <string>Welcome to the Create New Virtual Disk Wizard!</string> 64 </property> 65 </widget> 66 </item> 67 <item> 68 <widget class="Line" name="line11" > 69 <property name="orientation" > 70 <enum>Qt::Horizontal</enum> 71 </property> 72 </widget> 73 </item> 74 <item> 75 <layout class="QHBoxLayout" > 76 <property name="spacing" > 77 <number>10</number> 78 </property> 79 <item> 80 <widget class="QLabel" name="mLogoWelcome" > 81 <property name="sizePolicy" > 82 <sizepolicy vsizetype="Minimum" hsizetype="Maximum" > 83 <horstretch>0</horstretch> 84 <verstretch>0</verstretch> 85 </sizepolicy> 86 </property> 87 <property name="autoFillBackground" > 88 <bool>true</bool> 89 </property> 90 <property name="text" > 91 <string/> 92 </property> 93 <property name="pixmap" > 94 <pixmap resource="../VirtualBox1.qrc" >:/vmw_new_harddisk.png</pixmap> 95 </property> 96 <property name="alignment" > 97 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 98 </property> 99 </widget> 100 </item> 101 <item> 102 <layout class="QVBoxLayout" > 103 <property name="spacing" > 104 <number>10</number> 105 </property> 106 <item> 107 <widget class="QILabel" name="mTextWelcome" > 108 <property name="sizePolicy" > 109 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 110 <horstretch>0</horstretch> 111 <verstretch>0</verstretch> 112 </sizepolicy> 113 </property> 114 <property name="minimumSize" > 115 <size> 116 <width>300</width> 117 <height>0</height> 118 </size> 119 </property> 120 <property name="text" > 121 <string><p>This wizard will help you to create a new virtual hard disk for your virtual machine.</p><p>Use the <b>Next</b> button to go to the next page of the wizard and the <b>Back</b> button to return to the previous page.</p></string> 122 </property> 123 <property name="alignment" > 124 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 125 </property> 126 <property name="wordWrap" > 127 <bool>true</bool> 128 </property> 129 </widget> 130 </item> 131 <item> 132 <spacer> 133 <property name="orientation" > 134 <enum>Qt::Vertical</enum> 135 </property> 136 <property name="sizeHint" > 137 <size> 138 <width>0</width> 139 <height>0</height> 140 </size> 141 </property> 142 </spacer> 143 </item> 144 </layout> 145 </item> 146 </layout> 147 </item> 148 <item> 149 <widget class="Line" name="line12" > 150 <property name="orientation" > 151 <enum>Qt::Horizontal</enum> 152 </property> 153 </widget> 154 </item> 155 <item> 156 <layout class="QHBoxLayout" > 157 <item> 158 <spacer> 159 <property name="orientation" > 160 <enum>Qt::Horizontal</enum> 161 </property> 162 <property name="sizeHint" > 163 <size> 164 <width>0</width> 165 <height>0</height> 166 </size> 167 </property> 168 </spacer> 169 </item> 170 <item> 171 <widget class="QPushButton" name="mBtnBack1" > 172 <property name="enabled" > 173 <bool>false</bool> 174 </property> 175 <property name="text" > 176 <string>< &Back</string> 177 </property> 178 </widget> 179 </item> 180 <item> 181 <widget class="QPushButton" name="mBtnNext1" > 182 <property name="text" > 183 <string>&Next ></string> 184 </property> 185 </widget> 186 </item> 187 <item> 188 <spacer> 189 <property name="orientation" > 190 <enum>Qt::Horizontal</enum> 191 </property> 192 <property name="sizeType" > 193 <enum>QSizePolicy::Fixed</enum> 194 </property> 195 <property name="sizeHint" > 196 <size> 197 <width>5</width> 198 <height>0</height> 199 </size> 200 </property> 201 </spacer> 202 </item> 203 <item> 204 <widget class="QPushButton" name="mBtnCancel1" > 205 <property name="text" > 206 <string>Cancel</string> 207 </property> 208 </widget> 209 </item> 210 </layout> 211 </item> 212 </layout> 213 </widget> 214 <widget class="QWidget" name="mPageType" > 215 <layout class="QVBoxLayout" > 216 <item> 217 <widget class="QLabel" name="mPageTypeHdr" > 218 <property name="font" > 219 <font> 220 <family>Arial</family> 221 <pointsize>12</pointsize> 222 <weight>75</weight> 223 <bold>true</bold> 224 </font> 225 </property> 226 <property name="text" > 227 <string>Hard Disk Storage Type</string> 228 </property> 229 </widget> 230 </item> 231 <item> 232 <widget class="Line" name="line21" > 233 <property name="orientation" > 234 <enum>Qt::Horizontal</enum> 235 </property> 236 </widget> 237 </item> 238 <item> 239 <layout class="QHBoxLayout" > 240 <property name="spacing" > 241 <number>10</number> 242 </property> 243 <item> 244 <widget class="QLabel" name="mLogoType" > 245 <property name="sizePolicy" > 246 <sizepolicy vsizetype="Minimum" hsizetype="Maximum" > 247 <horstretch>0</horstretch> 248 <verstretch>0</verstretch> 249 </sizepolicy> 250 </property> 251 <property name="autoFillBackground" > 252 <bool>true</bool> 253 </property> 254 <property name="text" > 255 <string/> 256 </property> 257 <property name="pixmap" > 258 <pixmap resource="../VirtualBox1.qrc" >:/vmw_new_harddisk.png</pixmap> 259 </property> 260 <property name="alignment" > 261 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 262 </property> 263 </widget> 264 </item> 265 <item> 266 <layout class="QVBoxLayout" > 267 <property name="spacing" > 268 <number>10</number> 269 </property> 270 <item> 271 <widget class="QILabel" name="mTextType" > 272 <property name="sizePolicy" > 273 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 274 <horstretch>0</horstretch> 275 <verstretch>0</verstretch> 276 </sizepolicy> 277 </property> 278 <property name="minimumSize" > 279 <size> 280 <width>300</width> 281 <height>0</height> 282 </size> 283 </property> 284 <property name="text" > 285 <string><p>Select the type of virtual hard disk you want to create.</p><p>A <b>dynamically expanding storage</b> initially occupies a very small amount of space on your physical hard disk. It will grow dynamically (up to the size specified) as the Guest OS claims disk space.</p><p>A <b>fixed-size storage</b> does not grow. It is stored in a file of approximately the same size as the size of the virtual hard disk. The creation of a fixed-size storage may take a long time depending on the storage size and the write performance of your harddisk.</p></string> 286 </property> 287 <property name="alignment" > 288 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 289 </property> 290 <property name="wordWrap" > 291 <bool>true</bool> 292 </property> 293 </widget> 294 </item> 295 <item> 296 <widget class="QGroupBox" name="mGbType" > 297 <property name="sizePolicy" > 298 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 299 <horstretch>0</horstretch> 300 <verstretch>0</verstretch> 301 </sizepolicy> 302 </property> 303 <property name="title" > 304 <string>Storage Type</string> 305 </property> 306 <layout class="QVBoxLayout" > 307 <property name="topMargin" > 308 <number>4</number> 309 </property> 310 <item> 311 <widget class="QRadioButton" name="mRbDynamicType" > 312 <property name="sizePolicy" > 313 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 314 <horstretch>0</horstretch> 315 <verstretch>0</verstretch> 316 </sizepolicy> 317 </property> 318 <property name="text" > 319 <string>&Dynamically expanding storage</string> 320 </property> 321 <property name="checked" > 322 <bool>true</bool> 323 </property> 324 </widget> 325 </item> 326 <item> 327 <widget class="QRadioButton" name="mRbFixedType" > 328 <property name="sizePolicy" > 329 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 330 <horstretch>0</horstretch> 331 <verstretch>0</verstretch> 332 </sizepolicy> 333 </property> 334 <property name="text" > 335 <string>&Fixed-size storage</string> 336 </property> 337 </widget> 338 </item> 339 </layout> 340 </widget> 341 </item> 342 <item> 343 <spacer> 344 <property name="orientation" > 345 <enum>Qt::Vertical</enum> 346 </property> 347 <property name="sizeHint" > 348 <size> 349 <width>0</width> 350 <height>0</height> 351 </size> 352 </property> 353 </spacer> 354 </item> 355 </layout> 356 </item> 357 </layout> 358 </item> 359 <item> 360 <widget class="Line" name="line22" > 361 <property name="orientation" > 362 <enum>Qt::Horizontal</enum> 363 </property> 364 </widget> 365 </item> 366 <item> 367 <layout class="QHBoxLayout" > 368 <item> 369 <spacer> 370 <property name="orientation" > 371 <enum>Qt::Horizontal</enum> 372 </property> 373 <property name="sizeHint" > 374 <size> 375 <width>0</width> 376 <height>0</height> 377 </size> 378 </property> 379 </spacer> 380 </item> 381 <item> 382 <widget class="QPushButton" name="mBtnBack2" > 383 <property name="text" > 384 <string>< &Back</string> 385 </property> 386 </widget> 387 </item> 388 <item> 389 <widget class="QPushButton" name="mBtnNext2" > 390 <property name="text" > 391 <string>&Next ></string> 392 </property> 393 </widget> 394 </item> 395 <item> 396 <spacer> 397 <property name="orientation" > 398 <enum>Qt::Horizontal</enum> 399 </property> 400 <property name="sizeType" > 401 <enum>QSizePolicy::Fixed</enum> 402 </property> 403 <property name="sizeHint" > 404 <size> 405 <width>5</width> 406 <height>0</height> 407 </size> 408 </property> 409 </spacer> 410 </item> 411 <item> 412 <widget class="QPushButton" name="mBtnCancel2" > 413 <property name="text" > 414 <string>Cancel</string> 415 </property> 416 </widget> 417 </item> 418 </layout> 419 </item> 420 </layout> 421 </widget> 422 <widget class="QWidget" name="mPageNameAndSize" > 423 <layout class="QVBoxLayout" > 424 <item> 425 <widget class="QLabel" name="mPageNameAndSizeHdr" > 426 <property name="font" > 427 <font> 428 <family>Arial</family> 429 <pointsize>12</pointsize> 430 <weight>75</weight> 431 <bold>true</bold> 432 </font> 433 </property> 434 <property name="text" > 435 <string>Virtual Disk Location and Size</string> 436 </property> 437 </widget> 438 </item> 439 <item> 440 <widget class="Line" name="line31" > 441 <property name="orientation" > 442 <enum>Qt::Horizontal</enum> 443 </property> 444 </widget> 445 </item> 446 <item> 447 <layout class="QHBoxLayout" > 448 <property name="spacing" > 449 <number>10</number> 450 </property> 451 <item> 452 <widget class="QLabel" name="mLogoNameAndSize" > 453 <property name="sizePolicy" > 454 <sizepolicy vsizetype="Minimum" hsizetype="Maximum" > 455 <horstretch>0</horstretch> 456 <verstretch>0</verstretch> 457 </sizepolicy> 458 </property> 459 <property name="autoFillBackground" > 460 <bool>true</bool> 461 </property> 462 <property name="text" > 463 <string/> 464 </property> 465 <property name="pixmap" > 466 <pixmap resource="../VirtualBox1.qrc" >:/vmw_new_harddisk.png</pixmap> 467 </property> 468 <property name="alignment" > 469 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 470 </property> 471 </widget> 472 </item> 473 <item> 474 <layout class="QVBoxLayout" > 475 <property name="spacing" > 476 <number>10</number> 477 </property> 478 <item> 479 <widget class="QILabel" name="mTextNameComment" > 480 <property name="sizePolicy" > 481 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 482 <horstretch>0</horstretch> 483 <verstretch>0</verstretch> 484 </sizepolicy> 485 </property> 486 <property name="minimumSize" > 487 <size> 488 <width>300</width> 489 <height>0</height> 490 </size> 491 </property> 492 <property name="text" > 493 <string><p>Press the <b>Select</b> button to select the location of a file to store the hard disk data or type a file name in the entry field.</p></string> 494 </property> 495 <property name="alignment" > 496 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 497 </property> 498 <property name="wordWrap" > 499 <bool>true</bool> 500 </property> 501 </widget> 502 </item> 503 <item> 504 <widget class="QGroupBox" name="mGbName" > 505 <property name="sizePolicy" > 506 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 507 <horstretch>0</horstretch> 508 <verstretch>0</verstretch> 509 </sizepolicy> 510 </property> 511 <property name="title" > 512 <string>&Location</string> 513 </property> 514 <layout class="QHBoxLayout" > 515 <property name="topMargin" > 516 <number>4</number> 517 </property> 518 <item> 519 <widget class="QLineEdit" name="mLeName" /> 520 </item> 521 <item> 522 <widget class="QToolButton" name="mTbNameSelect" > 523 <property name="text" > 524 <string/> 525 </property> 526 <property name="icon" > 527 <iconset resource="../VirtualBox1.qrc" >:/select_file_16px.png</iconset> 528 </property> 529 </widget> 530 </item> 531 </layout> 532 </widget> 533 </item> 534 <item> 535 <widget class="QILabel" name="mTextSizeComment" > 536 <property name="sizePolicy" > 537 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 538 <horstretch>0</horstretch> 539 <verstretch>0</verstretch> 540 </sizepolicy> 541 </property> 542 <property name="minimumSize" > 543 <size> 544 <width>300</width> 545 <height>0</height> 546 </size> 547 </property> 548 <property name="text" > 549 <string><p>Select the size of the virtual hard disk in megabytes. This size will be reported to the Guest OS as the maximum size of this hard disk.</p></string> 550 </property> 551 <property name="alignment" > 552 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 553 </property> 554 <property name="wordWrap" > 555 <bool>true</bool> 556 </property> 557 </widget> 558 </item> 559 <item> 560 <widget class="QGroupBox" name="mGbSize" > 561 <property name="sizePolicy" > 562 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 563 <horstretch>0</horstretch> 564 <verstretch>0</verstretch> 565 </sizepolicy> 566 </property> 567 <property name="title" > 568 <string>&Size</string> 569 </property> 570 <layout class="QGridLayout" > 571 <item row="0" column="0" colspan="3" > 572 <widget class="QSlider" name="mSlSize" > 573 <property name="sizePolicy" > 574 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 575 <horstretch>0</horstretch> 576 <verstretch>0</verstretch> 577 </sizepolicy> 578 </property> 579 <property name="orientation" > 580 <enum>Qt::Horizontal</enum> 581 </property> 582 <property name="tickPosition" > 583 <enum>QSlider::TicksBelow</enum> 584 </property> 585 </widget> 586 </item> 587 <item row="0" column="3" > 588 <widget class="QILineEdit" name="mLeSize" > 589 <property name="sizePolicy" > 590 <sizepolicy vsizetype="Fixed" hsizetype="Maximum" > 591 <horstretch>0</horstretch> 592 <verstretch>0</verstretch> 593 </sizepolicy> 594 </property> 595 </widget> 596 </item> 597 <item row="1" column="0" > 598 <widget class="QLabel" name="mTxSizeMin" > 599 <property name="sizePolicy" > 600 <sizepolicy vsizetype="Preferred" hsizetype="Minimum" > 601 <horstretch>0</horstretch> 602 <verstretch>0</verstretch> 603 </sizepolicy> 604 </property> 605 <property name="alignment" > 606 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 607 </property> 608 </widget> 609 </item> 610 <item row="1" column="1" > 611 <spacer> 612 <property name="orientation" > 613 <enum>Qt::Horizontal</enum> 614 </property> 615 <property name="sizeType" > 616 <enum>QSizePolicy::Expanding</enum> 617 </property> 618 <property name="sizeHint" > 619 <size> 620 <width>221</width> 621 <height>20</height> 622 </size> 623 </property> 624 </spacer> 625 </item> 626 <item row="1" column="2" > 627 <widget class="QLabel" name="mTxSizeMax" > 628 <property name="sizePolicy" > 629 <sizepolicy vsizetype="Preferred" hsizetype="Minimum" > 630 <horstretch>0</horstretch> 631 <verstretch>0</verstretch> 632 </sizepolicy> 633 </property> 634 <property name="alignment" > 635 <set>Qt::AlignRight|Qt::AlignTop|Qt::AlignTrailing</set> 636 </property> 637 </widget> 638 </item> 639 </layout> 640 </widget> 641 </item> 642 <item> 643 <spacer> 644 <property name="orientation" > 645 <enum>Qt::Vertical</enum> 646 </property> 647 <property name="sizeHint" > 648 <size> 649 <width>0</width> 650 <height>0</height> 651 </size> 652 </property> 653 </spacer> 654 </item> 655 </layout> 656 </item> 657 </layout> 658 </item> 659 <item> 660 <widget class="Line" name="line32" > 661 <property name="orientation" > 662 <enum>Qt::Horizontal</enum> 663 </property> 664 </widget> 665 </item> 666 <item> 667 <layout class="QHBoxLayout" > 668 <item> 669 <spacer> 670 <property name="orientation" > 671 <enum>Qt::Horizontal</enum> 672 </property> 673 <property name="sizeHint" > 674 <size> 675 <width>0</width> 676 <height>0</height> 677 </size> 678 </property> 679 </spacer> 680 </item> 681 <item> 682 <widget class="QPushButton" name="mBtnBack3" > 683 <property name="text" > 684 <string>< &Back</string> 685 </property> 686 </widget> 687 </item> 688 <item> 689 <widget class="QPushButton" name="mBtnNext3" > 690 <property name="text" > 691 <string>&Next ></string> 692 </property> 693 </widget> 694 </item> 695 <item> 696 <spacer> 697 <property name="orientation" > 698 <enum>Qt::Horizontal</enum> 699 </property> 700 <property name="sizeType" > 701 <enum>QSizePolicy::Fixed</enum> 702 </property> 703 <property name="sizeHint" > 704 <size> 705 <width>5</width> 706 <height>0</height> 707 </size> 708 </property> 709 </spacer> 710 </item> 711 <item> 712 <widget class="QPushButton" name="mBtnCancel3" > 713 <property name="text" > 714 <string>Cancel</string> 715 </property> 716 </widget> 717 </item> 718 </layout> 719 </item> 720 </layout> 721 </widget> 722 <widget class="QWidget" name="mPageSummary" > 723 <layout class="QVBoxLayout" > 724 <item> 725 <widget class="QLabel" name="mPageSummaryHdr" > 726 <property name="font" > 727 <font> 728 <family>Arial</family> 729 <pointsize>12</pointsize> 730 <weight>75</weight> 731 <bold>true</bold> 732 </font> 733 </property> 734 <property name="text" > 735 <string>Summary</string> 736 </property> 737 </widget> 738 </item> 739 <item> 740 <widget class="Line" name="line41" > 741 <property name="orientation" > 742 <enum>Qt::Horizontal</enum> 743 </property> 744 </widget> 745 </item> 746 <item> 747 <layout class="QHBoxLayout" > 748 <property name="spacing" > 749 <number>10</number> 750 </property> 751 <item> 752 <widget class="QLabel" name="mLogoSummary" > 753 <property name="sizePolicy" > 754 <sizepolicy vsizetype="Minimum" hsizetype="Maximum" > 755 <horstretch>0</horstretch> 756 <verstretch>0</verstretch> 757 </sizepolicy> 758 </property> 759 <property name="autoFillBackground" > 760 <bool>true</bool> 761 </property> 762 <property name="text" > 763 <string/> 764 </property> 765 <property name="pixmap" > 766 <pixmap resource="../VirtualBox1.qrc" >:/vmw_new_harddisk.png</pixmap> 767 </property> 768 <property name="alignment" > 769 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 770 </property> 771 </widget> 772 </item> 773 <item> 774 <layout class="QVBoxLayout" > 775 <property name="spacing" > 776 <number>10</number> 777 </property> 778 <item> 779 <widget class="QILabel" name="mTextSummaryHdr" > 780 <property name="sizePolicy" > 781 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 782 <horstretch>0</horstretch> 783 <verstretch>0</verstretch> 784 </sizepolicy> 785 </property> 786 <property name="minimumSize" > 787 <size> 788 <width>300</width> 789 <height>0</height> 790 </size> 791 </property> 792 <property name="text" > 793 <string>You are going to create a new virtual hard disk with the following parameters:</string> 794 </property> 795 <property name="alignment" > 796 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 797 </property> 798 <property name="wordWrap" > 799 <bool>true</bool> 800 </property> 801 </widget> 802 </item> 803 <item> 804 <widget class="QITextEdit" name="mTeSummary" > 805 <property name="sizePolicy" > 806 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 807 <horstretch>0</horstretch> 808 <verstretch>0</verstretch> 809 </sizepolicy> 810 </property> 811 <property name="minimumSize" > 812 <size> 813 <width>300</width> 814 <height>0</height> 815 </size> 816 </property> 817 <property name="frameShape" > 818 <enum>QFrame::NoFrame</enum> 819 </property> 820 <property name="autoFormatting" > 821 <set>QTextEdit::AutoAll</set> 822 </property> 823 <property name="readOnly" > 824 <bool>true</bool> 825 </property> 826 </widget> 827 </item> 828 <item> 829 <widget class="QILabel" name="mTextSummaryFtr" > 830 <property name="sizePolicy" > 831 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 832 <horstretch>0</horstretch> 833 <verstretch>0</verstretch> 834 </sizepolicy> 835 </property> 836 <property name="minimumSize" > 837 <size> 838 <width>300</width> 839 <height>0</height> 840 </size> 841 </property> 842 <property name="text" > 843 <string>If the above settings are correct, press the <b>Finish</b> button. Once you press it, a new hard disk will be created.</string> 844 </property> 845 <property name="alignment" > 846 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 847 </property> 848 <property name="wordWrap" > 849 <bool>true</bool> 850 </property> 851 </widget> 852 </item> 853 <item> 854 <spacer> 855 <property name="orientation" > 856 <enum>Qt::Vertical</enum> 857 </property> 858 <property name="sizeType" > 859 <enum>QSizePolicy::Expanding</enum> 860 </property> 861 <property name="sizeHint" > 862 <size> 863 <width>0</width> 864 <height>0</height> 865 </size> 866 </property> 867 </spacer> 868 </item> 869 </layout> 870 </item> 871 </layout> 872 </item> 873 <item> 874 <widget class="Line" name="line42" > 875 <property name="orientation" > 876 <enum>Qt::Horizontal</enum> 877 </property> 878 </widget> 879 </item> 880 <item> 881 <layout class="QHBoxLayout" > 882 <item> 883 <spacer> 884 <property name="orientation" > 885 <enum>Qt::Horizontal</enum> 886 </property> 887 <property name="sizeHint" > 888 <size> 889 <width>0</width> 890 <height>0</height> 891 </size> 892 </property> 893 </spacer> 894 </item> 895 <item> 896 <widget class="QPushButton" name="mBtnBack4" > 897 <property name="text" > 898 <string>< &Back</string> 899 </property> 900 </widget> 901 </item> 902 <item> 903 <widget class="QPushButton" name="mBtnFinish" > 904 <property name="text" > 905 <string>&Finish</string> 906 </property> 907 </widget> 908 </item> 909 <item> 910 <spacer> 911 <property name="orientation" > 912 <enum>Qt::Horizontal</enum> 913 </property> 914 <property name="sizeType" > 915 <enum>QSizePolicy::Fixed</enum> 916 </property> 917 <property name="sizeHint" > 918 <size> 919 <width>5</width> 920 <height>0</height> 921 </size> 922 </property> 923 </spacer> 924 </item> 925 <item> 926 <widget class="QPushButton" name="mBtnCancel4" > 927 <property name="text" > 928 <string>Cancel</string> 929 </property> 930 </widget> 931 </item> 932 </layout> 933 </item> 934 </layout> 935 </widget> 45 <property name="wordWrap"> 46 <bool>true</bool> 47 </property> 936 48 </widget> 49 </item> 50 <item> 51 <spacer name="m_pSpacer1"> 52 <property name="sizeHint" stdset="0"> 53 <size> 54 <width>0</width> 55 <height>0</height> 56 </size> 57 </property> 58 </spacer> 937 59 </item> 938 60 </layout> … … 944 66 <header>QILabel.h</header> 945 67 </customwidget> 946 <customwidget>947 <class>QITextEdit</class>948 <extends>QTextEdit</extends>949 <header>QIAbstractWizard.h</header>950 </customwidget>951 <customwidget>952 <class>QILineEdit</class>953 <extends>QLineEdit</extends>954 <header>QILineEdit.h</header>955 </customwidget>956 68 </customwidgets> 957 <tabstops> 958 <tabstop>mBtnNext1</tabstop> 959 <tabstop>mBtnCancel1</tabstop> 960 <tabstop>mBtnBack2</tabstop> 961 <tabstop>mBtnNext2</tabstop> 962 <tabstop>mBtnCancel2</tabstop> 963 <tabstop>mSlSize</tabstop> 964 <tabstop>mLeSize</tabstop> 965 <tabstop>mBtnBack3</tabstop> 966 <tabstop>mBtnNext3</tabstop> 967 <tabstop>mBtnCancel3</tabstop> 968 <tabstop>mBtnBack4</tabstop> 969 <tabstop>mBtnFinish</tabstop> 970 <tabstop>mBtnCancel4</tabstop> 971 </tabstops> 972 <resources> 973 <include location="../VirtualBox1.qrc" /> 974 </resources> 69 <resources/> 975 70 <connections/> 976 71 </ui> -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/newhd/UINewHDWzdPage2.ui
r25356 r26079 1 <ui version="4.0" > 1 <?xml version="1.0" encoding="UTF-8"?> 2 <ui version="4.0"> 2 3 <comment> 3 4 VBox frontends: Qt4 GUI ("VirtualBox"): 4 5 5 Copyright (C) 200 8Sun Microsystems, Inc.6 Copyright (C) 2009-2010 Sun Microsystems, Inc. 6 7 7 8 This file is part of VirtualBox Open Source Edition (OSE), as … … 17 18 additional information or have any questions. 18 19 </comment> 19 <class> VBoxNewHDWzd</class>20 <widget class="Q Dialog" name="VBoxNewHDWzd">21 <property name="geometry" 20 <class>UINewHDWzdPage2</class> 21 <widget class="QWidget" name="UINewHDWzdPage2"> 22 <property name="geometry"> 22 23 <rect> 23 24 <x>0</x> 24 25 <y>0</y> 25 <width> 506</width>26 <height>4 13</height>26 <width>600</width> 27 <height>400</height> 27 28 </rect> 28 29 </property> 29 <property name="windowTitle" > 30 <string>Create New Virtual Disk</string> 30 <property name="sizePolicy"> 31 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 32 <horstretch>0</horstretch> 33 <verstretch>0</verstretch> 34 </sizepolicy> 31 35 </property> 32 <layout class="QVBoxLayout" > 33 <property name="leftMargin" > 34 <number>0</number> 35 </property> 36 <property name="topMargin" > 37 <number>0</number> 38 </property> 39 <property name="rightMargin" > 40 <number>0</number> 41 </property> 36 <layout class="QVBoxLayout" name="m_pLayout1"> 42 37 <property name="bottomMargin" > 43 38 <number>0</number> 44 39 </property> 45 40 <item> 46 <widget class="Q StackedWidget" name="mPageStack">47 <property name=" currentIndex">48 < number>0</number>41 <widget class="QILabel" name="m_pPage2Text1"> 42 <property name="text"> 43 <string><p>Select the type of virtual hard disk you want to create.</p><p>A <b>dynamically expanding storage</b> initially occupies a very small amount of space on your physical hard disk. It will grow dynamically (up to the size specified) as the Guest OS claims disk space.</p><p>A <b>fixed-size storage</b> does not grow. It is stored in a file of approximately the same size as the size of the virtual hard disk. The creation of a fixed-size storage may take a long time depending on the storage size and the write performance of your harddisk.</p></string> 49 44 </property> 50 <widget class="QWidget" name="mPageWelcome" > 51 <layout class="QVBoxLayout" > 52 <item> 53 <widget class="QLabel" name="mPageWelcomeHdr" > 54 <property name="font" > 55 <font> 56 <family>Arial</family> 57 <pointsize>12</pointsize> 58 <weight>75</weight> 59 <bold>true</bold> 60 </font> 61 </property> 62 <property name="text" > 63 <string>Welcome to the Create New Virtual Disk Wizard!</string> 64 </property> 65 </widget> 66 </item> 67 <item> 68 <widget class="Line" name="line11" > 69 <property name="orientation" > 70 <enum>Qt::Horizontal</enum> 71 </property> 72 </widget> 73 </item> 74 <item> 75 <layout class="QHBoxLayout" > 76 <property name="spacing" > 77 <number>10</number> 78 </property> 79 <item> 80 <widget class="QLabel" name="mLogoWelcome" > 81 <property name="sizePolicy" > 82 <sizepolicy vsizetype="Minimum" hsizetype="Maximum" > 83 <horstretch>0</horstretch> 84 <verstretch>0</verstretch> 85 </sizepolicy> 86 </property> 87 <property name="autoFillBackground" > 88 <bool>true</bool> 89 </property> 90 <property name="text" > 91 <string/> 92 </property> 93 <property name="pixmap" > 94 <pixmap resource="../VirtualBox1.qrc" >:/vmw_new_harddisk.png</pixmap> 95 </property> 96 <property name="alignment" > 97 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 98 </property> 99 </widget> 100 </item> 101 <item> 102 <layout class="QVBoxLayout" > 103 <property name="spacing" > 104 <number>10</number> 105 </property> 106 <item> 107 <widget class="QILabel" name="mTextWelcome" > 108 <property name="sizePolicy" > 109 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 110 <horstretch>0</horstretch> 111 <verstretch>0</verstretch> 112 </sizepolicy> 113 </property> 114 <property name="minimumSize" > 115 <size> 116 <width>300</width> 117 <height>0</height> 118 </size> 119 </property> 120 <property name="text" > 121 <string><p>This wizard will help you to create a new virtual hard disk for your virtual machine.</p><p>Use the <b>Next</b> button to go to the next page of the wizard and the <b>Back</b> button to return to the previous page.</p></string> 122 </property> 123 <property name="alignment" > 124 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 125 </property> 126 <property name="wordWrap" > 127 <bool>true</bool> 128 </property> 129 </widget> 130 </item> 131 <item> 132 <spacer> 133 <property name="orientation" > 134 <enum>Qt::Vertical</enum> 135 </property> 136 <property name="sizeHint" > 137 <size> 138 <width>0</width> 139 <height>0</height> 140 </size> 141 </property> 142 </spacer> 143 </item> 144 </layout> 145 </item> 146 </layout> 147 </item> 148 <item> 149 <widget class="Line" name="line12" > 150 <property name="orientation" > 151 <enum>Qt::Horizontal</enum> 152 </property> 153 </widget> 154 </item> 155 <item> 156 <layout class="QHBoxLayout" > 157 <item> 158 <spacer> 159 <property name="orientation" > 160 <enum>Qt::Horizontal</enum> 161 </property> 162 <property name="sizeHint" > 163 <size> 164 <width>0</width> 165 <height>0</height> 166 </size> 167 </property> 168 </spacer> 169 </item> 170 <item> 171 <widget class="QPushButton" name="mBtnBack1" > 172 <property name="enabled" > 173 <bool>false</bool> 174 </property> 175 <property name="text" > 176 <string>< &Back</string> 177 </property> 178 </widget> 179 </item> 180 <item> 181 <widget class="QPushButton" name="mBtnNext1" > 182 <property name="text" > 183 <string>&Next ></string> 184 </property> 185 </widget> 186 </item> 187 <item> 188 <spacer> 189 <property name="orientation" > 190 <enum>Qt::Horizontal</enum> 191 </property> 192 <property name="sizeType" > 193 <enum>QSizePolicy::Fixed</enum> 194 </property> 195 <property name="sizeHint" > 196 <size> 197 <width>5</width> 198 <height>0</height> 199 </size> 200 </property> 201 </spacer> 202 </item> 203 <item> 204 <widget class="QPushButton" name="mBtnCancel1" > 205 <property name="text" > 206 <string>Cancel</string> 207 </property> 208 </widget> 209 </item> 210 </layout> 211 </item> 212 </layout> 213 </widget> 214 <widget class="QWidget" name="mPageType" > 215 <layout class="QVBoxLayout" > 216 <item> 217 <widget class="QLabel" name="mPageTypeHdr" > 218 <property name="font" > 219 <font> 220 <family>Arial</family> 221 <pointsize>12</pointsize> 222 <weight>75</weight> 223 <bold>true</bold> 224 </font> 225 </property> 226 <property name="text" > 227 <string>Hard Disk Storage Type</string> 228 </property> 229 </widget> 230 </item> 231 <item> 232 <widget class="Line" name="line21" > 233 <property name="orientation" > 234 <enum>Qt::Horizontal</enum> 235 </property> 236 </widget> 237 </item> 238 <item> 239 <layout class="QHBoxLayout" > 240 <property name="spacing" > 241 <number>10</number> 242 </property> 243 <item> 244 <widget class="QLabel" name="mLogoType" > 245 <property name="sizePolicy" > 246 <sizepolicy vsizetype="Minimum" hsizetype="Maximum" > 247 <horstretch>0</horstretch> 248 <verstretch>0</verstretch> 249 </sizepolicy> 250 </property> 251 <property name="autoFillBackground" > 252 <bool>true</bool> 253 </property> 254 <property name="text" > 255 <string/> 256 </property> 257 <property name="pixmap" > 258 <pixmap resource="../VirtualBox1.qrc" >:/vmw_new_harddisk.png</pixmap> 259 </property> 260 <property name="alignment" > 261 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 262 </property> 263 </widget> 264 </item> 265 <item> 266 <layout class="QVBoxLayout" > 267 <property name="spacing" > 268 <number>10</number> 269 </property> 270 <item> 271 <widget class="QILabel" name="mTextType" > 272 <property name="sizePolicy" > 273 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 274 <horstretch>0</horstretch> 275 <verstretch>0</verstretch> 276 </sizepolicy> 277 </property> 278 <property name="minimumSize" > 279 <size> 280 <width>300</width> 281 <height>0</height> 282 </size> 283 </property> 284 <property name="text" > 285 <string><p>Select the type of virtual hard disk you want to create.</p><p>A <b>dynamically expanding storage</b> initially occupies a very small amount of space on your physical hard disk. It will grow dynamically (up to the size specified) as the Guest OS claims disk space.</p><p>A <b>fixed-size storage</b> does not grow. It is stored in a file of approximately the same size as the size of the virtual hard disk. The creation of a fixed-size storage may take a long time depending on the storage size and the write performance of your harddisk.</p></string> 286 </property> 287 <property name="alignment" > 288 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 289 </property> 290 <property name="wordWrap" > 291 <bool>true</bool> 292 </property> 293 </widget> 294 </item> 295 <item> 296 <widget class="QGroupBox" name="mGbType" > 297 <property name="sizePolicy" > 298 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 299 <horstretch>0</horstretch> 300 <verstretch>0</verstretch> 301 </sizepolicy> 302 </property> 303 <property name="title" > 304 <string>Storage Type</string> 305 </property> 306 <layout class="QVBoxLayout" > 307 <property name="topMargin" > 308 <number>4</number> 309 </property> 310 <item> 311 <widget class="QRadioButton" name="mRbDynamicType" > 312 <property name="sizePolicy" > 313 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 314 <horstretch>0</horstretch> 315 <verstretch>0</verstretch> 316 </sizepolicy> 317 </property> 318 <property name="text" > 319 <string>&Dynamically expanding storage</string> 320 </property> 321 <property name="checked" > 322 <bool>true</bool> 323 </property> 324 </widget> 325 </item> 326 <item> 327 <widget class="QRadioButton" name="mRbFixedType" > 328 <property name="sizePolicy" > 329 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 330 <horstretch>0</horstretch> 331 <verstretch>0</verstretch> 332 </sizepolicy> 333 </property> 334 <property name="text" > 335 <string>&Fixed-size storage</string> 336 </property> 337 </widget> 338 </item> 339 </layout> 340 </widget> 341 </item> 342 <item> 343 <spacer> 344 <property name="orientation" > 345 <enum>Qt::Vertical</enum> 346 </property> 347 <property name="sizeHint" > 348 <size> 349 <width>0</width> 350 <height>0</height> 351 </size> 352 </property> 353 </spacer> 354 </item> 355 </layout> 356 </item> 357 </layout> 358 </item> 359 <item> 360 <widget class="Line" name="line22" > 361 <property name="orientation" > 362 <enum>Qt::Horizontal</enum> 363 </property> 364 </widget> 365 </item> 366 <item> 367 <layout class="QHBoxLayout" > 368 <item> 369 <spacer> 370 <property name="orientation" > 371 <enum>Qt::Horizontal</enum> 372 </property> 373 <property name="sizeHint" > 374 <size> 375 <width>0</width> 376 <height>0</height> 377 </size> 378 </property> 379 </spacer> 380 </item> 381 <item> 382 <widget class="QPushButton" name="mBtnBack2" > 383 <property name="text" > 384 <string>< &Back</string> 385 </property> 386 </widget> 387 </item> 388 <item> 389 <widget class="QPushButton" name="mBtnNext2" > 390 <property name="text" > 391 <string>&Next ></string> 392 </property> 393 </widget> 394 </item> 395 <item> 396 <spacer> 397 <property name="orientation" > 398 <enum>Qt::Horizontal</enum> 399 </property> 400 <property name="sizeType" > 401 <enum>QSizePolicy::Fixed</enum> 402 </property> 403 <property name="sizeHint" > 404 <size> 405 <width>5</width> 406 <height>0</height> 407 </size> 408 </property> 409 </spacer> 410 </item> 411 <item> 412 <widget class="QPushButton" name="mBtnCancel2" > 413 <property name="text" > 414 <string>Cancel</string> 415 </property> 416 </widget> 417 </item> 418 </layout> 419 </item> 420 </layout> 421 </widget> 422 <widget class="QWidget" name="mPageNameAndSize" > 423 <layout class="QVBoxLayout" > 424 <item> 425 <widget class="QLabel" name="mPageNameAndSizeHdr" > 426 <property name="font" > 427 <font> 428 <family>Arial</family> 429 <pointsize>12</pointsize> 430 <weight>75</weight> 431 <bold>true</bold> 432 </font> 433 </property> 434 <property name="text" > 435 <string>Virtual Disk Location and Size</string> 436 </property> 437 </widget> 438 </item> 439 <item> 440 <widget class="Line" name="line31" > 441 <property name="orientation" > 442 <enum>Qt::Horizontal</enum> 443 </property> 444 </widget> 445 </item> 446 <item> 447 <layout class="QHBoxLayout" > 448 <property name="spacing" > 449 <number>10</number> 450 </property> 451 <item> 452 <widget class="QLabel" name="mLogoNameAndSize" > 453 <property name="sizePolicy" > 454 <sizepolicy vsizetype="Minimum" hsizetype="Maximum" > 455 <horstretch>0</horstretch> 456 <verstretch>0</verstretch> 457 </sizepolicy> 458 </property> 459 <property name="autoFillBackground" > 460 <bool>true</bool> 461 </property> 462 <property name="text" > 463 <string/> 464 </property> 465 <property name="pixmap" > 466 <pixmap resource="../VirtualBox1.qrc" >:/vmw_new_harddisk.png</pixmap> 467 </property> 468 <property name="alignment" > 469 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 470 </property> 471 </widget> 472 </item> 473 <item> 474 <layout class="QVBoxLayout" > 475 <property name="spacing" > 476 <number>10</number> 477 </property> 478 <item> 479 <widget class="QILabel" name="mTextNameComment" > 480 <property name="sizePolicy" > 481 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 482 <horstretch>0</horstretch> 483 <verstretch>0</verstretch> 484 </sizepolicy> 485 </property> 486 <property name="minimumSize" > 487 <size> 488 <width>300</width> 489 <height>0</height> 490 </size> 491 </property> 492 <property name="text" > 493 <string><p>Press the <b>Select</b> button to select the location of a file to store the hard disk data or type a file name in the entry field.</p></string> 494 </property> 495 <property name="alignment" > 496 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 497 </property> 498 <property name="wordWrap" > 499 <bool>true</bool> 500 </property> 501 </widget> 502 </item> 503 <item> 504 <widget class="QGroupBox" name="mGbName" > 505 <property name="sizePolicy" > 506 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 507 <horstretch>0</horstretch> 508 <verstretch>0</verstretch> 509 </sizepolicy> 510 </property> 511 <property name="title" > 512 <string>&Location</string> 513 </property> 514 <layout class="QHBoxLayout" > 515 <property name="topMargin" > 516 <number>4</number> 517 </property> 518 <item> 519 <widget class="QLineEdit" name="mLeName" /> 520 </item> 521 <item> 522 <widget class="QToolButton" name="mTbNameSelect" > 523 <property name="text" > 524 <string/> 525 </property> 526 <property name="icon" > 527 <iconset resource="../VirtualBox1.qrc" >:/select_file_16px.png</iconset> 528 </property> 529 </widget> 530 </item> 531 </layout> 532 </widget> 533 </item> 534 <item> 535 <widget class="QILabel" name="mTextSizeComment" > 536 <property name="sizePolicy" > 537 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 538 <horstretch>0</horstretch> 539 <verstretch>0</verstretch> 540 </sizepolicy> 541 </property> 542 <property name="minimumSize" > 543 <size> 544 <width>300</width> 545 <height>0</height> 546 </size> 547 </property> 548 <property name="text" > 549 <string><p>Select the size of the virtual hard disk in megabytes. This size will be reported to the Guest OS as the maximum size of this hard disk.</p></string> 550 </property> 551 <property name="alignment" > 552 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 553 </property> 554 <property name="wordWrap" > 555 <bool>true</bool> 556 </property> 557 </widget> 558 </item> 559 <item> 560 <widget class="QGroupBox" name="mGbSize" > 561 <property name="sizePolicy" > 562 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 563 <horstretch>0</horstretch> 564 <verstretch>0</verstretch> 565 </sizepolicy> 566 </property> 567 <property name="title" > 568 <string>&Size</string> 569 </property> 570 <layout class="QGridLayout" > 571 <item row="0" column="0" colspan="3" > 572 <widget class="QSlider" name="mSlSize" > 573 <property name="sizePolicy" > 574 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 575 <horstretch>0</horstretch> 576 <verstretch>0</verstretch> 577 </sizepolicy> 578 </property> 579 <property name="orientation" > 580 <enum>Qt::Horizontal</enum> 581 </property> 582 <property name="tickPosition" > 583 <enum>QSlider::TicksBelow</enum> 584 </property> 585 </widget> 586 </item> 587 <item row="0" column="3" > 588 <widget class="QILineEdit" name="mLeSize" > 589 <property name="sizePolicy" > 590 <sizepolicy vsizetype="Fixed" hsizetype="Maximum" > 591 <horstretch>0</horstretch> 592 <verstretch>0</verstretch> 593 </sizepolicy> 594 </property> 595 </widget> 596 </item> 597 <item row="1" column="0" > 598 <widget class="QLabel" name="mTxSizeMin" > 599 <property name="sizePolicy" > 600 <sizepolicy vsizetype="Preferred" hsizetype="Minimum" > 601 <horstretch>0</horstretch> 602 <verstretch>0</verstretch> 603 </sizepolicy> 604 </property> 605 <property name="alignment" > 606 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 607 </property> 608 </widget> 609 </item> 610 <item row="1" column="1" > 611 <spacer> 612 <property name="orientation" > 613 <enum>Qt::Horizontal</enum> 614 </property> 615 <property name="sizeType" > 616 <enum>QSizePolicy::Expanding</enum> 617 </property> 618 <property name="sizeHint" > 619 <size> 620 <width>221</width> 621 <height>20</height> 622 </size> 623 </property> 624 </spacer> 625 </item> 626 <item row="1" column="2" > 627 <widget class="QLabel" name="mTxSizeMax" > 628 <property name="sizePolicy" > 629 <sizepolicy vsizetype="Preferred" hsizetype="Minimum" > 630 <horstretch>0</horstretch> 631 <verstretch>0</verstretch> 632 </sizepolicy> 633 </property> 634 <property name="alignment" > 635 <set>Qt::AlignRight|Qt::AlignTop|Qt::AlignTrailing</set> 636 </property> 637 </widget> 638 </item> 639 </layout> 640 </widget> 641 </item> 642 <item> 643 <spacer> 644 <property name="orientation" > 645 <enum>Qt::Vertical</enum> 646 </property> 647 <property name="sizeHint" > 648 <size> 649 <width>0</width> 650 <height>0</height> 651 </size> 652 </property> 653 </spacer> 654 </item> 655 </layout> 656 </item> 657 </layout> 658 </item> 659 <item> 660 <widget class="Line" name="line32" > 661 <property name="orientation" > 662 <enum>Qt::Horizontal</enum> 663 </property> 664 </widget> 665 </item> 666 <item> 667 <layout class="QHBoxLayout" > 668 <item> 669 <spacer> 670 <property name="orientation" > 671 <enum>Qt::Horizontal</enum> 672 </property> 673 <property name="sizeHint" > 674 <size> 675 <width>0</width> 676 <height>0</height> 677 </size> 678 </property> 679 </spacer> 680 </item> 681 <item> 682 <widget class="QPushButton" name="mBtnBack3" > 683 <property name="text" > 684 <string>< &Back</string> 685 </property> 686 </widget> 687 </item> 688 <item> 689 <widget class="QPushButton" name="mBtnNext3" > 690 <property name="text" > 691 <string>&Next ></string> 692 </property> 693 </widget> 694 </item> 695 <item> 696 <spacer> 697 <property name="orientation" > 698 <enum>Qt::Horizontal</enum> 699 </property> 700 <property name="sizeType" > 701 <enum>QSizePolicy::Fixed</enum> 702 </property> 703 <property name="sizeHint" > 704 <size> 705 <width>5</width> 706 <height>0</height> 707 </size> 708 </property> 709 </spacer> 710 </item> 711 <item> 712 <widget class="QPushButton" name="mBtnCancel3" > 713 <property name="text" > 714 <string>Cancel</string> 715 </property> 716 </widget> 717 </item> 718 </layout> 719 </item> 720 </layout> 721 </widget> 722 <widget class="QWidget" name="mPageSummary" > 723 <layout class="QVBoxLayout" > 724 <item> 725 <widget class="QLabel" name="mPageSummaryHdr" > 726 <property name="font" > 727 <font> 728 <family>Arial</family> 729 <pointsize>12</pointsize> 730 <weight>75</weight> 731 <bold>true</bold> 732 </font> 733 </property> 734 <property name="text" > 735 <string>Summary</string> 736 </property> 737 </widget> 738 </item> 739 <item> 740 <widget class="Line" name="line41" > 741 <property name="orientation" > 742 <enum>Qt::Horizontal</enum> 743 </property> 744 </widget> 745 </item> 746 <item> 747 <layout class="QHBoxLayout" > 748 <property name="spacing" > 749 <number>10</number> 750 </property> 751 <item> 752 <widget class="QLabel" name="mLogoSummary" > 753 <property name="sizePolicy" > 754 <sizepolicy vsizetype="Minimum" hsizetype="Maximum" > 755 <horstretch>0</horstretch> 756 <verstretch>0</verstretch> 757 </sizepolicy> 758 </property> 759 <property name="autoFillBackground" > 760 <bool>true</bool> 761 </property> 762 <property name="text" > 763 <string/> 764 </property> 765 <property name="pixmap" > 766 <pixmap resource="../VirtualBox1.qrc" >:/vmw_new_harddisk.png</pixmap> 767 </property> 768 <property name="alignment" > 769 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 770 </property> 771 </widget> 772 </item> 773 <item> 774 <layout class="QVBoxLayout" > 775 <property name="spacing" > 776 <number>10</number> 777 </property> 778 <item> 779 <widget class="QILabel" name="mTextSummaryHdr" > 780 <property name="sizePolicy" > 781 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 782 <horstretch>0</horstretch> 783 <verstretch>0</verstretch> 784 </sizepolicy> 785 </property> 786 <property name="minimumSize" > 787 <size> 788 <width>300</width> 789 <height>0</height> 790 </size> 791 </property> 792 <property name="text" > 793 <string>You are going to create a new virtual hard disk with the following parameters:</string> 794 </property> 795 <property name="alignment" > 796 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 797 </property> 798 <property name="wordWrap" > 799 <bool>true</bool> 800 </property> 801 </widget> 802 </item> 803 <item> 804 <widget class="QITextEdit" name="mTeSummary" > 805 <property name="sizePolicy" > 806 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 807 <horstretch>0</horstretch> 808 <verstretch>0</verstretch> 809 </sizepolicy> 810 </property> 811 <property name="minimumSize" > 812 <size> 813 <width>300</width> 814 <height>0</height> 815 </size> 816 </property> 817 <property name="frameShape" > 818 <enum>QFrame::NoFrame</enum> 819 </property> 820 <property name="autoFormatting" > 821 <set>QTextEdit::AutoAll</set> 822 </property> 823 <property name="readOnly" > 824 <bool>true</bool> 825 </property> 826 </widget> 827 </item> 828 <item> 829 <widget class="QILabel" name="mTextSummaryFtr" > 830 <property name="sizePolicy" > 831 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 832 <horstretch>0</horstretch> 833 <verstretch>0</verstretch> 834 </sizepolicy> 835 </property> 836 <property name="minimumSize" > 837 <size> 838 <width>300</width> 839 <height>0</height> 840 </size> 841 </property> 842 <property name="text" > 843 <string>If the above settings are correct, press the <b>Finish</b> button. Once you press it, a new hard disk will be created.</string> 844 </property> 845 <property name="alignment" > 846 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 847 </property> 848 <property name="wordWrap" > 849 <bool>true</bool> 850 </property> 851 </widget> 852 </item> 853 <item> 854 <spacer> 855 <property name="orientation" > 856 <enum>Qt::Vertical</enum> 857 </property> 858 <property name="sizeType" > 859 <enum>QSizePolicy::Expanding</enum> 860 </property> 861 <property name="sizeHint" > 862 <size> 863 <width>0</width> 864 <height>0</height> 865 </size> 866 </property> 867 </spacer> 868 </item> 869 </layout> 870 </item> 871 </layout> 872 </item> 873 <item> 874 <widget class="Line" name="line42" > 875 <property name="orientation" > 876 <enum>Qt::Horizontal</enum> 877 </property> 878 </widget> 879 </item> 880 <item> 881 <layout class="QHBoxLayout" > 882 <item> 883 <spacer> 884 <property name="orientation" > 885 <enum>Qt::Horizontal</enum> 886 </property> 887 <property name="sizeHint" > 888 <size> 889 <width>0</width> 890 <height>0</height> 891 </size> 892 </property> 893 </spacer> 894 </item> 895 <item> 896 <widget class="QPushButton" name="mBtnBack4" > 897 <property name="text" > 898 <string>< &Back</string> 899 </property> 900 </widget> 901 </item> 902 <item> 903 <widget class="QPushButton" name="mBtnFinish" > 904 <property name="text" > 905 <string>&Finish</string> 906 </property> 907 </widget> 908 </item> 909 <item> 910 <spacer> 911 <property name="orientation" > 912 <enum>Qt::Horizontal</enum> 913 </property> 914 <property name="sizeType" > 915 <enum>QSizePolicy::Fixed</enum> 916 </property> 917 <property name="sizeHint" > 918 <size> 919 <width>5</width> 920 <height>0</height> 921 </size> 922 </property> 923 </spacer> 924 </item> 925 <item> 926 <widget class="QPushButton" name="mBtnCancel4" > 927 <property name="text" > 928 <string>Cancel</string> 929 </property> 930 </widget> 931 </item> 932 </layout> 933 </item> 934 </layout> 935 </widget> 45 <property name="wordWrap"> 46 <bool>true</bool> 47 </property> 936 48 </widget> 49 </item> 50 <item> 51 <widget class="QGroupBox" name="m_pTypeCnt"> 52 <property name="title"> 53 <string>Storage Type</string> 54 </property> 55 <layout class="QVBoxLayout" name="m_pLayout2"> 56 <item> 57 <widget class="QRadioButton" name="m_pTypeDynamic"> 58 <property name="text"> 59 <string>&Dynamically expanding storage</string> 60 </property> 61 </widget> 62 </item> 63 <item> 64 <widget class="QRadioButton" name="m_pTypeFixed"> 65 <property name="text"> 66 <string>&Fixed-size storage</string> 67 </property> 68 </widget> 69 </item> 70 </layout> 71 </widget> 72 </item> 73 <item> 74 <spacer name="m_pSpacer1"> 75 <property name="sizeHint" stdset="0"> 76 <size> 77 <width>0</width> 78 <height>0</height> 79 </size> 80 </property> 81 </spacer> 937 82 </item> 938 83 </layout> … … 944 89 <header>QILabel.h</header> 945 90 </customwidget> 946 <customwidget>947 <class>QITextEdit</class>948 <extends>QTextEdit</extends>949 <header>QIAbstractWizard.h</header>950 </customwidget>951 <customwidget>952 <class>QILineEdit</class>953 <extends>QLineEdit</extends>954 <header>QILineEdit.h</header>955 </customwidget>956 91 </customwidgets> 957 <tabstops> 958 <tabstop>mBtnNext1</tabstop> 959 <tabstop>mBtnCancel1</tabstop> 960 <tabstop>mBtnBack2</tabstop> 961 <tabstop>mBtnNext2</tabstop> 962 <tabstop>mBtnCancel2</tabstop> 963 <tabstop>mSlSize</tabstop> 964 <tabstop>mLeSize</tabstop> 965 <tabstop>mBtnBack3</tabstop> 966 <tabstop>mBtnNext3</tabstop> 967 <tabstop>mBtnCancel3</tabstop> 968 <tabstop>mBtnBack4</tabstop> 969 <tabstop>mBtnFinish</tabstop> 970 <tabstop>mBtnCancel4</tabstop> 971 </tabstops> 972 <resources> 973 <include location="../VirtualBox1.qrc" /> 974 </resources> 92 <resources/> 975 93 <connections/> 976 94 </ui> -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/newhd/UINewHDWzdPage3.ui
r25356 r26079 1 <ui version="4.0" > 1 <?xml version="1.0" encoding="UTF-8"?> 2 <ui version="4.0"> 2 3 <comment> 3 4 VBox frontends: Qt4 GUI ("VirtualBox"): 4 5 5 Copyright (C) 200 8Sun Microsystems, Inc.6 Copyright (C) 2009-2010 Sun Microsystems, Inc. 6 7 7 8 This file is part of VirtualBox Open Source Edition (OSE), as … … 17 18 additional information or have any questions. 18 19 </comment> 19 <class> VBoxNewHDWzd</class>20 <widget class="Q Dialog" name="VBoxNewHDWzd">21 <property name="geometry" 20 <class>UINewHDWzdPage3</class> 21 <widget class="QWidget" name="UINewHDWzdPage3"> 22 <property name="geometry"> 22 23 <rect> 23 24 <x>0</x> 24 25 <y>0</y> 25 <width> 506</width>26 <height>4 13</height>26 <width>600</width> 27 <height>400</height> 27 28 </rect> 28 29 </property> 29 <property name="windowTitle" > 30 <string>Create New Virtual Disk</string> 30 <property name="sizePolicy"> 31 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 32 <horstretch>0</horstretch> 33 <verstretch>0</verstretch> 34 </sizepolicy> 31 35 </property> 32 <layout class="QVBoxLayout" > 33 <property name="leftMargin" > 34 <number>0</number> 35 </property> 36 <property name="topMargin" > 37 <number>0</number> 38 </property> 39 <property name="rightMargin" > 40 <number>0</number> 41 </property> 36 <layout class="QVBoxLayout" name="m_pLayout1"> 42 37 <property name="bottomMargin" > 43 38 <number>0</number> 44 39 </property> 45 40 <item> 46 <widget class="Q StackedWidget" name="mPageStack">47 <property name=" currentIndex">48 < number>0</number>41 <widget class="QILabel" name="m_pPage3Text1"> 42 <property name="text"> 43 <string><p>Press the <b>Select</b> button to select the location of a file to store the hard disk data or type a file name in the entry field.</p></string> 49 44 </property> 50 <widget class="QWidget" name="mPageWelcome" > 51 <layout class="QVBoxLayout" > 52 <item> 53 <widget class="QLabel" name="mPageWelcomeHdr" > 54 <property name="font" > 55 <font> 56 <family>Arial</family> 57 <pointsize>12</pointsize> 58 <weight>75</weight> 59 <bold>true</bold> 60 </font> 61 </property> 62 <property name="text" > 63 <string>Welcome to the Create New Virtual Disk Wizard!</string> 64 </property> 65 </widget> 66 </item> 67 <item> 68 <widget class="Line" name="line11" > 69 <property name="orientation" > 70 <enum>Qt::Horizontal</enum> 71 </property> 72 </widget> 73 </item> 74 <item> 75 <layout class="QHBoxLayout" > 76 <property name="spacing" > 77 <number>10</number> 78 </property> 79 <item> 80 <widget class="QLabel" name="mLogoWelcome" > 81 <property name="sizePolicy" > 82 <sizepolicy vsizetype="Minimum" hsizetype="Maximum" > 83 <horstretch>0</horstretch> 84 <verstretch>0</verstretch> 85 </sizepolicy> 86 </property> 87 <property name="autoFillBackground" > 88 <bool>true</bool> 89 </property> 90 <property name="text" > 91 <string/> 92 </property> 93 <property name="pixmap" > 94 <pixmap resource="../VirtualBox1.qrc" >:/vmw_new_harddisk.png</pixmap> 95 </property> 96 <property name="alignment" > 97 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 98 </property> 99 </widget> 100 </item> 101 <item> 102 <layout class="QVBoxLayout" > 103 <property name="spacing" > 104 <number>10</number> 105 </property> 106 <item> 107 <widget class="QILabel" name="mTextWelcome" > 108 <property name="sizePolicy" > 109 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 110 <horstretch>0</horstretch> 111 <verstretch>0</verstretch> 112 </sizepolicy> 113 </property> 114 <property name="minimumSize" > 115 <size> 116 <width>300</width> 117 <height>0</height> 118 </size> 119 </property> 120 <property name="text" > 121 <string><p>This wizard will help you to create a new virtual hard disk for your virtual machine.</p><p>Use the <b>Next</b> button to go to the next page of the wizard and the <b>Back</b> button to return to the previous page.</p></string> 122 </property> 123 <property name="alignment" > 124 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 125 </property> 126 <property name="wordWrap" > 127 <bool>true</bool> 128 </property> 129 </widget> 130 </item> 131 <item> 132 <spacer> 133 <property name="orientation" > 134 <enum>Qt::Vertical</enum> 135 </property> 136 <property name="sizeHint" > 137 <size> 138 <width>0</width> 139 <height>0</height> 140 </size> 141 </property> 142 </spacer> 143 </item> 144 </layout> 145 </item> 146 </layout> 147 </item> 148 <item> 149 <widget class="Line" name="line12" > 150 <property name="orientation" > 151 <enum>Qt::Horizontal</enum> 152 </property> 153 </widget> 154 </item> 155 <item> 156 <layout class="QHBoxLayout" > 157 <item> 158 <spacer> 159 <property name="orientation" > 160 <enum>Qt::Horizontal</enum> 161 </property> 162 <property name="sizeHint" > 163 <size> 164 <width>0</width> 165 <height>0</height> 166 </size> 167 </property> 168 </spacer> 169 </item> 170 <item> 171 <widget class="QPushButton" name="mBtnBack1" > 172 <property name="enabled" > 173 <bool>false</bool> 174 </property> 175 <property name="text" > 176 <string>< &Back</string> 177 </property> 178 </widget> 179 </item> 180 <item> 181 <widget class="QPushButton" name="mBtnNext1" > 182 <property name="text" > 183 <string>&Next ></string> 184 </property> 185 </widget> 186 </item> 187 <item> 188 <spacer> 189 <property name="orientation" > 190 <enum>Qt::Horizontal</enum> 191 </property> 192 <property name="sizeType" > 193 <enum>QSizePolicy::Fixed</enum> 194 </property> 195 <property name="sizeHint" > 196 <size> 197 <width>5</width> 198 <height>0</height> 199 </size> 200 </property> 201 </spacer> 202 </item> 203 <item> 204 <widget class="QPushButton" name="mBtnCancel1" > 205 <property name="text" > 206 <string>Cancel</string> 207 </property> 208 </widget> 209 </item> 210 </layout> 211 </item> 212 </layout> 213 </widget> 214 <widget class="QWidget" name="mPageType" > 215 <layout class="QVBoxLayout" > 216 <item> 217 <widget class="QLabel" name="mPageTypeHdr" > 218 <property name="font" > 219 <font> 220 <family>Arial</family> 221 <pointsize>12</pointsize> 222 <weight>75</weight> 223 <bold>true</bold> 224 </font> 225 </property> 226 <property name="text" > 227 <string>Hard Disk Storage Type</string> 228 </property> 229 </widget> 230 </item> 231 <item> 232 <widget class="Line" name="line21" > 233 <property name="orientation" > 234 <enum>Qt::Horizontal</enum> 235 </property> 236 </widget> 237 </item> 238 <item> 239 <layout class="QHBoxLayout" > 240 <property name="spacing" > 241 <number>10</number> 242 </property> 243 <item> 244 <widget class="QLabel" name="mLogoType" > 245 <property name="sizePolicy" > 246 <sizepolicy vsizetype="Minimum" hsizetype="Maximum" > 247 <horstretch>0</horstretch> 248 <verstretch>0</verstretch> 249 </sizepolicy> 250 </property> 251 <property name="autoFillBackground" > 252 <bool>true</bool> 253 </property> 254 <property name="text" > 255 <string/> 256 </property> 257 <property name="pixmap" > 258 <pixmap resource="../VirtualBox1.qrc" >:/vmw_new_harddisk.png</pixmap> 259 </property> 260 <property name="alignment" > 261 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 262 </property> 263 </widget> 264 </item> 265 <item> 266 <layout class="QVBoxLayout" > 267 <property name="spacing" > 268 <number>10</number> 269 </property> 270 <item> 271 <widget class="QILabel" name="mTextType" > 272 <property name="sizePolicy" > 273 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 274 <horstretch>0</horstretch> 275 <verstretch>0</verstretch> 276 </sizepolicy> 277 </property> 278 <property name="minimumSize" > 279 <size> 280 <width>300</width> 281 <height>0</height> 282 </size> 283 </property> 284 <property name="text" > 285 <string><p>Select the type of virtual hard disk you want to create.</p><p>A <b>dynamically expanding storage</b> initially occupies a very small amount of space on your physical hard disk. It will grow dynamically (up to the size specified) as the Guest OS claims disk space.</p><p>A <b>fixed-size storage</b> does not grow. It is stored in a file of approximately the same size as the size of the virtual hard disk. The creation of a fixed-size storage may take a long time depending on the storage size and the write performance of your harddisk.</p></string> 286 </property> 287 <property name="alignment" > 288 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 289 </property> 290 <property name="wordWrap" > 291 <bool>true</bool> 292 </property> 293 </widget> 294 </item> 295 <item> 296 <widget class="QGroupBox" name="mGbType" > 297 <property name="sizePolicy" > 298 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 299 <horstretch>0</horstretch> 300 <verstretch>0</verstretch> 301 </sizepolicy> 302 </property> 303 <property name="title" > 304 <string>Storage Type</string> 305 </property> 306 <layout class="QVBoxLayout" > 307 <property name="topMargin" > 308 <number>4</number> 309 </property> 310 <item> 311 <widget class="QRadioButton" name="mRbDynamicType" > 312 <property name="sizePolicy" > 313 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 314 <horstretch>0</horstretch> 315 <verstretch>0</verstretch> 316 </sizepolicy> 317 </property> 318 <property name="text" > 319 <string>&Dynamically expanding storage</string> 320 </property> 321 <property name="checked" > 322 <bool>true</bool> 323 </property> 324 </widget> 325 </item> 326 <item> 327 <widget class="QRadioButton" name="mRbFixedType" > 328 <property name="sizePolicy" > 329 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 330 <horstretch>0</horstretch> 331 <verstretch>0</verstretch> 332 </sizepolicy> 333 </property> 334 <property name="text" > 335 <string>&Fixed-size storage</string> 336 </property> 337 </widget> 338 </item> 339 </layout> 340 </widget> 341 </item> 342 <item> 343 <spacer> 344 <property name="orientation" > 345 <enum>Qt::Vertical</enum> 346 </property> 347 <property name="sizeHint" > 348 <size> 349 <width>0</width> 350 <height>0</height> 351 </size> 352 </property> 353 </spacer> 354 </item> 355 </layout> 356 </item> 357 </layout> 358 </item> 359 <item> 360 <widget class="Line" name="line22" > 361 <property name="orientation" > 362 <enum>Qt::Horizontal</enum> 363 </property> 364 </widget> 365 </item> 366 <item> 367 <layout class="QHBoxLayout" > 368 <item> 369 <spacer> 370 <property name="orientation" > 371 <enum>Qt::Horizontal</enum> 372 </property> 373 <property name="sizeHint" > 374 <size> 375 <width>0</width> 376 <height>0</height> 377 </size> 378 </property> 379 </spacer> 380 </item> 381 <item> 382 <widget class="QPushButton" name="mBtnBack2" > 383 <property name="text" > 384 <string>< &Back</string> 385 </property> 386 </widget> 387 </item> 388 <item> 389 <widget class="QPushButton" name="mBtnNext2" > 390 <property name="text" > 391 <string>&Next ></string> 392 </property> 393 </widget> 394 </item> 395 <item> 396 <spacer> 397 <property name="orientation" > 398 <enum>Qt::Horizontal</enum> 399 </property> 400 <property name="sizeType" > 401 <enum>QSizePolicy::Fixed</enum> 402 </property> 403 <property name="sizeHint" > 404 <size> 405 <width>5</width> 406 <height>0</height> 407 </size> 408 </property> 409 </spacer> 410 </item> 411 <item> 412 <widget class="QPushButton" name="mBtnCancel2" > 413 <property name="text" > 414 <string>Cancel</string> 415 </property> 416 </widget> 417 </item> 418 </layout> 419 </item> 420 </layout> 421 </widget> 422 <widget class="QWidget" name="mPageNameAndSize" > 423 <layout class="QVBoxLayout" > 424 <item> 425 <widget class="QLabel" name="mPageNameAndSizeHdr" > 426 <property name="font" > 427 <font> 428 <family>Arial</family> 429 <pointsize>12</pointsize> 430 <weight>75</weight> 431 <bold>true</bold> 432 </font> 433 </property> 434 <property name="text" > 435 <string>Virtual Disk Location and Size</string> 436 </property> 437 </widget> 438 </item> 439 <item> 440 <widget class="Line" name="line31" > 441 <property name="orientation" > 442 <enum>Qt::Horizontal</enum> 443 </property> 444 </widget> 445 </item> 446 <item> 447 <layout class="QHBoxLayout" > 448 <property name="spacing" > 449 <number>10</number> 450 </property> 451 <item> 452 <widget class="QLabel" name="mLogoNameAndSize" > 453 <property name="sizePolicy" > 454 <sizepolicy vsizetype="Minimum" hsizetype="Maximum" > 455 <horstretch>0</horstretch> 456 <verstretch>0</verstretch> 457 </sizepolicy> 458 </property> 459 <property name="autoFillBackground" > 460 <bool>true</bool> 461 </property> 462 <property name="text" > 463 <string/> 464 </property> 465 <property name="pixmap" > 466 <pixmap resource="../VirtualBox1.qrc" >:/vmw_new_harddisk.png</pixmap> 467 </property> 468 <property name="alignment" > 469 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 470 </property> 471 </widget> 472 </item> 473 <item> 474 <layout class="QVBoxLayout" > 475 <property name="spacing" > 476 <number>10</number> 477 </property> 478 <item> 479 <widget class="QILabel" name="mTextNameComment" > 480 <property name="sizePolicy" > 481 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 482 <horstretch>0</horstretch> 483 <verstretch>0</verstretch> 484 </sizepolicy> 485 </property> 486 <property name="minimumSize" > 487 <size> 488 <width>300</width> 489 <height>0</height> 490 </size> 491 </property> 492 <property name="text" > 493 <string><p>Press the <b>Select</b> button to select the location of a file to store the hard disk data or type a file name in the entry field.</p></string> 494 </property> 495 <property name="alignment" > 496 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 497 </property> 498 <property name="wordWrap" > 499 <bool>true</bool> 500 </property> 501 </widget> 502 </item> 503 <item> 504 <widget class="QGroupBox" name="mGbName" > 505 <property name="sizePolicy" > 506 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 507 <horstretch>0</horstretch> 508 <verstretch>0</verstretch> 509 </sizepolicy> 510 </property> 511 <property name="title" > 512 <string>&Location</string> 513 </property> 514 <layout class="QHBoxLayout" > 515 <property name="topMargin" > 516 <number>4</number> 517 </property> 518 <item> 519 <widget class="QLineEdit" name="mLeName" /> 520 </item> 521 <item> 522 <widget class="QToolButton" name="mTbNameSelect" > 523 <property name="text" > 524 <string/> 525 </property> 526 <property name="icon" > 527 <iconset resource="../VirtualBox1.qrc" >:/select_file_16px.png</iconset> 528 </property> 529 </widget> 530 </item> 531 </layout> 532 </widget> 533 </item> 534 <item> 535 <widget class="QILabel" name="mTextSizeComment" > 536 <property name="sizePolicy" > 537 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 538 <horstretch>0</horstretch> 539 <verstretch>0</verstretch> 540 </sizepolicy> 541 </property> 542 <property name="minimumSize" > 543 <size> 544 <width>300</width> 545 <height>0</height> 546 </size> 547 </property> 548 <property name="text" > 549 <string><p>Select the size of the virtual hard disk in megabytes. This size will be reported to the Guest OS as the maximum size of this hard disk.</p></string> 550 </property> 551 <property name="alignment" > 552 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 553 </property> 554 <property name="wordWrap" > 555 <bool>true</bool> 556 </property> 557 </widget> 558 </item> 559 <item> 560 <widget class="QGroupBox" name="mGbSize" > 561 <property name="sizePolicy" > 562 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 563 <horstretch>0</horstretch> 564 <verstretch>0</verstretch> 565 </sizepolicy> 566 </property> 567 <property name="title" > 568 <string>&Size</string> 569 </property> 570 <layout class="QGridLayout" > 571 <item row="0" column="0" colspan="3" > 572 <widget class="QSlider" name="mSlSize" > 573 <property name="sizePolicy" > 574 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 575 <horstretch>0</horstretch> 576 <verstretch>0</verstretch> 577 </sizepolicy> 578 </property> 579 <property name="orientation" > 580 <enum>Qt::Horizontal</enum> 581 </property> 582 <property name="tickPosition" > 583 <enum>QSlider::TicksBelow</enum> 584 </property> 585 </widget> 586 </item> 587 <item row="0" column="3" > 588 <widget class="QILineEdit" name="mLeSize" > 589 <property name="sizePolicy" > 590 <sizepolicy vsizetype="Fixed" hsizetype="Maximum" > 591 <horstretch>0</horstretch> 592 <verstretch>0</verstretch> 593 </sizepolicy> 594 </property> 595 </widget> 596 </item> 597 <item row="1" column="0" > 598 <widget class="QLabel" name="mTxSizeMin" > 599 <property name="sizePolicy" > 600 <sizepolicy vsizetype="Preferred" hsizetype="Minimum" > 601 <horstretch>0</horstretch> 602 <verstretch>0</verstretch> 603 </sizepolicy> 604 </property> 605 <property name="alignment" > 606 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 607 </property> 608 </widget> 609 </item> 610 <item row="1" column="1" > 611 <spacer> 612 <property name="orientation" > 613 <enum>Qt::Horizontal</enum> 614 </property> 615 <property name="sizeType" > 616 <enum>QSizePolicy::Expanding</enum> 617 </property> 618 <property name="sizeHint" > 619 <size> 620 <width>221</width> 621 <height>20</height> 622 </size> 623 </property> 624 </spacer> 625 </item> 626 <item row="1" column="2" > 627 <widget class="QLabel" name="mTxSizeMax" > 628 <property name="sizePolicy" > 629 <sizepolicy vsizetype="Preferred" hsizetype="Minimum" > 630 <horstretch>0</horstretch> 631 <verstretch>0</verstretch> 632 </sizepolicy> 633 </property> 634 <property name="alignment" > 635 <set>Qt::AlignRight|Qt::AlignTop|Qt::AlignTrailing</set> 636 </property> 637 </widget> 638 </item> 639 </layout> 640 </widget> 641 </item> 642 <item> 643 <spacer> 644 <property name="orientation" > 645 <enum>Qt::Vertical</enum> 646 </property> 647 <property name="sizeHint" > 648 <size> 649 <width>0</width> 650 <height>0</height> 651 </size> 652 </property> 653 </spacer> 654 </item> 655 </layout> 656 </item> 657 </layout> 658 </item> 659 <item> 660 <widget class="Line" name="line32" > 661 <property name="orientation" > 662 <enum>Qt::Horizontal</enum> 663 </property> 664 </widget> 665 </item> 666 <item> 667 <layout class="QHBoxLayout" > 668 <item> 669 <spacer> 670 <property name="orientation" > 671 <enum>Qt::Horizontal</enum> 672 </property> 673 <property name="sizeHint" > 674 <size> 675 <width>0</width> 676 <height>0</height> 677 </size> 678 </property> 679 </spacer> 680 </item> 681 <item> 682 <widget class="QPushButton" name="mBtnBack3" > 683 <property name="text" > 684 <string>< &Back</string> 685 </property> 686 </widget> 687 </item> 688 <item> 689 <widget class="QPushButton" name="mBtnNext3" > 690 <property name="text" > 691 <string>&Next ></string> 692 </property> 693 </widget> 694 </item> 695 <item> 696 <spacer> 697 <property name="orientation" > 698 <enum>Qt::Horizontal</enum> 699 </property> 700 <property name="sizeType" > 701 <enum>QSizePolicy::Fixed</enum> 702 </property> 703 <property name="sizeHint" > 704 <size> 705 <width>5</width> 706 <height>0</height> 707 </size> 708 </property> 709 </spacer> 710 </item> 711 <item> 712 <widget class="QPushButton" name="mBtnCancel3" > 713 <property name="text" > 714 <string>Cancel</string> 715 </property> 716 </widget> 717 </item> 718 </layout> 719 </item> 720 </layout> 721 </widget> 722 <widget class="QWidget" name="mPageSummary" > 723 <layout class="QVBoxLayout" > 724 <item> 725 <widget class="QLabel" name="mPageSummaryHdr" > 726 <property name="font" > 727 <font> 728 <family>Arial</family> 729 <pointsize>12</pointsize> 730 <weight>75</weight> 731 <bold>true</bold> 732 </font> 733 </property> 734 <property name="text" > 735 <string>Summary</string> 736 </property> 737 </widget> 738 </item> 739 <item> 740 <widget class="Line" name="line41" > 741 <property name="orientation" > 742 <enum>Qt::Horizontal</enum> 743 </property> 744 </widget> 745 </item> 746 <item> 747 <layout class="QHBoxLayout" > 748 <property name="spacing" > 749 <number>10</number> 750 </property> 751 <item> 752 <widget class="QLabel" name="mLogoSummary" > 753 <property name="sizePolicy" > 754 <sizepolicy vsizetype="Minimum" hsizetype="Maximum" > 755 <horstretch>0</horstretch> 756 <verstretch>0</verstretch> 757 </sizepolicy> 758 </property> 759 <property name="autoFillBackground" > 760 <bool>true</bool> 761 </property> 762 <property name="text" > 763 <string/> 764 </property> 765 <property name="pixmap" > 766 <pixmap resource="../VirtualBox1.qrc" >:/vmw_new_harddisk.png</pixmap> 767 </property> 768 <property name="alignment" > 769 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 770 </property> 771 </widget> 772 </item> 773 <item> 774 <layout class="QVBoxLayout" > 775 <property name="spacing" > 776 <number>10</number> 777 </property> 778 <item> 779 <widget class="QILabel" name="mTextSummaryHdr" > 780 <property name="sizePolicy" > 781 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 782 <horstretch>0</horstretch> 783 <verstretch>0</verstretch> 784 </sizepolicy> 785 </property> 786 <property name="minimumSize" > 787 <size> 788 <width>300</width> 789 <height>0</height> 790 </size> 791 </property> 792 <property name="text" > 793 <string>You are going to create a new virtual hard disk with the following parameters:</string> 794 </property> 795 <property name="alignment" > 796 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 797 </property> 798 <property name="wordWrap" > 799 <bool>true</bool> 800 </property> 801 </widget> 802 </item> 803 <item> 804 <widget class="QITextEdit" name="mTeSummary" > 805 <property name="sizePolicy" > 806 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 807 <horstretch>0</horstretch> 808 <verstretch>0</verstretch> 809 </sizepolicy> 810 </property> 811 <property name="minimumSize" > 812 <size> 813 <width>300</width> 814 <height>0</height> 815 </size> 816 </property> 817 <property name="frameShape" > 818 <enum>QFrame::NoFrame</enum> 819 </property> 820 <property name="autoFormatting" > 821 <set>QTextEdit::AutoAll</set> 822 </property> 823 <property name="readOnly" > 824 <bool>true</bool> 825 </property> 826 </widget> 827 </item> 828 <item> 829 <widget class="QILabel" name="mTextSummaryFtr" > 830 <property name="sizePolicy" > 831 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 832 <horstretch>0</horstretch> 833 <verstretch>0</verstretch> 834 </sizepolicy> 835 </property> 836 <property name="minimumSize" > 837 <size> 838 <width>300</width> 839 <height>0</height> 840 </size> 841 </property> 842 <property name="text" > 843 <string>If the above settings are correct, press the <b>Finish</b> button. Once you press it, a new hard disk will be created.</string> 844 </property> 845 <property name="alignment" > 846 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 847 </property> 848 <property name="wordWrap" > 849 <bool>true</bool> 850 </property> 851 </widget> 852 </item> 853 <item> 854 <spacer> 855 <property name="orientation" > 856 <enum>Qt::Vertical</enum> 857 </property> 858 <property name="sizeType" > 859 <enum>QSizePolicy::Expanding</enum> 860 </property> 861 <property name="sizeHint" > 862 <size> 863 <width>0</width> 864 <height>0</height> 865 </size> 866 </property> 867 </spacer> 868 </item> 869 </layout> 870 </item> 871 </layout> 872 </item> 873 <item> 874 <widget class="Line" name="line42" > 875 <property name="orientation" > 876 <enum>Qt::Horizontal</enum> 877 </property> 878 </widget> 879 </item> 880 <item> 881 <layout class="QHBoxLayout" > 882 <item> 883 <spacer> 884 <property name="orientation" > 885 <enum>Qt::Horizontal</enum> 886 </property> 887 <property name="sizeHint" > 888 <size> 889 <width>0</width> 890 <height>0</height> 891 </size> 892 </property> 893 </spacer> 894 </item> 895 <item> 896 <widget class="QPushButton" name="mBtnBack4" > 897 <property name="text" > 898 <string>< &Back</string> 899 </property> 900 </widget> 901 </item> 902 <item> 903 <widget class="QPushButton" name="mBtnFinish" > 904 <property name="text" > 905 <string>&Finish</string> 906 </property> 907 </widget> 908 </item> 909 <item> 910 <spacer> 911 <property name="orientation" > 912 <enum>Qt::Horizontal</enum> 913 </property> 914 <property name="sizeType" > 915 <enum>QSizePolicy::Fixed</enum> 916 </property> 917 <property name="sizeHint" > 918 <size> 919 <width>5</width> 920 <height>0</height> 921 </size> 922 </property> 923 </spacer> 924 </item> 925 <item> 926 <widget class="QPushButton" name="mBtnCancel4" > 927 <property name="text" > 928 <string>Cancel</string> 929 </property> 930 </widget> 931 </item> 932 </layout> 933 </item> 934 </layout> 935 </widget> 45 <property name="wordWrap"> 46 <bool>true</bool> 47 </property> 936 48 </widget> 49 </item> 50 <item> 51 <widget class="QGroupBox" name="m_pLocationCnt"> 52 <property name="title"> 53 <string>&Location</string> 54 </property> 55 <layout class="QHBoxLayout" name="m_pLayout2"> 56 <item> 57 <widget class="QLineEdit" name="m_pLocationEditor"/> 58 </item> 59 <item> 60 <widget class="QToolButton" name="m_pLocationSelector"> 61 <property name="autoRaise"> 62 <bool>true</bool> 63 </property> 64 </widget> 65 </item> 66 </layout> 67 </widget> 68 </item> 69 <item> 70 <widget class="QILabel" name="m_pPage3Text2"> 71 <property name="text"> 72 <string><p>Select the size of the virtual hard disk in megabytes. This size will be reported to the Guest OS as the maximum size of this hard disk.</p></string> 73 </property> 74 <property name="wordWrap"> 75 <bool>true</bool> 76 </property> 77 </widget> 78 </item> 79 <item> 80 <widget class="QGroupBox" name="m_pSizeCnt"> 81 <property name="title"> 82 <string>&Size</string> 83 </property> 84 <layout class="QGridLayout" name="m_pLayout3"> 85 <item row="0" column="0" colspan="3"> 86 <widget class="QSlider" name="m_pSizeSlider"> 87 <property name="sizePolicy"> 88 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 89 <horstretch>0</horstretch> 90 <verstretch>0</verstretch> 91 </sizepolicy> 92 </property> 93 <property name="orientation"> 94 <enum>Qt::Horizontal</enum> 95 </property> 96 <property name="tickPosition"> 97 <enum>QSlider::TicksBelow</enum> 98 </property> 99 </widget> 100 </item> 101 <item row="0" column="3"> 102 <widget class="QILineEdit" name="m_pSizeEditor"> 103 <property name="sizePolicy"> 104 <sizepolicy hsizetype="Preferred" vsizetype="Fixed"> 105 <horstretch>0</horstretch> 106 <verstretch>0</verstretch> 107 </sizepolicy> 108 </property> 109 </widget> 110 </item> 111 <item row="1" column="0"> 112 <widget class="QLabel" name="m_pSizeMin"> 113 <property name="sizePolicy"> 114 <sizepolicy hsizetype="Maximum" vsizetype="Preferred"> 115 <horstretch>0</horstretch> 116 <verstretch>0</verstretch> 117 </sizepolicy> 118 </property> 119 </widget> 120 </item> 121 <item row="1" column="1"> 122 <spacer name="m_pSpacer1"> 123 <property name="orientation"> 124 <enum>Qt::Horizontal</enum> 125 </property> 126 <property name="sizeHint" stdset="0"> 127 <size> 128 <width>0</width> 129 <height>0</height> 130 </size> 131 </property> 132 </spacer> 133 </item> 134 <item row="1" column="2"> 135 <widget class="QLabel" name="m_pSizeMax"> 136 <property name="sizePolicy"> 137 <sizepolicy hsizetype="Maximum" vsizetype="Preferred"> 138 <horstretch>0</horstretch> 139 <verstretch>0</verstretch> 140 </sizepolicy> 141 </property> 142 </widget> 143 </item> 144 </layout> 145 </widget> 146 </item> 147 <item> 148 <spacer name="m_pSpacer2"> 149 <property name="sizeHint" stdset="0"> 150 <size> 151 <width>0</width> 152 <height>0</height> 153 </size> 154 </property> 155 </spacer> 937 156 </item> 938 157 </layout> … … 945 164 </customwidget> 946 165 <customwidget> 947 <class>QITextEdit</class>948 <extends>QTextEdit</extends>949 <header>QIAbstractWizard.h</header>950 </customwidget>951 <customwidget>952 166 <class>QILineEdit</class> 953 167 <extends>QLineEdit</extends> … … 955 169 </customwidget> 956 170 </customwidgets> 957 <tabstops> 958 <tabstop>mBtnNext1</tabstop> 959 <tabstop>mBtnCancel1</tabstop> 960 <tabstop>mBtnBack2</tabstop> 961 <tabstop>mBtnNext2</tabstop> 962 <tabstop>mBtnCancel2</tabstop> 963 <tabstop>mSlSize</tabstop> 964 <tabstop>mLeSize</tabstop> 965 <tabstop>mBtnBack3</tabstop> 966 <tabstop>mBtnNext3</tabstop> 967 <tabstop>mBtnCancel3</tabstop> 968 <tabstop>mBtnBack4</tabstop> 969 <tabstop>mBtnFinish</tabstop> 970 <tabstop>mBtnCancel4</tabstop> 971 </tabstops> 972 <resources> 973 <include location="../VirtualBox1.qrc" /> 974 </resources> 171 <resources/> 975 172 <connections/> 976 173 </ui> -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/newhd/UINewHDWzdPage4.ui
r25356 r26079 1 <ui version="4.0" > 1 <?xml version="1.0" encoding="UTF-8"?> 2 <ui version="4.0"> 2 3 <comment> 3 4 VBox frontends: Qt4 GUI ("VirtualBox"): 4 5 5 Copyright (C) 200 8Sun Microsystems, Inc.6 Copyright (C) 2009-2010 Sun Microsystems, Inc. 6 7 7 8 This file is part of VirtualBox Open Source Edition (OSE), as … … 17 18 additional information or have any questions. 18 19 </comment> 19 <class> VBoxNewHDWzd</class>20 <widget class="Q Dialog" name="VBoxNewHDWzd">21 <property name="geometry" 20 <class>UINewHDWzdPage4</class> 21 <widget class="QWidget" name="UINewHDWzdPage4"> 22 <property name="geometry"> 22 23 <rect> 23 24 <x>0</x> 24 25 <y>0</y> 25 <width> 506</width>26 <height>4 13</height>26 <width>600</width> 27 <height>400</height> 27 28 </rect> 28 29 </property> 29 <property name="windowTitle" > 30 <string>Create New Virtual Disk</string> 30 <property name="sizePolicy"> 31 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 32 <horstretch>0</horstretch> 33 <verstretch>0</verstretch> 34 </sizepolicy> 31 35 </property> 32 <layout class="QVBoxLayout" > 33 <property name="leftMargin" > 34 <number>0</number> 35 </property> 36 <property name="topMargin" > 37 <number>0</number> 38 </property> 39 <property name="rightMargin" > 40 <number>0</number> 41 </property> 36 <layout class="QVBoxLayout" name="m_pLayout1"> 42 37 <property name="bottomMargin" > 43 38 <number>0</number> 44 39 </property> 45 40 <item> 46 <widget class="Q StackedWidget" name="mPageStack">47 <property name=" currentIndex">48 < number>0</number>41 <widget class="QILabel" name="m_pPage4Text1"> 42 <property name="text"> 43 <string>You are going to create a new virtual hard disk with the following parameters:</string> 49 44 </property> 50 <widget class="QWidget" name="mPageWelcome" > 51 <layout class="QVBoxLayout" > 52 <item> 53 <widget class="QLabel" name="mPageWelcomeHdr" > 54 <property name="font" > 55 <font> 56 <family>Arial</family> 57 <pointsize>12</pointsize> 58 <weight>75</weight> 59 <bold>true</bold> 60 </font> 61 </property> 62 <property name="text" > 63 <string>Welcome to the Create New Virtual Disk Wizard!</string> 64 </property> 65 </widget> 66 </item> 67 <item> 68 <widget class="Line" name="line11" > 69 <property name="orientation" > 70 <enum>Qt::Horizontal</enum> 71 </property> 72 </widget> 73 </item> 74 <item> 75 <layout class="QHBoxLayout" > 76 <property name="spacing" > 77 <number>10</number> 78 </property> 79 <item> 80 <widget class="QLabel" name="mLogoWelcome" > 81 <property name="sizePolicy" > 82 <sizepolicy vsizetype="Minimum" hsizetype="Maximum" > 83 <horstretch>0</horstretch> 84 <verstretch>0</verstretch> 85 </sizepolicy> 86 </property> 87 <property name="autoFillBackground" > 88 <bool>true</bool> 89 </property> 90 <property name="text" > 91 <string/> 92 </property> 93 <property name="pixmap" > 94 <pixmap resource="../VirtualBox1.qrc" >:/vmw_new_harddisk.png</pixmap> 95 </property> 96 <property name="alignment" > 97 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 98 </property> 99 </widget> 100 </item> 101 <item> 102 <layout class="QVBoxLayout" > 103 <property name="spacing" > 104 <number>10</number> 105 </property> 106 <item> 107 <widget class="QILabel" name="mTextWelcome" > 108 <property name="sizePolicy" > 109 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 110 <horstretch>0</horstretch> 111 <verstretch>0</verstretch> 112 </sizepolicy> 113 </property> 114 <property name="minimumSize" > 115 <size> 116 <width>300</width> 117 <height>0</height> 118 </size> 119 </property> 120 <property name="text" > 121 <string><p>This wizard will help you to create a new virtual hard disk for your virtual machine.</p><p>Use the <b>Next</b> button to go to the next page of the wizard and the <b>Back</b> button to return to the previous page.</p></string> 122 </property> 123 <property name="alignment" > 124 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 125 </property> 126 <property name="wordWrap" > 127 <bool>true</bool> 128 </property> 129 </widget> 130 </item> 131 <item> 132 <spacer> 133 <property name="orientation" > 134 <enum>Qt::Vertical</enum> 135 </property> 136 <property name="sizeHint" > 137 <size> 138 <width>0</width> 139 <height>0</height> 140 </size> 141 </property> 142 </spacer> 143 </item> 144 </layout> 145 </item> 146 </layout> 147 </item> 148 <item> 149 <widget class="Line" name="line12" > 150 <property name="orientation" > 151 <enum>Qt::Horizontal</enum> 152 </property> 153 </widget> 154 </item> 155 <item> 156 <layout class="QHBoxLayout" > 157 <item> 158 <spacer> 159 <property name="orientation" > 160 <enum>Qt::Horizontal</enum> 161 </property> 162 <property name="sizeHint" > 163 <size> 164 <width>0</width> 165 <height>0</height> 166 </size> 167 </property> 168 </spacer> 169 </item> 170 <item> 171 <widget class="QPushButton" name="mBtnBack1" > 172 <property name="enabled" > 173 <bool>false</bool> 174 </property> 175 <property name="text" > 176 <string>< &Back</string> 177 </property> 178 </widget> 179 </item> 180 <item> 181 <widget class="QPushButton" name="mBtnNext1" > 182 <property name="text" > 183 <string>&Next ></string> 184 </property> 185 </widget> 186 </item> 187 <item> 188 <spacer> 189 <property name="orientation" > 190 <enum>Qt::Horizontal</enum> 191 </property> 192 <property name="sizeType" > 193 <enum>QSizePolicy::Fixed</enum> 194 </property> 195 <property name="sizeHint" > 196 <size> 197 <width>5</width> 198 <height>0</height> 199 </size> 200 </property> 201 </spacer> 202 </item> 203 <item> 204 <widget class="QPushButton" name="mBtnCancel1" > 205 <property name="text" > 206 <string>Cancel</string> 207 </property> 208 </widget> 209 </item> 210 </layout> 211 </item> 212 </layout> 213 </widget> 214 <widget class="QWidget" name="mPageType" > 215 <layout class="QVBoxLayout" > 216 <item> 217 <widget class="QLabel" name="mPageTypeHdr" > 218 <property name="font" > 219 <font> 220 <family>Arial</family> 221 <pointsize>12</pointsize> 222 <weight>75</weight> 223 <bold>true</bold> 224 </font> 225 </property> 226 <property name="text" > 227 <string>Hard Disk Storage Type</string> 228 </property> 229 </widget> 230 </item> 231 <item> 232 <widget class="Line" name="line21" > 233 <property name="orientation" > 234 <enum>Qt::Horizontal</enum> 235 </property> 236 </widget> 237 </item> 238 <item> 239 <layout class="QHBoxLayout" > 240 <property name="spacing" > 241 <number>10</number> 242 </property> 243 <item> 244 <widget class="QLabel" name="mLogoType" > 245 <property name="sizePolicy" > 246 <sizepolicy vsizetype="Minimum" hsizetype="Maximum" > 247 <horstretch>0</horstretch> 248 <verstretch>0</verstretch> 249 </sizepolicy> 250 </property> 251 <property name="autoFillBackground" > 252 <bool>true</bool> 253 </property> 254 <property name="text" > 255 <string/> 256 </property> 257 <property name="pixmap" > 258 <pixmap resource="../VirtualBox1.qrc" >:/vmw_new_harddisk.png</pixmap> 259 </property> 260 <property name="alignment" > 261 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 262 </property> 263 </widget> 264 </item> 265 <item> 266 <layout class="QVBoxLayout" > 267 <property name="spacing" > 268 <number>10</number> 269 </property> 270 <item> 271 <widget class="QILabel" name="mTextType" > 272 <property name="sizePolicy" > 273 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 274 <horstretch>0</horstretch> 275 <verstretch>0</verstretch> 276 </sizepolicy> 277 </property> 278 <property name="minimumSize" > 279 <size> 280 <width>300</width> 281 <height>0</height> 282 </size> 283 </property> 284 <property name="text" > 285 <string><p>Select the type of virtual hard disk you want to create.</p><p>A <b>dynamically expanding storage</b> initially occupies a very small amount of space on your physical hard disk. It will grow dynamically (up to the size specified) as the Guest OS claims disk space.</p><p>A <b>fixed-size storage</b> does not grow. It is stored in a file of approximately the same size as the size of the virtual hard disk. The creation of a fixed-size storage may take a long time depending on the storage size and the write performance of your harddisk.</p></string> 286 </property> 287 <property name="alignment" > 288 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 289 </property> 290 <property name="wordWrap" > 291 <bool>true</bool> 292 </property> 293 </widget> 294 </item> 295 <item> 296 <widget class="QGroupBox" name="mGbType" > 297 <property name="sizePolicy" > 298 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 299 <horstretch>0</horstretch> 300 <verstretch>0</verstretch> 301 </sizepolicy> 302 </property> 303 <property name="title" > 304 <string>Storage Type</string> 305 </property> 306 <layout class="QVBoxLayout" > 307 <property name="topMargin" > 308 <number>4</number> 309 </property> 310 <item> 311 <widget class="QRadioButton" name="mRbDynamicType" > 312 <property name="sizePolicy" > 313 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 314 <horstretch>0</horstretch> 315 <verstretch>0</verstretch> 316 </sizepolicy> 317 </property> 318 <property name="text" > 319 <string>&Dynamically expanding storage</string> 320 </property> 321 <property name="checked" > 322 <bool>true</bool> 323 </property> 324 </widget> 325 </item> 326 <item> 327 <widget class="QRadioButton" name="mRbFixedType" > 328 <property name="sizePolicy" > 329 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 330 <horstretch>0</horstretch> 331 <verstretch>0</verstretch> 332 </sizepolicy> 333 </property> 334 <property name="text" > 335 <string>&Fixed-size storage</string> 336 </property> 337 </widget> 338 </item> 339 </layout> 340 </widget> 341 </item> 342 <item> 343 <spacer> 344 <property name="orientation" > 345 <enum>Qt::Vertical</enum> 346 </property> 347 <property name="sizeHint" > 348 <size> 349 <width>0</width> 350 <height>0</height> 351 </size> 352 </property> 353 </spacer> 354 </item> 355 </layout> 356 </item> 357 </layout> 358 </item> 359 <item> 360 <widget class="Line" name="line22" > 361 <property name="orientation" > 362 <enum>Qt::Horizontal</enum> 363 </property> 364 </widget> 365 </item> 366 <item> 367 <layout class="QHBoxLayout" > 368 <item> 369 <spacer> 370 <property name="orientation" > 371 <enum>Qt::Horizontal</enum> 372 </property> 373 <property name="sizeHint" > 374 <size> 375 <width>0</width> 376 <height>0</height> 377 </size> 378 </property> 379 </spacer> 380 </item> 381 <item> 382 <widget class="QPushButton" name="mBtnBack2" > 383 <property name="text" > 384 <string>< &Back</string> 385 </property> 386 </widget> 387 </item> 388 <item> 389 <widget class="QPushButton" name="mBtnNext2" > 390 <property name="text" > 391 <string>&Next ></string> 392 </property> 393 </widget> 394 </item> 395 <item> 396 <spacer> 397 <property name="orientation" > 398 <enum>Qt::Horizontal</enum> 399 </property> 400 <property name="sizeType" > 401 <enum>QSizePolicy::Fixed</enum> 402 </property> 403 <property name="sizeHint" > 404 <size> 405 <width>5</width> 406 <height>0</height> 407 </size> 408 </property> 409 </spacer> 410 </item> 411 <item> 412 <widget class="QPushButton" name="mBtnCancel2" > 413 <property name="text" > 414 <string>Cancel</string> 415 </property> 416 </widget> 417 </item> 418 </layout> 419 </item> 420 </layout> 421 </widget> 422 <widget class="QWidget" name="mPageNameAndSize" > 423 <layout class="QVBoxLayout" > 424 <item> 425 <widget class="QLabel" name="mPageNameAndSizeHdr" > 426 <property name="font" > 427 <font> 428 <family>Arial</family> 429 <pointsize>12</pointsize> 430 <weight>75</weight> 431 <bold>true</bold> 432 </font> 433 </property> 434 <property name="text" > 435 <string>Virtual Disk Location and Size</string> 436 </property> 437 </widget> 438 </item> 439 <item> 440 <widget class="Line" name="line31" > 441 <property name="orientation" > 442 <enum>Qt::Horizontal</enum> 443 </property> 444 </widget> 445 </item> 446 <item> 447 <layout class="QHBoxLayout" > 448 <property name="spacing" > 449 <number>10</number> 450 </property> 451 <item> 452 <widget class="QLabel" name="mLogoNameAndSize" > 453 <property name="sizePolicy" > 454 <sizepolicy vsizetype="Minimum" hsizetype="Maximum" > 455 <horstretch>0</horstretch> 456 <verstretch>0</verstretch> 457 </sizepolicy> 458 </property> 459 <property name="autoFillBackground" > 460 <bool>true</bool> 461 </property> 462 <property name="text" > 463 <string/> 464 </property> 465 <property name="pixmap" > 466 <pixmap resource="../VirtualBox1.qrc" >:/vmw_new_harddisk.png</pixmap> 467 </property> 468 <property name="alignment" > 469 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 470 </property> 471 </widget> 472 </item> 473 <item> 474 <layout class="QVBoxLayout" > 475 <property name="spacing" > 476 <number>10</number> 477 </property> 478 <item> 479 <widget class="QILabel" name="mTextNameComment" > 480 <property name="sizePolicy" > 481 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 482 <horstretch>0</horstretch> 483 <verstretch>0</verstretch> 484 </sizepolicy> 485 </property> 486 <property name="minimumSize" > 487 <size> 488 <width>300</width> 489 <height>0</height> 490 </size> 491 </property> 492 <property name="text" > 493 <string><p>Press the <b>Select</b> button to select the location of a file to store the hard disk data or type a file name in the entry field.</p></string> 494 </property> 495 <property name="alignment" > 496 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 497 </property> 498 <property name="wordWrap" > 499 <bool>true</bool> 500 </property> 501 </widget> 502 </item> 503 <item> 504 <widget class="QGroupBox" name="mGbName" > 505 <property name="sizePolicy" > 506 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 507 <horstretch>0</horstretch> 508 <verstretch>0</verstretch> 509 </sizepolicy> 510 </property> 511 <property name="title" > 512 <string>&Location</string> 513 </property> 514 <layout class="QHBoxLayout" > 515 <property name="topMargin" > 516 <number>4</number> 517 </property> 518 <item> 519 <widget class="QLineEdit" name="mLeName" /> 520 </item> 521 <item> 522 <widget class="QToolButton" name="mTbNameSelect" > 523 <property name="text" > 524 <string/> 525 </property> 526 <property name="icon" > 527 <iconset resource="../VirtualBox1.qrc" >:/select_file_16px.png</iconset> 528 </property> 529 </widget> 530 </item> 531 </layout> 532 </widget> 533 </item> 534 <item> 535 <widget class="QILabel" name="mTextSizeComment" > 536 <property name="sizePolicy" > 537 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 538 <horstretch>0</horstretch> 539 <verstretch>0</verstretch> 540 </sizepolicy> 541 </property> 542 <property name="minimumSize" > 543 <size> 544 <width>300</width> 545 <height>0</height> 546 </size> 547 </property> 548 <property name="text" > 549 <string><p>Select the size of the virtual hard disk in megabytes. This size will be reported to the Guest OS as the maximum size of this hard disk.</p></string> 550 </property> 551 <property name="alignment" > 552 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 553 </property> 554 <property name="wordWrap" > 555 <bool>true</bool> 556 </property> 557 </widget> 558 </item> 559 <item> 560 <widget class="QGroupBox" name="mGbSize" > 561 <property name="sizePolicy" > 562 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 563 <horstretch>0</horstretch> 564 <verstretch>0</verstretch> 565 </sizepolicy> 566 </property> 567 <property name="title" > 568 <string>&Size</string> 569 </property> 570 <layout class="QGridLayout" > 571 <item row="0" column="0" colspan="3" > 572 <widget class="QSlider" name="mSlSize" > 573 <property name="sizePolicy" > 574 <sizepolicy vsizetype="Fixed" hsizetype="Expanding" > 575 <horstretch>0</horstretch> 576 <verstretch>0</verstretch> 577 </sizepolicy> 578 </property> 579 <property name="orientation" > 580 <enum>Qt::Horizontal</enum> 581 </property> 582 <property name="tickPosition" > 583 <enum>QSlider::TicksBelow</enum> 584 </property> 585 </widget> 586 </item> 587 <item row="0" column="3" > 588 <widget class="QILineEdit" name="mLeSize" > 589 <property name="sizePolicy" > 590 <sizepolicy vsizetype="Fixed" hsizetype="Maximum" > 591 <horstretch>0</horstretch> 592 <verstretch>0</verstretch> 593 </sizepolicy> 594 </property> 595 </widget> 596 </item> 597 <item row="1" column="0" > 598 <widget class="QLabel" name="mTxSizeMin" > 599 <property name="sizePolicy" > 600 <sizepolicy vsizetype="Preferred" hsizetype="Minimum" > 601 <horstretch>0</horstretch> 602 <verstretch>0</verstretch> 603 </sizepolicy> 604 </property> 605 <property name="alignment" > 606 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 607 </property> 608 </widget> 609 </item> 610 <item row="1" column="1" > 611 <spacer> 612 <property name="orientation" > 613 <enum>Qt::Horizontal</enum> 614 </property> 615 <property name="sizeType" > 616 <enum>QSizePolicy::Expanding</enum> 617 </property> 618 <property name="sizeHint" > 619 <size> 620 <width>221</width> 621 <height>20</height> 622 </size> 623 </property> 624 </spacer> 625 </item> 626 <item row="1" column="2" > 627 <widget class="QLabel" name="mTxSizeMax" > 628 <property name="sizePolicy" > 629 <sizepolicy vsizetype="Preferred" hsizetype="Minimum" > 630 <horstretch>0</horstretch> 631 <verstretch>0</verstretch> 632 </sizepolicy> 633 </property> 634 <property name="alignment" > 635 <set>Qt::AlignRight|Qt::AlignTop|Qt::AlignTrailing</set> 636 </property> 637 </widget> 638 </item> 639 </layout> 640 </widget> 641 </item> 642 <item> 643 <spacer> 644 <property name="orientation" > 645 <enum>Qt::Vertical</enum> 646 </property> 647 <property name="sizeHint" > 648 <size> 649 <width>0</width> 650 <height>0</height> 651 </size> 652 </property> 653 </spacer> 654 </item> 655 </layout> 656 </item> 657 </layout> 658 </item> 659 <item> 660 <widget class="Line" name="line32" > 661 <property name="orientation" > 662 <enum>Qt::Horizontal</enum> 663 </property> 664 </widget> 665 </item> 666 <item> 667 <layout class="QHBoxLayout" > 668 <item> 669 <spacer> 670 <property name="orientation" > 671 <enum>Qt::Horizontal</enum> 672 </property> 673 <property name="sizeHint" > 674 <size> 675 <width>0</width> 676 <height>0</height> 677 </size> 678 </property> 679 </spacer> 680 </item> 681 <item> 682 <widget class="QPushButton" name="mBtnBack3" > 683 <property name="text" > 684 <string>< &Back</string> 685 </property> 686 </widget> 687 </item> 688 <item> 689 <widget class="QPushButton" name="mBtnNext3" > 690 <property name="text" > 691 <string>&Next ></string> 692 </property> 693 </widget> 694 </item> 695 <item> 696 <spacer> 697 <property name="orientation" > 698 <enum>Qt::Horizontal</enum> 699 </property> 700 <property name="sizeType" > 701 <enum>QSizePolicy::Fixed</enum> 702 </property> 703 <property name="sizeHint" > 704 <size> 705 <width>5</width> 706 <height>0</height> 707 </size> 708 </property> 709 </spacer> 710 </item> 711 <item> 712 <widget class="QPushButton" name="mBtnCancel3" > 713 <property name="text" > 714 <string>Cancel</string> 715 </property> 716 </widget> 717 </item> 718 </layout> 719 </item> 720 </layout> 721 </widget> 722 <widget class="QWidget" name="mPageSummary" > 723 <layout class="QVBoxLayout" > 724 <item> 725 <widget class="QLabel" name="mPageSummaryHdr" > 726 <property name="font" > 727 <font> 728 <family>Arial</family> 729 <pointsize>12</pointsize> 730 <weight>75</weight> 731 <bold>true</bold> 732 </font> 733 </property> 734 <property name="text" > 735 <string>Summary</string> 736 </property> 737 </widget> 738 </item> 739 <item> 740 <widget class="Line" name="line41" > 741 <property name="orientation" > 742 <enum>Qt::Horizontal</enum> 743 </property> 744 </widget> 745 </item> 746 <item> 747 <layout class="QHBoxLayout" > 748 <property name="spacing" > 749 <number>10</number> 750 </property> 751 <item> 752 <widget class="QLabel" name="mLogoSummary" > 753 <property name="sizePolicy" > 754 <sizepolicy vsizetype="Minimum" hsizetype="Maximum" > 755 <horstretch>0</horstretch> 756 <verstretch>0</verstretch> 757 </sizepolicy> 758 </property> 759 <property name="autoFillBackground" > 760 <bool>true</bool> 761 </property> 762 <property name="text" > 763 <string/> 764 </property> 765 <property name="pixmap" > 766 <pixmap resource="../VirtualBox1.qrc" >:/vmw_new_harddisk.png</pixmap> 767 </property> 768 <property name="alignment" > 769 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 770 </property> 771 </widget> 772 </item> 773 <item> 774 <layout class="QVBoxLayout" > 775 <property name="spacing" > 776 <number>10</number> 777 </property> 778 <item> 779 <widget class="QILabel" name="mTextSummaryHdr" > 780 <property name="sizePolicy" > 781 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 782 <horstretch>0</horstretch> 783 <verstretch>0</verstretch> 784 </sizepolicy> 785 </property> 786 <property name="minimumSize" > 787 <size> 788 <width>300</width> 789 <height>0</height> 790 </size> 791 </property> 792 <property name="text" > 793 <string>You are going to create a new virtual hard disk with the following parameters:</string> 794 </property> 795 <property name="alignment" > 796 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 797 </property> 798 <property name="wordWrap" > 799 <bool>true</bool> 800 </property> 801 </widget> 802 </item> 803 <item> 804 <widget class="QITextEdit" name="mTeSummary" > 805 <property name="sizePolicy" > 806 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 807 <horstretch>0</horstretch> 808 <verstretch>0</verstretch> 809 </sizepolicy> 810 </property> 811 <property name="minimumSize" > 812 <size> 813 <width>300</width> 814 <height>0</height> 815 </size> 816 </property> 817 <property name="frameShape" > 818 <enum>QFrame::NoFrame</enum> 819 </property> 820 <property name="autoFormatting" > 821 <set>QTextEdit::AutoAll</set> 822 </property> 823 <property name="readOnly" > 824 <bool>true</bool> 825 </property> 826 </widget> 827 </item> 828 <item> 829 <widget class="QILabel" name="mTextSummaryFtr" > 830 <property name="sizePolicy" > 831 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 832 <horstretch>0</horstretch> 833 <verstretch>0</verstretch> 834 </sizepolicy> 835 </property> 836 <property name="minimumSize" > 837 <size> 838 <width>300</width> 839 <height>0</height> 840 </size> 841 </property> 842 <property name="text" > 843 <string>If the above settings are correct, press the <b>Finish</b> button. Once you press it, a new hard disk will be created.</string> 844 </property> 845 <property name="alignment" > 846 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 847 </property> 848 <property name="wordWrap" > 849 <bool>true</bool> 850 </property> 851 </widget> 852 </item> 853 <item> 854 <spacer> 855 <property name="orientation" > 856 <enum>Qt::Vertical</enum> 857 </property> 858 <property name="sizeType" > 859 <enum>QSizePolicy::Expanding</enum> 860 </property> 861 <property name="sizeHint" > 862 <size> 863 <width>0</width> 864 <height>0</height> 865 </size> 866 </property> 867 </spacer> 868 </item> 869 </layout> 870 </item> 871 </layout> 872 </item> 873 <item> 874 <widget class="Line" name="line42" > 875 <property name="orientation" > 876 <enum>Qt::Horizontal</enum> 877 </property> 878 </widget> 879 </item> 880 <item> 881 <layout class="QHBoxLayout" > 882 <item> 883 <spacer> 884 <property name="orientation" > 885 <enum>Qt::Horizontal</enum> 886 </property> 887 <property name="sizeHint" > 888 <size> 889 <width>0</width> 890 <height>0</height> 891 </size> 892 </property> 893 </spacer> 894 </item> 895 <item> 896 <widget class="QPushButton" name="mBtnBack4" > 897 <property name="text" > 898 <string>< &Back</string> 899 </property> 900 </widget> 901 </item> 902 <item> 903 <widget class="QPushButton" name="mBtnFinish" > 904 <property name="text" > 905 <string>&Finish</string> 906 </property> 907 </widget> 908 </item> 909 <item> 910 <spacer> 911 <property name="orientation" > 912 <enum>Qt::Horizontal</enum> 913 </property> 914 <property name="sizeType" > 915 <enum>QSizePolicy::Fixed</enum> 916 </property> 917 <property name="sizeHint" > 918 <size> 919 <width>5</width> 920 <height>0</height> 921 </size> 922 </property> 923 </spacer> 924 </item> 925 <item> 926 <widget class="QPushButton" name="mBtnCancel4" > 927 <property name="text" > 928 <string>Cancel</string> 929 </property> 930 </widget> 931 </item> 932 </layout> 933 </item> 934 </layout> 935 </widget> 45 <property name="wordWrap"> 46 <bool>true</bool> 47 </property> 936 48 </widget> 49 </item> 50 <item> 51 <widget class="QTextEdit" name="m_pSummaryText"> 52 <property name="sizePolicy"> 53 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 54 <horstretch>0</horstretch> 55 <verstretch>0</verstretch> 56 </sizepolicy> 57 </property> 58 <property name="minimumSize"> 59 <size> 60 <width>300</width> 61 <height>0</height> 62 </size> 63 </property> 64 <property name="frameShape"> 65 <enum>QFrame::NoFrame</enum> 66 </property> 67 <property name="readOnly"> 68 <bool>true</bool> 69 </property> 70 </widget> 71 </item> 72 <item> 73 <widget class="QILabel" name="m_pPage4Text2"> 74 <property name="text"> 75 <string>If the above settings are correct, press the <b>Finish</b> button. Once you press it, a new hard disk will be created.</string> 76 </property> 77 <property name="wordWrap"> 78 <bool>true</bool> 79 </property> 80 </widget> 81 </item> 82 <item> 83 <spacer name="m_pSpacer1"> 84 <property name="sizeHint" stdset="0"> 85 <size> 86 <width>0</width> 87 <height>0</height> 88 </size> 89 </property> 90 </spacer> 937 91 </item> 938 92 </layout> … … 944 98 <header>QILabel.h</header> 945 99 </customwidget> 946 <customwidget>947 <class>QITextEdit</class>948 <extends>QTextEdit</extends>949 <header>QIAbstractWizard.h</header>950 </customwidget>951 <customwidget>952 <class>QILineEdit</class>953 <extends>QLineEdit</extends>954 <header>QILineEdit.h</header>955 </customwidget>956 100 </customwidgets> 957 <tabstops> 958 <tabstop>mBtnNext1</tabstop> 959 <tabstop>mBtnCancel1</tabstop> 960 <tabstop>mBtnBack2</tabstop> 961 <tabstop>mBtnNext2</tabstop> 962 <tabstop>mBtnCancel2</tabstop> 963 <tabstop>mSlSize</tabstop> 964 <tabstop>mLeSize</tabstop> 965 <tabstop>mBtnBack3</tabstop> 966 <tabstop>mBtnNext3</tabstop> 967 <tabstop>mBtnCancel3</tabstop> 968 <tabstop>mBtnBack4</tabstop> 969 <tabstop>mBtnFinish</tabstop> 970 <tabstop>mBtnCancel4</tabstop> 971 </tabstops> 972 <resources> 973 <include location="../VirtualBox1.qrc" /> 974 </resources> 101 <resources/> 975 102 <connections/> 976 103 </ui> -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/newvm/UINewVMWzd.cpp
r25265 r26079 2 2 * 3 3 * VBox frontends: Qt4 GUI ("VirtualBox"): 4 * VBoxNewVMWzd class implementation4 * UINewVMWzd class implementation 5 5 */ 6 6 7 7 /* 8 * Copyright (C) 2006-20 08Sun Microsystems, Inc.8 * Copyright (C) 2006-2010 Sun Microsystems, Inc. 9 9 * 10 10 * This file is part of VirtualBox Open Source Edition (OSE), as … … 21 21 */ 22 22 23 /* VBox includes */ 24 #include "VBoxNewVMWzd.h" 25 #include "VBoxVMSettingsHD.h" 26 #include "VBoxUtils.h" 23 /* Local includes */ 24 #include "UINewVMWzd.h" 25 #include "UINewHDWzd.h" 27 26 #include "VBoxGlobal.h" 28 27 #include "VBoxProblemReporter.h" 29 #include "VBoxNewHDWzd.h"30 28 #include "VBoxMediaManagerDlg.h" 31 32 VBoxNewVMWzd::VBoxNewVMWzd (QWidget *aParent) 33 : QIWithRetranslateUI<QIAbstractWizard> (aParent) 34 { 35 /* Apply UI decorations */ 36 Ui::VBoxNewVMWzd::setupUi (this); 37 38 /* Initialize wizard hdr */ 39 initializeWizardHdr(); 40 41 /* Name and OS page */ 42 mLeName->setValidator (new QRegExpValidator (QRegExp (".+"), this)); 43 44 mWvalNameAndOS = new QIWidgetValidator (mPageNameAndOS, this); 45 connect (mWvalNameAndOS, SIGNAL (validityChanged (const QIWidgetValidator*)), 46 this, SLOT (enableNext (const QIWidgetValidator*))); 47 connect (mOSTypeSelector, SIGNAL (osTypeChanged()), this, SLOT (onOSTypeChanged())); 48 49 /* Memory page */ 50 mLeRAM->setFixedWidthByText ("99999"); 51 mLeRAM->setValidator (new QIntValidator (mSlRAM->minRAM(), mSlRAM->maxRAM(), this)); 52 53 mWvalMemory = new QIWidgetValidator (mPageMemory, this); 54 connect (mWvalMemory, SIGNAL (validityChanged (const QIWidgetValidator*)), 55 this, SLOT (enableNext (const QIWidgetValidator*))); 56 connect (mWvalMemory, SIGNAL (isValidRequested (QIWidgetValidator*)), 57 this, SLOT (revalidate (QIWidgetValidator*))); 58 connect (mSlRAM, SIGNAL (valueChanged (int)), 59 this, SLOT (slRAMValueChanged (int))); 60 connect (mLeRAM, SIGNAL (textChanged (const QString&)), 61 this, SLOT (leRAMTextChanged (const QString&))); 62 63 /* HDD Images page */ 29 #include "VBoxVMSettingsHD.h" 30 31 UINewVMWzd::UINewVMWzd(QWidget *pParent) : QIWizard(pParent) 32 { 33 /* Create & add pages */ 34 addPage(new UINewVMWzdPage1); 35 addPage(new UINewVMWzdPage2); 36 addPage(new UINewVMWzdPage3); 37 addPage(new UINewVMWzdPage4); 38 addPage(new UINewVMWzdPage5); 39 40 /* Translate */ 41 retranslateUi(); 42 43 /* Resize to 'golden ratio' */ 44 resizeToGoldenRatio(); 45 46 /* Assign watermark */ 47 assignWatermark(":/vmw_new_welcome.png"); 48 } 49 50 const CMachine UINewVMWzd::machine() const 51 { 52 /* Use 'machine' field value from page 5 */ 53 return field("machine").value<CMachine>(); 54 } 55 56 void UINewVMWzd::retranslateUi() 57 { 58 /* Wizard title */ 59 setWindowTitle(tr("Create New Virtual Machine")); 60 } 61 62 UINewVMWzdPage1::UINewVMWzdPage1() 63 { 64 /* Decorate page */ 65 Ui::UINewVMWzdPage1::setupUi(this); 66 67 /* Translate */ 68 retranslateUi(); 69 } 70 71 void UINewVMWzdPage1::retranslateUi() 72 { 73 /* Translate uic generated strings */ 74 Ui::UINewVMWzdPage1::retranslateUi(this); 75 76 /* Wizard page 1 title */ 77 setTitle(tr("Welcome to the New Virtual Machine Wizard!")); 78 } 79 80 UINewVMWzdPage2::UINewVMWzdPage2() 81 { 82 /* Decorate page */ 83 Ui::UINewVMWzdPage2::setupUi(this); 84 85 /* Register 'name' & 'type' fields */ 86 registerField("name*", m_pNameEditor); 87 registerField("type*", m_pTypeSelector, "type", SIGNAL(osTypeChanged())); 88 89 /* Setup contents */ 90 m_pTypeSelector->activateLayout(); 91 92 /* Translate */ 93 retranslateUi(); 94 } 95 96 void UINewVMWzdPage2::retranslateUi() 97 { 98 /* Translate uic generated strings */ 99 Ui::UINewVMWzdPage2::retranslateUi(this); 100 101 /* Wizard page 2 title */ 102 setTitle(tr("VM Name and OS Type")); 103 } 104 105 void UINewVMWzdPage2::initializePage() 106 { 107 /* Translate */ 108 retranslateUi(); 109 110 /* 'Name' field should have focus initially */ 111 m_pNameEditor->setFocus(); 112 } 113 114 UINewVMWzdPage3::UINewVMWzdPage3() 115 { 116 /* Decorate page */ 117 Ui::UINewVMWzdPage3::setupUi(this); 118 119 /* Register 'ram' field */ 120 registerField("ram*", m_pRamSlider, "value", SIGNAL(valueChanged(int))); 121 122 /* Setup contents */ 123 m_pRamEditor->setFixedWidthByText("88888"); 124 m_pRamEditor->setAlignment(Qt::AlignRight); 125 m_pRamEditor->setValidator(new QIntValidator(m_pRamSlider->minRAM(), m_pRamSlider->maxRAM(), this)); 126 127 /* Setup page connections */ 128 connect(m_pRamSlider, SIGNAL(valueChanged(int)), this, SLOT(ramSliderValueChanged(int))); 129 connect(m_pRamEditor, SIGNAL(textChanged(const QString &)), this, SLOT(ramEditorTextChanged(const QString &))); 130 131 /* Initialise page connections */ 132 ramSliderValueChanged(m_pRamSlider->value()); 133 134 /* Translate */ 135 retranslateUi(); 136 } 137 138 void UINewVMWzdPage3::retranslateUi() 139 { 140 /* Translate uic generated strings */ 141 Ui::UINewVMWzdPage3::retranslateUi(this); 142 143 /* Wizard page 3 title */ 144 setTitle(tr("Memory")); 145 146 /* Translate recommended 'ram' field value */ 147 QString strRecommendedRAM = field("type").value<CGuestOSType>().isNull() ? QString() : 148 QString::number(field("type").value<CGuestOSType>().GetRecommendedRAM()); 149 m_pPage3Text2->setText(tr("The recommended base memory size is <b>%1</b> MB.").arg(strRecommendedRAM)); 150 151 /* Translate minimum & maximum 'ram' field values */ 152 m_pRamMin->setText(QString("%1 %2").arg(m_pRamSlider->minRAM()).arg(tr("MB", "megabytes"))); 153 m_pRamMax->setText(QString("%1 %2").arg(m_pRamSlider->maxRAM()).arg(tr("MB", "megabytes"))); 154 } 155 156 void UINewVMWzdPage3::initializePage() 157 { 158 /* Translate */ 159 retranslateUi(); 160 161 /* Assign recommended 'ram' field value */ 162 CGuestOSType type = field("type").value<CGuestOSType>(); 163 ramSliderValueChanged(type.GetRecommendedRAM()); 164 165 /* 'Ram' field should have focus initially */ 166 m_pRamSlider->setFocus(); 167 } 168 169 bool UINewVMWzdPage3::isComplete() const 170 { 171 /* Check what 'ram' field value feats the bounds */ 172 return field("ram").toInt() >= qMax(1, (int)m_pRamSlider->minRAM()) && 173 field("ram").toInt() <= (int)m_pRamSlider->maxRAM(); 174 } 175 176 void UINewVMWzdPage3::ramSliderValueChanged(int iValue) 177 { 178 /* Update 'ram' field editor connected to slider */ 179 m_pRamEditor->setText(QString::number(iValue)); 180 } 181 182 void UINewVMWzdPage3::ramEditorTextChanged(const QString &strText) 183 { 184 /* Update 'ram' field slider connected to editor */ 185 m_pRamSlider->setValue(strText.toInt()); 186 } 187 188 UINewVMWzdPage4::UINewVMWzdPage4() 189 { 190 /* Decorate page */ 191 Ui::UINewVMWzdPage4::setupUi(this); 192 193 /* Register CMedium class */ 194 qRegisterMetaType<CMedium>(); 195 196 /* Register all related 'hardDisk*' fields */ 197 registerField("hardDisk", this, "hardDisk"); 198 registerField("hardDiskId", this, "hardDiskId"); 199 registerField("hardDiskName", this, "hardDiskName"); 200 registerField("hardDiskLocation", this, "hardDiskLocation"); 201 202 /* Insert shifting spacer */ 203 QGridLayout *pLayout = qobject_cast<QGridLayout*>(m_pBootHDCnt->layout()); 204 Assert(pLayout); 64 205 QStyleOptionButton options; 65 options.initFrom (mNewVDIRadio); 66 QGridLayout *hdLayout = qobject_cast <QGridLayout*> (mGbHDA->layout()); 67 int wid = mNewVDIRadio->style()->subElementRect (QStyle::SE_RadioButtonIndicator, &options, mNewVDIRadio).width() + 68 mNewVDIRadio->style()->pixelMetric (QStyle::PM_RadioButtonLabelSpacing, &options, mNewVDIRadio) - 69 hdLayout->spacing() - 1; 70 QSpacerItem *spacer = new QSpacerItem (wid, 0, QSizePolicy::Fixed, QSizePolicy::Fixed); 71 hdLayout->addItem (spacer, 2, 0); 72 mHDCombo->setType (VBoxDefs::MediumType_HardDisk); 73 mHDCombo->repopulate(); 74 mTbVmm->setIcon (VBoxGlobal::iconSet (":/select_file_16px.png", 75 ":/select_file_dis_16px.png")); 76 77 mWvalHDD = new QIWidgetValidator (mPageHDD, this); 78 connect (mWvalHDD, SIGNAL (validityChanged (const QIWidgetValidator*)), 79 this, SLOT (enableNext (const QIWidgetValidator*))); 80 connect (mWvalHDD, SIGNAL (isValidRequested (QIWidgetValidator*)), 81 this, SLOT (revalidate (QIWidgetValidator*))); 82 connect (mGbHDA, SIGNAL (toggled (bool)), mWvalHDD, SLOT (revalidate())); 83 connect (mNewVDIRadio, SIGNAL (toggled (bool)), this, SLOT (hdTypeChanged())); 84 connect (mExistRadio, SIGNAL (toggled (bool)), this, SLOT (hdTypeChanged())); 85 connect (mHDCombo, SIGNAL (currentIndexChanged (int)), 86 mWvalHDD, SLOT (revalidate())); 87 connect (mTbVmm, SIGNAL (clicked()), this, SLOT (showMediaManager())); 88 89 /* Name and OS page */ 90 onOSTypeChanged(); 91 92 /* Memory page */ 93 slRAMValueChanged (mSlRAM->value()); 94 95 /* HDD Images page */ 96 hdTypeChanged(); 97 98 /* Initial revalidation */ 99 mWvalNameAndOS->revalidate(); 100 mWvalMemory->revalidate(); 101 mWvalHDD->revalidate(); 102 103 /* Initialize wizard ftr */ 104 initializeWizardFtr(); 105 106 retranslateUi(); 107 } 108 109 VBoxNewVMWzd::~VBoxNewVMWzd() 110 { 206 options.initFrom(m_pDiskCreate); 207 int wid = m_pDiskCreate->style()->subElementRect(QStyle::SE_RadioButtonIndicator, &options, m_pDiskCreate).width() + 208 m_pDiskCreate->style()->pixelMetric(QStyle::PM_RadioButtonLabelSpacing, &options, m_pDiskCreate) - 209 pLayout->spacing() - 1; 210 QSpacerItem *spacer = new QSpacerItem(wid, 0, QSizePolicy::Fixed, QSizePolicy::Fixed); 211 pLayout->addItem(spacer, 2, 0); 212 213 /* Initialise medium-combo-box */ 214 m_pDiskSelector->setType(VBoxDefs::MediumType_HardDisk); 215 m_pDiskSelector->repopulate(); 216 217 /* Setup medium-manager button */ 218 m_pVMMButton->setIcon(VBoxGlobal::iconSet(":/select_file_16px.png", ":/select_file_dis_16px.png")); 219 220 /* Setup page connections */ 221 connect(m_pBootHDCnt, SIGNAL(toggled(bool)), this, SLOT(hardDiskSourceChanged())); 222 connect(m_pDiskCreate, SIGNAL(toggled(bool)), this, SLOT(hardDiskSourceChanged())); 223 connect(m_pDiskPresent, SIGNAL(toggled(bool)), this, SLOT(hardDiskSourceChanged())); 224 connect(m_pDiskSelector, SIGNAL(currentIndexChanged(int)), this, SLOT(hardDiskSourceChanged())); 225 connect(m_pVMMButton, SIGNAL(clicked()), this, SLOT(getWithMediaManager())); 226 227 /* Initialise page connections */ 228 hardDiskSourceChanged(); 229 230 /* Translate */ 231 retranslateUi(); 232 } 233 234 void UINewVMWzdPage4::retranslateUi() 235 { 236 /* Translate uic generated strings */ 237 Ui::UINewVMWzdPage4::retranslateUi(this); 238 239 /* Wizard page 4 title */ 240 setTitle(tr("Virtual Hard Disk")); 241 242 /* Translate recommended 'hdd' field value */ 243 QString strRecommendedHDD = field("type").value<CGuestOSType>().isNull() ? QString() : 244 QString::number(field("type").value<CGuestOSType>().GetRecommendedHDD()); 245 m_pPage4Text2->setText (tr ("The recommended size of the boot hard disk is <b>%1</b> MB.").arg (strRecommendedHDD)); 246 } 247 248 void UINewVMWzdPage4::initializePage() 249 { 250 /* Translate */ 251 retranslateUi(); 252 253 /* Prepare initial choice */ 254 m_pBootHDCnt->setChecked(true); 255 m_pDiskSelector->setCurrentIndex(0); 256 m_pDiskCreate->setChecked(true); 257 258 /* 'Create new hard-disk' should have focus initially */ 259 m_pDiskCreate->setFocus(); 260 } 261 262 void UINewVMWzdPage4::cleanupPage() 263 { 264 /* Clean medium if present */ 111 265 ensureNewHardDiskDeleted(); 112 } 113 114 const CMachine& VBoxNewVMWzd::machine() const 115 { 116 return mMachine; 117 } 118 119 void VBoxNewVMWzd::retranslateUi() 266 /* Clean fields of that page */ 267 QIWizardPage::cleanupPage(); 268 } 269 270 bool UINewVMWzdPage4::isComplete() const 271 { 272 /* Check what 'hardDisk' field value feats the rules */ 273 return !m_pBootHDCnt->isChecked() || 274 !m_pDiskPresent->isChecked() || 275 !vboxGlobal().findMedium(m_pDiskSelector->id()).isNull(); 276 } 277 278 bool UINewVMWzdPage4::validatePage() 279 { 280 /* Ensure unused hard-disk is deleted */ 281 if (!m_pBootHDCnt->isChecked() || m_pDiskCreate->isChecked() || (!m_HardDisk.isNull() && m_strHardDiskId != m_HardDisk.GetId())) 282 ensureNewHardDiskDeleted(); 283 284 /* Ask user about disk-less machine */ 285 if (!m_pBootHDCnt->isChecked() && !vboxProblem().confirmHardDisklessMachine(this)) 286 return false; 287 288 /* Show the New Hard Disk wizard */ 289 if (m_pBootHDCnt->isChecked() && m_pDiskCreate->isChecked() && !getWithNewHardDiskWizard()) 290 return false; 291 292 return true; 293 } 294 295 void UINewVMWzdPage4::ensureNewHardDiskDeleted() 296 { 297 if (m_HardDisk.isNull()) 298 return; 299 300 QString id = m_HardDisk.GetId(); 301 302 bool success = false; 303 304 CProgress progress = m_HardDisk.DeleteStorage(); 305 if (m_HardDisk.isOk()) 306 { 307 vboxProblem().showModalProgressDialog(progress, windowTitle(), this); 308 if (progress.isOk() && progress.GetResultCode() == S_OK) 309 success = true; 310 } 311 312 if (success) 313 vboxGlobal().removeMedium(VBoxDefs::MediumType_HardDisk, id); 314 else 315 vboxProblem().cannotDeleteHardDiskStorage(this, m_HardDisk, progress); 316 317 m_HardDisk.detach(); 318 } 319 320 void UINewVMWzdPage4::hardDiskSourceChanged() 321 { 322 m_pDiskCreate->setEnabled(m_pBootHDCnt->isChecked()); 323 m_pDiskPresent->setEnabled(m_pBootHDCnt->isChecked()); 324 m_pDiskSelector->setEnabled(m_pDiskPresent->isEnabled() && m_pDiskPresent->isChecked()); 325 m_pVMMButton->setEnabled(m_pDiskPresent->isEnabled() && m_pDiskPresent->isChecked()); 326 327 if (m_pBootHDCnt->isChecked() && m_pDiskPresent->isChecked()) 328 { 329 m_strHardDiskId = m_pDiskSelector->id(); 330 m_strHardDiskName = m_pDiskSelector->currentText(); 331 m_strHardDiskLocation = m_pDiskSelector->location(); 332 } 333 else 334 { 335 m_strHardDiskId.clear(); 336 m_strHardDiskName.clear(); 337 m_strHardDiskLocation.clear(); 338 } 339 340 emit completeChanged(); 341 } 342 343 void UINewVMWzdPage4::getWithMediaManager() 344 { 345 VBoxMediaManagerDlg dlg(this); 346 dlg.setup(VBoxDefs::MediumType_HardDisk, true); 347 348 if (dlg.exec() == QDialog::Accepted) 349 { 350 QString newId = dlg.selectedId(); 351 if (m_pDiskSelector->id() != newId) 352 m_pDiskSelector->setCurrentItem(newId); 353 } 354 355 m_pDiskSelector->setFocus(); 356 } 357 358 bool UINewVMWzdPage4::getWithNewHardDiskWizard() 359 { 360 UINewHDWzd dlg(this); 361 dlg.setRecommendedName(field("name").toString()); 362 dlg.setRecommendedSize(field("type").value<CGuestOSType>().GetRecommendedHDD()); 363 364 if (dlg.exec() == QDialog::Accepted) 365 { 366 m_HardDisk = dlg.hardDisk(); 367 m_pDiskSelector->setCurrentItem(m_HardDisk.GetId()); 368 m_pDiskPresent->click(); 369 return true; 370 } 371 372 return false; 373 } 374 375 CMedium UINewVMWzdPage4::hardDisk() const 376 { 377 return m_HardDisk; 378 } 379 380 void UINewVMWzdPage4::setHardDisk(const CMedium &hardDisk) 381 { 382 m_HardDisk = hardDisk; 383 } 384 385 QString UINewVMWzdPage4::hardDiskId() const 386 { 387 return m_strHardDiskId; 388 } 389 390 void UINewVMWzdPage4::setHardDiskId(const QString &strHardDiskId) 391 { 392 m_strHardDiskId = strHardDiskId; 393 } 394 395 QString UINewVMWzdPage4::hardDiskName() const 396 { 397 return m_strHardDiskName; 398 } 399 400 void UINewVMWzdPage4::setHardDiskName(const QString &strHardDiskName) 401 { 402 m_strHardDiskName = strHardDiskName; 403 } 404 405 QString UINewVMWzdPage4::hardDiskLocation() const 406 { 407 return m_strHardDiskLocation; 408 } 409 410 void UINewVMWzdPage4::setHardDiskLocation(const QString &strHardDiskLocation) 411 { 412 m_strHardDiskLocation = strHardDiskLocation; 413 } 414 415 UINewVMWzdPage5::UINewVMWzdPage5() 416 { 417 /* Decorate page */ 418 Ui::UINewVMWzdPage5::setupUi(this); 419 420 /* Register CMachine class */ 421 qRegisterMetaType<CMachine>(); 422 423 /* Register 'machine' field */ 424 registerField("machine", this, "machine"); 425 426 /* Disable the background painting of the summary widget */ 427 m_pSummaryText->viewport()->setAutoFillBackground (false); 428 /* Make the summary field read-only */ 429 m_pSummaryText->setReadOnly (true); 430 431 /* Translate */ 432 retranslateUi(); 433 } 434 435 void UINewVMWzdPage5::retranslateUi() 120 436 { 121 437 /* Translate uic generated strings */ 122 Ui::VBoxNewVMWzd::retranslateUi (this); 123 124 CGuestOSType type = mOSTypeSelector->type(); 125 126 mTextRAMBest->setText ( 127 tr ("The recommended base memory size is <b>%1</b> MB.") 128 .arg (type.GetRecommendedRAM())); 129 mTextVDIBest->setText ( 130 tr ("The recommended size of the boot hard disk is <b>%1</b> MB.") 131 .arg (type.GetRecommendedHDD())); 132 133 mTxRAMMin->setText (QString ("<qt>%1 %2</qt>") 134 .arg (mSlRAM->minRAM()).arg (tr ("MB", "megabytes"))); 135 mTxRAMMax->setText (QString ("<qt>%1 %2</qt>") 136 .arg (mSlRAM->maxRAM()).arg (tr ("MB", "megabytes"))); 137 138 QWidget *page = mPageStack->currentWidget(); 139 140 if (page == mPageSummary) 141 { 142 /* Compose summary */ 143 QString summary = QString ( 144 "<tr><td><nobr>%1: </nobr></td><td>%2</td></tr>" 145 "<tr><td><nobr>%3: </nobr></td><td>%4</td></tr>" 146 "<tr><td><nobr>%5: </nobr></td><td>%6 %7</td></tr>") 147 .arg (tr ("Name", "summary"), mLeName->text()) 148 .arg (tr ("OS Type", "summary"), type.GetDescription()) 149 .arg (tr ("Base Memory", "summary")).arg (mSlRAM->value()) 150 .arg (tr ("MB", "megabytes")); 151 152 if (mGbHDA->isChecked() && !mHDCombo->id().isNull()) 153 summary += QString ( 154 "<tr><td><nobr>%8: </nobr></td><td><nobr>%9</nobr></td></tr>") 155 .arg (tr ("Boot Hard Disk", "summary"), mHDCombo->currentText()); 156 157 mTeSummary->setText ("<table>" + summary + "</table>"); 158 } 159 } 160 161 void VBoxNewVMWzd::accept() 162 { 163 /* Try to create the machine when the Finish button is pressed. 164 * On failure, the wisard will remain open to give it another try. */ 165 if (constructMachine()) 166 QDialog::accept(); 167 } 168 169 void VBoxNewVMWzd::showMediaManager() 170 { 171 VBoxMediaManagerDlg dlg (this); 172 dlg.setup (VBoxDefs::MediumType_HardDisk, true); 173 174 if (dlg.exec() == QDialog::Accepted) 175 { 176 QString newId = dlg.selectedId(); 177 if (mHDCombo->id() != newId) 178 { 179 ensureNewHardDiskDeleted(); 180 mHDCombo->setCurrentItem (newId); 181 } 182 } 183 184 mHDCombo->setFocus(); 185 } 186 187 void VBoxNewVMWzd::onOSTypeChanged() 188 { 189 slRAMValueChanged (mOSTypeSelector->type().GetRecommendedRAM()); 190 } 191 192 void VBoxNewVMWzd::slRAMValueChanged (int aValue) 193 { 194 mLeRAM->setText (QString().setNum (aValue)); 195 } 196 197 void VBoxNewVMWzd::leRAMTextChanged (const QString &aText) 198 { 199 mSlRAM->setValue (aText.toInt()); 200 } 201 202 void VBoxNewVMWzd::hdTypeChanged() 203 { 204 mHDCombo->setEnabled (mExistRadio->isChecked()); 205 mTbVmm->setEnabled (mExistRadio->isChecked()); 206 if (mExistRadio->isChecked()) 207 mHDCombo->setFocus(); 208 209 mWvalHDD->revalidate(); 210 } 211 212 void VBoxNewVMWzd::revalidate (QIWidgetValidator *aWval) 213 { 214 /* Get common result of validators */ 215 bool valid = aWval->isOtherValid(); 216 217 /* Do individual validations for pages */ 218 if (aWval->widget() == mPageMemory) 219 { 220 valid = true; 221 if (mSlRAM->value() > (int)mSlRAM->maxRAMAlw()) 222 valid = false; 223 } 224 else if (aWval->widget() == mPageHDD) 225 { 226 valid = true; 227 if ( (mGbHDA->isChecked()) 228 && (vboxGlobal().findMedium (mHDCombo->id()).isNull()) 229 && (mExistRadio->isChecked())) 230 { 231 valid = false; 232 } 233 } 234 235 aWval->setOtherValid (valid); 236 } 237 238 void VBoxNewVMWzd::enableNext (const QIWidgetValidator *aWval) 239 { 240 nextButton (aWval->widget())->setEnabled (aWval->isValid()); 241 } 242 243 void VBoxNewVMWzd::onPageShow() 244 { 245 /* Make sure all is properly translated & composed */ 246 retranslateUi(); 247 248 QWidget *page = mPageStack->currentWidget(); 249 250 if (page == mPageWelcome) 251 nextButton (page)->setFocus(); 252 else if (page == mPageNameAndOS) 253 mLeName->setFocus(); 254 else if (page == mPageMemory) 255 mSlRAM->setFocus(); 256 else if (page == mPageHDD) 257 mHDCombo->setFocus(); 258 else if (page == mPageSummary) 259 mTeSummary->setFocus(); 260 261 if (page == mPageSummary) 262 finishButton()->setDefault (true); 263 else 264 nextButton (page)->setDefault (true); 265 } 266 267 void VBoxNewVMWzd::showBackPage() 268 { 269 /* Delete temporary HD if present */ 270 if (sender() == mBtnBack5) 271 ensureNewHardDiskDeleted(); 272 273 /* Switch to the back page */ 274 QIAbstractWizard::showBackPage(); 275 } 276 277 void VBoxNewVMWzd::showNextPage() 278 { 279 /* Ask user about disk-less machine */ 280 if (sender() == mBtnNext4 && !mGbHDA->isChecked() && 281 !vboxProblem().confirmHardDisklessMachine (this)) 282 return; 283 284 /* Show the New Hard Disk wizard */ 285 if (sender() == mBtnNext4 && mGbHDA->isChecked() && 286 mNewVDIRadio->isChecked() && !showNewHDWizard()) 287 return; 288 289 /* Switch to the next page */ 290 QIAbstractWizard::showNextPage(); 291 } 292 293 294 bool VBoxNewVMWzd::showNewHDWizard() 295 { 296 VBoxNewHDWzd dlg (this); 297 298 dlg.setRecommendedFileName (mLeName->text()); 299 dlg.setRecommendedSize (mOSTypeSelector->type().GetRecommendedHDD()); 300 301 if (dlg.exec() == QDialog::Accepted) 302 { 303 ensureNewHardDiskDeleted(); 304 mHardDisk = dlg.hardDisk(); 305 mHDCombo->setCurrentItem (mHardDisk.GetId()); 306 return true; 307 } 308 309 return false; 310 } 311 312 bool VBoxNewVMWzd::constructMachine() 438 Ui::UINewVMWzdPage5::retranslateUi(this); 439 440 /* Wizard page 5 title */ 441 setTitle(tr("Summary")); 442 443 /* Compose common summary */ 444 QString summary; 445 446 QString name = field("name").toString(); 447 QString type = field("type").value<CGuestOSType>().isNull() ? QString() : 448 field("type").value<CGuestOSType>().GetDescription(); 449 QString ram = QString::number(field("ram").toInt()); 450 451 summary += QString 452 ( 453 "<tr><td><nobr>%1: </nobr></td><td>%2</td></tr>" 454 "<tr><td><nobr>%3: </nobr></td><td>%4</td></tr>" 455 "<tr><td><nobr>%5: </nobr></td><td>%6 %7</td></tr>" 456 ) 457 .arg(tr("Name", "summary"), name) 458 .arg(tr("OS Type", "summary"), type) 459 .arg(tr("Base Memory", "summary"), ram, tr("MB", "megabytes")) 460 ; 461 /* Feat summary to 3 lines */ 462 setSummaryFieldLinesNumber(m_pSummaryText, 3); 463 464 /* Add hard-disk info */ 465 if (!field("hardDiskId").toString().isNull()) 466 { 467 summary += QString( 468 "<tr><td><nobr>%8: </nobr></td><td><nobr>%9</nobr></td></tr>") 469 .arg(tr("Boot Hard Disk", "summary"), field("hardDiskName").toString()); 470 /* Extend summary to 4 lines */ 471 setSummaryFieldLinesNumber(m_pSummaryText, 4); 472 } 473 474 m_pSummaryText->setText("<table cellspacing=0 cellpadding=0>" + summary + "</table>"); 475 } 476 477 void UINewVMWzdPage5::initializePage() 478 { 479 /* Translate */ 480 retranslateUi(); 481 482 /* Summary should have focus initially */ 483 m_pSummaryText->setFocus(); 484 } 485 486 bool UINewVMWzdPage5::validatePage() 487 { 488 /* Try to construct machine */ 489 return constructMachine(); 490 } 491 492 bool UINewVMWzdPage5::constructMachine() 313 493 { 314 494 CVirtualBox vbox = vboxGlobal().virtualBox(); 315 495 316 496 /* OS type */ 317 CGuestOSType type = mOSTypeSelector->type();318 AssertMsg (!type.isNull(), ("vmGuestOSType()must return non-null type"));497 CGuestOSType type = field("type").value<CGuestOSType>(); 498 AssertMsg(!type.isNull(), ("GuestOSType must return non-null type")); 319 499 QString typeId = type.GetId(); 320 500 321 501 /* Create a machine with the default settings file location */ 322 if (m Machine.isNull())323 { 324 m Machine = vbox.CreateMachine (mLeName->text(), typeId, QString::null, QString::null);502 if (m_Machine.isNull()) 503 { 504 m_Machine = vbox.CreateMachine(field("name").toString(), typeId, QString::null, QString::null); 325 505 if (!vbox.isOk()) 326 506 { 327 vboxProblem().cannotCreateMachine 507 vboxProblem().cannotCreateMachine(vbox, this); 328 508 return false; 329 509 } 330 510 331 /* The FirstRun wizard is to be shown only when we don't attach any hard 332 * disk or attach a new (empty) one. Selecting an existing hard disk 333 * will cancel the wizard. */ 334 if (!mGbHDA->isChecked() || !mHardDisk.isNull()) 335 mMachine.SetExtraData (VBoxDefs::GUI_FirstRun, "yes"); 511 /* The FirstRun wizard is to be shown only when we don't attach any hard disk or attach a new (empty) one. 512 * Selecting an existing hard disk will cancel the wizard. */ 513 if (field("hardDiskId").toString().isNull() || !field("hardDisk").value<CMedium>().isNull()) 514 m_Machine.SetExtraData(VBoxDefs::GUI_FirstRun, "yes"); 336 515 } 337 516 338 517 /* RAM size */ 339 m Machine.SetMemorySize (mSlRAM->value());518 m_Machine.SetMemorySize(field("ram").toInt()); 340 519 341 520 /* VRAM size - select maximum between recommended and minimum for fullscreen */ 342 m Machine.SetVRAMSize (qMax (type.GetRecommendedVRAM(),343 (ULONG) (VBoxGlobal::requiredVideoMemory(&m Machine) / _1M)));521 m_Machine.SetVRAMSize (qMax (type.GetRecommendedVRAM(), 522 (ULONG) (VBoxGlobal::requiredVideoMemory(&m_Machine) / _1M))); 344 523 345 524 /* Enabling audio by default */ 346 m Machine.GetAudioAdapter().SetEnabled(true);525 m_Machine.GetAudioAdapter().SetEnabled(true); 347 526 348 527 /* Enable the OHCI and EHCI controller by default for new VMs. (new in 2.2) */ 349 CUSBController usbController = m Machine.GetUSBController();528 CUSBController usbController = m_Machine.GetUSBController(); 350 529 if (!usbController.isNull()) 351 530 { 352 usbController.SetEnabled 353 usbController.SetEnabledEhci 531 usbController.SetEnabled(true); 532 usbController.SetEnabledEhci(true); 354 533 } 355 534 356 535 /* Create default storage controllers */ 357 QString ideCtrName = VBoxVMSettingsHD::tr 358 QString floppyCtrName = VBoxVMSettingsHD::tr 536 QString ideCtrName = VBoxVMSettingsHD::tr("IDE Controller"); 537 QString floppyCtrName = VBoxVMSettingsHD::tr("Floppy Controller"); 359 538 KStorageBus ideBus = KStorageBus_IDE; 360 539 KStorageBus floppyBus = KStorageBus_Floppy; 361 m Machine.AddStorageController(ideCtrName, ideBus);362 m Machine.AddStorageController(floppyCtrName, floppyBus);540 m_Machine.AddStorageController(ideCtrName, ideBus); 541 m_Machine.AddStorageController(floppyCtrName, floppyBus); 363 542 364 543 /* Register the VM prior to attaching hard disks */ 365 vbox.RegisterMachine (mMachine);544 vbox.RegisterMachine(m_Machine); 366 545 if (!vbox.isOk()) 367 546 { 368 vboxProblem().cannotCreateMachine (vbox, mMachine, this);547 vboxProblem().cannotCreateMachine(vbox, m_Machine, this); 369 548 return false; 370 549 } … … 373 552 { 374 553 bool success = false; 375 QString machineId = m Machine.GetId();376 CSession session = vboxGlobal().openSession 554 QString machineId = m_Machine.GetId(); 555 CSession session = vboxGlobal().openSession(machineId); 377 556 if (!session.isNull()) 378 557 { … … 380 559 381 560 /* Boot hard disk (IDE Primary Master) */ 382 if ( mGbHDA->isChecked())561 if (!field("hardDiskId").toString().isNull()) 383 562 { 384 m.AttachDevice (ideCtrName, 0, 0, KDeviceType_HardDisk, mHDCombo->id());563 m.AttachDevice(ideCtrName, 0, 0, KDeviceType_HardDisk, field("hardDiskId").toString()); 385 564 if (!m.isOk()) 386 vboxProblem().cannotAttachDevice (this, m, VBoxDefs::MediumType_HardDisk, mHDCombo->location(), ideBus, 0, 0); 565 vboxProblem().cannotAttachDevice(this, m, VBoxDefs::MediumType_HardDisk, 566 field("hardDiskLocation").toString(), ideBus, 0, 0); 387 567 } 388 568 389 569 /* Attach empty CD/DVD ROM Device */ 390 m.AttachDevice 570 m.AttachDevice(ideCtrName, 1, 0, KDeviceType_DVD, QString("")); 391 571 if (!m.isOk()) 392 vboxProblem().cannotAttachDevice 572 vboxProblem().cannotAttachDevice(this, m, VBoxDefs::MediumType_DVD, QString(), ideBus, 1, 0); 393 573 394 574 /* Attach empty Floppy Device */ 395 m.AttachDevice 575 m.AttachDevice(floppyCtrName, 0, 0, KDeviceType_Floppy, QString("")); 396 576 if (!m.isOk()) 397 vboxProblem().cannotAttachDevice 577 vboxProblem().cannotAttachDevice(this, m, VBoxDefs::MediumType_Floppy, QString(), floppyBus, 0, 0); 398 578 399 579 if (m.isOk()) … … 403 583 success = true; 404 584 else 405 vboxProblem().cannotSaveMachineSettings 585 vboxProblem().cannotSaveMachineSettings(m, this); 406 586 } 407 587 … … 411 591 { 412 592 /* Unregister on failure */ 413 vbox.UnregisterMachine 593 vbox.UnregisterMachine(machineId); 414 594 if (vbox.isOk()) 415 m Machine.DeleteSettings();595 m_Machine.DeleteSettings(); 416 596 return false; 417 597 } … … 419 599 420 600 /* Ensure we don't try to delete a newly created hard disk on success */ 421 mHardDisk.detach(); 601 if (!field("hardDisk").value<CMedium>().isNull()) 602 field("hardDisk").value<CMedium>().detach(); 422 603 423 604 return true; 424 605 } 425 606 426 void VBoxNewVMWzd::ensureNewHardDiskDeleted() 427 { 428 if (!mHardDisk.isNull()) 429 { 430 /* Remember ID as it may be lost after the deletion */ 431 QString id = mHardDisk.GetId(); 432 433 bool success = false; 434 435 CProgress progress = mHardDisk.DeleteStorage(); 436 if (mHardDisk.isOk()) 437 { 438 vboxProblem().showModalProgressDialog (progress, windowTitle(), 439 parentWidget()); 440 if (progress.isOk() && progress.GetResultCode() == S_OK) 441 success = true; 442 } 443 444 if (success) 445 vboxGlobal().removeMedium (VBoxDefs::MediumType_HardDisk, id); 446 else 447 vboxProblem().cannotDeleteHardDiskStorage (this, mHardDisk, 448 progress); 449 mHardDisk.detach(); 450 } 451 } 452 607 CMachine UINewVMWzdPage5::machine() const 608 { 609 return m_Machine; 610 } 611 612 void UINewVMWzdPage5::setMachine(const CMachine &machine) 613 { 614 m_Machine = machine; 615 } -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/newvm/UINewVMWzd.h
r25265 r26079 2 2 * 3 3 * VBox frontends: Qt4 GUI ("VirtualBox"): 4 * VBoxNewVMWzd class declaration4 * UINewVMWzd class declaration 5 5 */ 6 6 7 7 /* 8 * Copyright (C) 2006-20 08Sun Microsystems, Inc.8 * Copyright (C) 2006-2010 Sun Microsystems, Inc. 9 9 * 10 10 * This file is part of VirtualBox Open Source Edition (OSE), as … … 21 21 */ 22 22 23 #ifndef __ VBoxNewVMWzd_h__24 #define __ VBoxNewVMWzd_h__23 #ifndef __UINewVMWzd_h__ 24 #define __UINewVMWzd_h__ 25 25 26 #include "QIAbstractWizard.h" 27 #include "VBoxNewVMWzd.gen.h" 26 27 /* Local includes */ 28 #include "QIWizard.h" 28 29 #include "COMDefs.h" 29 #include "QIWidgetValidator.h"30 30 #include "QIWithRetranslateUI.h" 31 31 32 class VBoxNewVMWzd : public QIWithRetranslateUI<QIAbstractWizard>, 33 public Ui::VBoxNewVMWzd 32 /* Generated includes */ 33 #include "UINewVMWzdPage1.gen.h" 34 #include "UINewVMWzdPage2.gen.h" 35 #include "UINewVMWzdPage3.gen.h" 36 #include "UINewVMWzdPage4.gen.h" 37 #include "UINewVMWzdPage5.gen.h" 38 39 class UINewVMWzd : public QIWizard 34 40 { 35 41 Q_OBJECT; … … 37 43 public: 38 44 39 VBoxNewVMWzd (QWidget *aParent = 0); 40 ~VBoxNewVMWzd(); 45 UINewVMWzd(QWidget *pParent); 41 46 42 const CMachine& machine() const; 47 const CMachine machine() const; 48 49 protected: 50 51 void retranslateUi(); 52 }; 53 54 class UINewVMWzdPage1 : public QIWizardPage, public Ui::UINewVMWzdPage1 55 { 56 Q_OBJECT; 57 58 public: 59 60 UINewVMWzdPage1(); 61 62 protected: 63 64 void retranslateUi(); 65 }; 66 67 class UINewVMWzdPage2 : public QIWizardPage, public Ui::UINewVMWzdPage2 68 { 69 Q_OBJECT; 70 71 public: 72 73 UINewVMWzdPage2(); 43 74 44 75 protected: … … 46 77 void retranslateUi(); 47 78 79 void initializePage(); 80 }; 81 82 class UINewVMWzdPage3 : public QIWizardPage, public Ui::UINewVMWzdPage3 83 { 84 Q_OBJECT; 85 86 public: 87 88 UINewVMWzdPage3(); 89 90 protected: 91 92 void retranslateUi(); 93 94 void initializePage(); 95 96 bool isComplete() const; 97 48 98 private slots: 49 99 50 void accept(); 51 void showMediaManager(); 52 void onOSTypeChanged(); 53 void slRAMValueChanged (int aValue); 54 void leRAMTextChanged (const QString &aTtext); 55 void hdTypeChanged(); 56 void revalidate (QIWidgetValidator *aWval); 57 void enableNext (const QIWidgetValidator *aWval); 58 void onPageShow(); 59 void showBackPage(); 60 void showNextPage(); 100 void ramSliderValueChanged(int iValue); 101 void ramEditorTextChanged(const QString &strText); 102 }; 103 104 class UINewVMWzdPage4 : public QIWizardPage, public Ui::UINewVMWzdPage4 105 { 106 Q_OBJECT; 107 Q_PROPERTY(CMedium hardDisk READ hardDisk WRITE setHardDisk); 108 Q_PROPERTY(QString hardDiskId READ hardDiskId WRITE setHardDiskId); 109 Q_PROPERTY(QString hardDiskName READ hardDiskName WRITE setHardDiskName); 110 Q_PROPERTY(QString hardDiskLocation READ hardDiskLocation WRITE setHardDiskLocation); 111 112 public: 113 114 UINewVMWzdPage4(); 115 116 protected: 117 118 void retranslateUi(); 119 120 void initializePage(); 121 void cleanupPage(); 122 123 bool isComplete() const; 124 bool validatePage(); 125 126 private slots: 127 128 void ensureNewHardDiskDeleted(); 129 void hardDiskSourceChanged(); 130 void getWithMediaManager(); 61 131 62 132 private: 63 133 64 bool showNewHDWizard(); 65 bool constructMachine(); 66 void ensureNewHardDiskDeleted(); 134 bool getWithNewHardDiskWizard(); 67 135 68 QIWidgetValidator *mWvalNameAndOS; 69 QIWidgetValidator *mWvalMemory; 70 QIWidgetValidator *mWvalHDD; 71 CMedium mHardDisk; 72 CMachine mMachine; 136 CMedium hardDisk() const; 137 void setHardDisk(const CMedium &hardDisk); 138 CMedium m_HardDisk; 139 140 QString hardDiskId() const; 141 void setHardDiskId(const QString &strHardDiskId); 142 QString m_strHardDiskId; 143 144 QString hardDiskName() const; 145 void setHardDiskName(const QString &strHardDiskName); 146 QString m_strHardDiskName; 147 148 QString hardDiskLocation() const; 149 void setHardDiskLocation(const QString &strHardDiskLocation); 150 QString m_strHardDiskLocation; 73 151 }; 74 152 75 #endif // __VBoxNewVMWzd_h__ 153 class UINewVMWzdPage5 : public QIWizardPage, public Ui::UINewVMWzdPage5 154 { 155 Q_OBJECT; 156 Q_PROPERTY(CMachine machine READ machine WRITE setMachine); 76 157 158 public: 159 160 UINewVMWzdPage5(); 161 162 protected: 163 164 void retranslateUi(); 165 166 void initializePage(); 167 168 bool validatePage(); 169 170 private: 171 172 bool constructMachine(); 173 174 CMachine machine() const; 175 void setMachine(const CMachine &machine); 176 CMachine m_Machine; 177 }; 178 179 Q_DECLARE_METATYPE(CMachine); 180 181 #endif // __UINewVMWzd_h__ -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/newvm/UINewVMWzdPage1.ui
r25267 r26079 2 2 <ui version="4.0"> 3 3 <comment> 4 VBox frontends: Qt4 GUI ( "VirtualBox"):4 VBox frontends: Qt4 GUI ("VirtualBox"): 5 5 6 Copyright (C) 200 8Sun Microsystems, Inc.6 Copyright (C) 2009 Sun Microsystems, Inc. 7 7 8 8 This file is part of VirtualBox Open Source Edition (OSE), as … … 18 18 additional information or have any questions. 19 19 </comment> 20 <class>VBoxNewVMWzd</class> 21 <widget class="QDialog" name="VBoxNewVMWzd"> 20 <class>UINewVMWzdPage1</class> 21 <widget class="QWidget" name="UINewVMWzdPage1"> 22 <property name="sizePolicy"> 23 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 24 <horstretch>0</horstretch> 25 <verstretch>0</verstretch> 26 </sizepolicy> 27 </property> 22 28 <property name="geometry"> 23 29 <rect> 24 30 <x>0</x> 25 31 <y>0</y> 26 <width> 516</width>27 <height>4 98</height>32 <width>600</width> 33 <height>400</height> 28 34 </rect> 29 35 </property> 30 <property name="windowTitle"> 31 <string>Create New Virtual Machine</string> 36 <property name="sizePolicy"> 37 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 38 <horstretch>0</horstretch> 39 <verstretch>0</verstretch> 40 </sizepolicy> 32 41 </property> 33 <layout class="QVBoxLayout" >34 <property name=" margin">42 <layout class="QVBoxLayout" name="m_pLayout1"> 43 <property name="bottomMargin" > 35 44 <number>0</number> 36 45 </property> 37 46 <item> 38 <widget class="Q StackedWidget" name="mPageStack">39 <property name=" currentIndex">40 < number>2</number>47 <widget class="QILabel" name="m_pPage1Text1"> 48 <property name="text"> 49 <string><p>This wizard will guide you through the steps that are necessary to create a new virtual machine for VirtualBox.</p><p>Use the <b>Next</b> button to go the next page of the wizard and the <b>Back</b> button to return to the previous page.</p></string> 41 50 </property> 42 <widget class="QWidget" name="mPageWelcome"> 43 <layout class="QVBoxLayout"> 44 <item> 45 <widget class="QLabel" name="mPageWelcomeHdr"> 46 <property name="font"> 47 <font> 48 <family>Arial</family> 49 <pointsize>12</pointsize> 50 <weight>75</weight> 51 <bold>true</bold> 52 </font> 53 </property> 54 <property name="text"> 55 <string>Welcome to the New Virtual Machine Wizard!</string> 56 </property> 57 </widget> 58 </item> 59 <item> 60 <widget class="Line" name="line11"> 61 <property name="orientation"> 62 <enum>Qt::Horizontal</enum> 63 </property> 64 </widget> 65 </item> 66 <item> 67 <layout class="QHBoxLayout"> 68 <property name="spacing"> 69 <number>10</number> 70 </property> 71 <item> 72 <widget class="QLabel" name="mLogoWelcome"> 73 <property name="sizePolicy"> 74 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 75 <horstretch>0</horstretch> 76 <verstretch>0</verstretch> 77 </sizepolicy> 78 </property> 79 <property name="autoFillBackground"> 80 <bool>true</bool> 81 </property> 82 <property name="text"> 83 <string/> 84 </property> 85 <property name="pixmap"> 86 <pixmap resource="../VirtualBox1.qrc">:/vmw_new_welcome.png</pixmap> 87 </property> 88 <property name="alignment"> 89 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 90 </property> 91 </widget> 92 </item> 93 <item> 94 <layout class="QVBoxLayout"> 95 <property name="spacing"> 96 <number>10</number> 97 </property> 98 <item> 99 <widget class="QILabel" name="mTextWelcome"> 100 <property name="sizePolicy"> 101 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 102 <horstretch>0</horstretch> 103 <verstretch>0</verstretch> 104 </sizepolicy> 105 </property> 106 <property name="minimumSize"> 107 <size> 108 <width>300</width> 109 <height>0</height> 110 </size> 111 </property> 112 <property name="text"> 113 <string><p>This wizard will guide you through the steps that are necessary to create a new virtual machine for VirtualBox.</p><p>Use the <b>Next</b> button to go the next page of the wizard and the <b>Back</b> button to return to the previous page.</p></string> 114 </property> 115 <property name="wordWrap"> 116 <bool>true</bool> 117 </property> 118 </widget> 119 </item> 120 <item> 121 <spacer> 122 <property name="orientation"> 123 <enum>Qt::Vertical</enum> 124 </property> 125 <property name="sizeHint" stdset="0"> 126 <size> 127 <width>0</width> 128 <height>0</height> 129 </size> 130 </property> 131 </spacer> 132 </item> 133 </layout> 134 </item> 135 </layout> 136 </item> 137 <item> 138 <widget class="Line" name="line12"> 139 <property name="orientation"> 140 <enum>Qt::Horizontal</enum> 141 </property> 142 </widget> 143 </item> 144 <item> 145 <layout class="QHBoxLayout"> 146 <item> 147 <spacer> 148 <property name="orientation"> 149 <enum>Qt::Horizontal</enum> 150 </property> 151 <property name="sizeHint" stdset="0"> 152 <size> 153 <width>0</width> 154 <height>0</height> 155 </size> 156 </property> 157 </spacer> 158 </item> 159 <item> 160 <widget class="QPushButton" name="mBtnBack1"> 161 <property name="enabled"> 162 <bool>false</bool> 163 </property> 164 <property name="text"> 165 <string>< &Back</string> 166 </property> 167 </widget> 168 </item> 169 <item> 170 <widget class="QPushButton" name="mBtnNext1"> 171 <property name="text"> 172 <string>&Next ></string> 173 </property> 174 </widget> 175 </item> 176 <item> 177 <spacer> 178 <property name="orientation"> 179 <enum>Qt::Horizontal</enum> 180 </property> 181 <property name="sizeType"> 182 <enum>QSizePolicy::Fixed</enum> 183 </property> 184 <property name="sizeHint" stdset="0"> 185 <size> 186 <width>5</width> 187 <height>0</height> 188 </size> 189 </property> 190 </spacer> 191 </item> 192 <item> 193 <widget class="QPushButton" name="mBtnCancel1"> 194 <property name="text"> 195 <string>Cancel</string> 196 </property> 197 </widget> 198 </item> 199 </layout> 200 </item> 201 </layout> 202 </widget> 203 <widget class="QWidget" name="mPageNameAndOS"> 204 <layout class="QVBoxLayout"> 205 <item> 206 <widget class="QLabel" name="mPageNameAndOSHdr"> 207 <property name="font"> 208 <font> 209 <family>Arial</family> 210 <pointsize>12</pointsize> 211 <weight>75</weight> 212 <bold>true</bold> 213 </font> 214 </property> 215 <property name="text"> 216 <string>VM Name and OS Type</string> 217 </property> 218 </widget> 219 </item> 220 <item> 221 <widget class="Line" name="line21"> 222 <property name="orientation"> 223 <enum>Qt::Horizontal</enum> 224 </property> 225 </widget> 226 </item> 227 <item> 228 <layout class="QHBoxLayout"> 229 <property name="spacing"> 230 <number>10</number> 231 </property> 232 <item> 233 <widget class="QLabel" name="mLogoNameAndOS"> 234 <property name="sizePolicy"> 235 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 236 <horstretch>0</horstretch> 237 <verstretch>0</verstretch> 238 </sizepolicy> 239 </property> 240 <property name="autoFillBackground"> 241 <bool>true</bool> 242 </property> 243 <property name="text"> 244 <string/> 245 </property> 246 <property name="pixmap"> 247 <pixmap resource="../VirtualBox1.qrc">:/vmw_new_welcome.png</pixmap> 248 </property> 249 <property name="alignment"> 250 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 251 </property> 252 </widget> 253 </item> 254 <item> 255 <layout class="QVBoxLayout"> 256 <property name="spacing"> 257 <number>10</number> 258 </property> 259 <item> 260 <widget class="QILabel" name="mTextNameAndOS"> 261 <property name="sizePolicy"> 262 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 263 <horstretch>0</horstretch> 264 <verstretch>0</verstretch> 265 </sizepolicy> 266 </property> 267 <property name="minimumSize"> 268 <size> 269 <width>300</width> 270 <height>0</height> 271 </size> 272 </property> 273 <property name="text"> 274 <string><p>Enter a name for the new virtual machine and select the type of the guest operating system you plan to install onto the virtual machine.</p><p>The name of the virtual machine usually indicates its software and hardware configuration. It will be used by all VirtualBox components to identify your virtual machine.</p></string> 275 </property> 276 <property name="wordWrap"> 277 <bool>true</bool> 278 </property> 279 </widget> 280 </item> 281 <item> 282 <widget class="QGroupBox" name="gbName"> 283 <property name="sizePolicy"> 284 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 285 <horstretch>0</horstretch> 286 <verstretch>0</verstretch> 287 </sizepolicy> 288 </property> 289 <property name="title"> 290 <string>N&ame</string> 291 </property> 292 <layout class="QHBoxLayout"> 293 <property name="spacing"> 294 <number>0</number> 295 </property> 296 <property name="leftMargin"> 297 <number>9</number> 298 </property> 299 <property name="topMargin"> 300 <number>4</number> 301 </property> 302 <property name="rightMargin"> 303 <number>9</number> 304 </property> 305 <property name="bottomMargin"> 306 <number>9</number> 307 </property> 308 <item> 309 <widget class="QLineEdit" name="mLeName"/> 310 </item> 311 </layout> 312 </widget> 313 </item> 314 <item> 315 <widget class="QGroupBox" name="gbOSType"> 316 <property name="sizePolicy"> 317 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 318 <horstretch>0</horstretch> 319 <verstretch>0</verstretch> 320 </sizepolicy> 321 </property> 322 <property name="title"> 323 <string>OS &Type</string> 324 </property> 325 <layout class="QHBoxLayout"> 326 <property name="topMargin"> 327 <number>4</number> 328 </property> 329 <item> 330 <widget class="VBoxOSTypeSelectorWidget" name="mOSTypeSelector" native="true"/> 331 </item> 332 </layout> 333 </widget> 334 </item> 335 <item> 336 <spacer> 337 <property name="orientation"> 338 <enum>Qt::Vertical</enum> 339 </property> 340 <property name="sizeHint" stdset="0"> 341 <size> 342 <width>0</width> 343 <height>0</height> 344 </size> 345 </property> 346 </spacer> 347 </item> 348 </layout> 349 </item> 350 </layout> 351 </item> 352 <item> 353 <widget class="Line" name="line22"> 354 <property name="orientation"> 355 <enum>Qt::Horizontal</enum> 356 </property> 357 </widget> 358 </item> 359 <item> 360 <layout class="QHBoxLayout"> 361 <item> 362 <spacer> 363 <property name="orientation"> 364 <enum>Qt::Horizontal</enum> 365 </property> 366 <property name="sizeHint" stdset="0"> 367 <size> 368 <width>0</width> 369 <height>0</height> 370 </size> 371 </property> 372 </spacer> 373 </item> 374 <item> 375 <widget class="QPushButton" name="mBtnBack2"> 376 <property name="text"> 377 <string>< &Back</string> 378 </property> 379 </widget> 380 </item> 381 <item> 382 <widget class="QPushButton" name="mBtnNext2"> 383 <property name="text"> 384 <string>&Next ></string> 385 </property> 386 </widget> 387 </item> 388 <item> 389 <spacer> 390 <property name="orientation"> 391 <enum>Qt::Horizontal</enum> 392 </property> 393 <property name="sizeType"> 394 <enum>QSizePolicy::Fixed</enum> 395 </property> 396 <property name="sizeHint" stdset="0"> 397 <size> 398 <width>5</width> 399 <height>0</height> 400 </size> 401 </property> 402 </spacer> 403 </item> 404 <item> 405 <widget class="QPushButton" name="mBtnCancel2"> 406 <property name="text"> 407 <string>Cancel</string> 408 </property> 409 </widget> 410 </item> 411 </layout> 412 </item> 413 </layout> 414 </widget> 415 <widget class="QWidget" name="mPageMemory"> 416 <layout class="QVBoxLayout"> 417 <item> 418 <widget class="QLabel" name="mPageMemoryHdr"> 419 <property name="font"> 420 <font> 421 <family>Arial</family> 422 <pointsize>12</pointsize> 423 <weight>75</weight> 424 <bold>true</bold> 425 </font> 426 </property> 427 <property name="text"> 428 <string>Memory</string> 429 </property> 430 </widget> 431 </item> 432 <item> 433 <widget class="Line" name="line31"> 434 <property name="orientation"> 435 <enum>Qt::Horizontal</enum> 436 </property> 437 </widget> 438 </item> 439 <item> 440 <layout class="QHBoxLayout"> 441 <property name="spacing"> 442 <number>10</number> 443 </property> 444 <item> 445 <widget class="QLabel" name="mLogoMemory"> 446 <property name="sizePolicy"> 447 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 448 <horstretch>0</horstretch> 449 <verstretch>0</verstretch> 450 </sizepolicy> 451 </property> 452 <property name="autoFillBackground"> 453 <bool>true</bool> 454 </property> 455 <property name="text"> 456 <string/> 457 </property> 458 <property name="pixmap"> 459 <pixmap resource="../VirtualBox1.qrc">:/vmw_new_welcome.png</pixmap> 460 </property> 461 <property name="alignment"> 462 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 463 </property> 464 </widget> 465 </item> 466 <item> 467 <layout class="QVBoxLayout"> 468 <property name="spacing"> 469 <number>10</number> 470 </property> 471 <item> 472 <widget class="QILabel" name="mTextMemory"> 473 <property name="sizePolicy"> 474 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 475 <horstretch>0</horstretch> 476 <verstretch>0</verstretch> 477 </sizepolicy> 478 </property> 479 <property name="minimumSize"> 480 <size> 481 <width>300</width> 482 <height>0</height> 483 </size> 484 </property> 485 <property name="text"> 486 <string><p>Select the amount of base memory (RAM) in megabytes to be allocated to the virtual machine.</p></string> 487 </property> 488 <property name="wordWrap"> 489 <bool>true</bool> 490 </property> 491 </widget> 492 </item> 493 <item> 494 <widget class="QILabel" name="mTextRAMBest"> 495 <property name="sizePolicy"> 496 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 497 <horstretch>0</horstretch> 498 <verstretch>0</verstretch> 499 </sizepolicy> 500 </property> 501 <property name="minimumSize"> 502 <size> 503 <width>300</width> 504 <height>0</height> 505 </size> 506 </property> 507 <property name="text"> 508 <string/> 509 </property> 510 <property name="wordWrap"> 511 <bool>true</bool> 512 </property> 513 </widget> 514 </item> 515 <item> 516 <widget class="QGroupBox" name="gbMemory"> 517 <property name="sizePolicy"> 518 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 519 <horstretch>0</horstretch> 520 <verstretch>0</verstretch> 521 </sizepolicy> 522 </property> 523 <property name="title"> 524 <string>Base &Memory Size</string> 525 </property> 526 <layout class="QGridLayout"> 527 <property name="topMargin"> 528 <number>4</number> 529 </property> 530 <item row="0" column="0" colspan="3"> 531 <widget class="VBoxGuestRAMSlider" name="mSlRAM"> 532 <property name="sizePolicy"> 533 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 534 <horstretch>0</horstretch> 535 <verstretch>0</verstretch> 536 </sizepolicy> 537 </property> 538 <property name="minimumSize"> 539 <size> 540 <width>0</width> 541 <height>0</height> 542 </size> 543 </property> 544 <property name="orientation"> 545 <enum>Qt::Horizontal</enum> 546 </property> 547 <property name="tickPosition"> 548 <enum>QSlider::TicksBelow</enum> 549 </property> 550 </widget> 551 </item> 552 <item row="0" column="3"> 553 <widget class="QILineEdit" name="mLeRAM"> 554 <property name="sizePolicy"> 555 <sizepolicy hsizetype="Preferred" vsizetype="Fixed"> 556 <horstretch>0</horstretch> 557 <verstretch>0</verstretch> 558 </sizepolicy> 559 </property> 560 </widget> 561 </item> 562 <item row="0" column="4"> 563 <widget class="QLabel" name="txRAM"> 564 <property name="sizePolicy"> 565 <sizepolicy hsizetype="Fixed" vsizetype="Fixed"> 566 <horstretch>0</horstretch> 567 <verstretch>0</verstretch> 568 </sizepolicy> 569 </property> 570 <property name="text"> 571 <string>MB</string> 572 </property> 573 </widget> 574 </item> 575 <item row="1" column="0"> 576 <widget class="QLabel" name="mTxRAMMin"> 577 <property name="sizePolicy"> 578 <sizepolicy hsizetype="Minimum" vsizetype="Preferred"> 579 <horstretch>0</horstretch> 580 <verstretch>0</verstretch> 581 </sizepolicy> 582 </property> 583 <property name="text"> 584 <string/> 585 </property> 586 <property name="alignment"> 587 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 588 </property> 589 </widget> 590 </item> 591 <item row="1" column="2"> 592 <widget class="QLabel" name="mTxRAMMax"> 593 <property name="sizePolicy"> 594 <sizepolicy hsizetype="Minimum" vsizetype="Preferred"> 595 <horstretch>0</horstretch> 596 <verstretch>0</verstretch> 597 </sizepolicy> 598 </property> 599 <property name="text"> 600 <string/> 601 </property> 602 <property name="alignment"> 603 <set>Qt::AlignRight|Qt::AlignTop|Qt::AlignTrailing</set> 604 </property> 605 </widget> 606 </item> 607 <item row="1" column="1"> 608 <spacer> 609 <property name="orientation"> 610 <enum>Qt::Horizontal</enum> 611 </property> 612 <property name="sizeHint" stdset="0"> 613 <size> 614 <width>40</width> 615 <height>5</height> 616 </size> 617 </property> 618 </spacer> 619 </item> 620 </layout> 621 </widget> 622 </item> 623 <item> 624 <spacer> 625 <property name="orientation"> 626 <enum>Qt::Vertical</enum> 627 </property> 628 <property name="sizeHint" stdset="0"> 629 <size> 630 <width>0</width> 631 <height>0</height> 632 </size> 633 </property> 634 </spacer> 635 </item> 636 </layout> 637 </item> 638 </layout> 639 </item> 640 <item> 641 <widget class="Line" name="line32"> 642 <property name="orientation"> 643 <enum>Qt::Horizontal</enum> 644 </property> 645 </widget> 646 </item> 647 <item> 648 <layout class="QHBoxLayout"> 649 <item> 650 <spacer> 651 <property name="orientation"> 652 <enum>Qt::Horizontal</enum> 653 </property> 654 <property name="sizeHint" stdset="0"> 655 <size> 656 <width>0</width> 657 <height>0</height> 658 </size> 659 </property> 660 </spacer> 661 </item> 662 <item> 663 <widget class="QPushButton" name="mBtnBack3"> 664 <property name="text"> 665 <string>< &Back</string> 666 </property> 667 </widget> 668 </item> 669 <item> 670 <widget class="QPushButton" name="mBtnNext3"> 671 <property name="text"> 672 <string>&Next ></string> 673 </property> 674 </widget> 675 </item> 676 <item> 677 <spacer> 678 <property name="orientation"> 679 <enum>Qt::Horizontal</enum> 680 </property> 681 <property name="sizeType"> 682 <enum>QSizePolicy::Fixed</enum> 683 </property> 684 <property name="sizeHint" stdset="0"> 685 <size> 686 <width>5</width> 687 <height>0</height> 688 </size> 689 </property> 690 </spacer> 691 </item> 692 <item> 693 <widget class="QPushButton" name="mBtnCancel3"> 694 <property name="text"> 695 <string>Cancel</string> 696 </property> 697 </widget> 698 </item> 699 </layout> 700 </item> 701 </layout> 702 </widget> 703 <widget class="QWidget" name="mPageHDD"> 704 <layout class="QVBoxLayout"> 705 <item> 706 <widget class="QLabel" name="mPageHDDHdr"> 707 <property name="font"> 708 <font> 709 <family>Arial</family> 710 <pointsize>12</pointsize> 711 <weight>75</weight> 712 <bold>true</bold> 713 </font> 714 </property> 715 <property name="text"> 716 <string>Virtual Hard Disk</string> 717 </property> 718 </widget> 719 </item> 720 <item> 721 <widget class="Line" name="line41"> 722 <property name="orientation"> 723 <enum>Qt::Horizontal</enum> 724 </property> 725 </widget> 726 </item> 727 <item> 728 <layout class="QHBoxLayout"> 729 <property name="spacing"> 730 <number>10</number> 731 </property> 732 <item> 733 <widget class="QLabel" name="mLogoHDD"> 734 <property name="sizePolicy"> 735 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 736 <horstretch>0</horstretch> 737 <verstretch>0</verstretch> 738 </sizepolicy> 739 </property> 740 <property name="autoFillBackground"> 741 <bool>true</bool> 742 </property> 743 <property name="text"> 744 <string/> 745 </property> 746 <property name="pixmap"> 747 <pixmap resource="../VirtualBox1.qrc">:/vmw_new_welcome.png</pixmap> 748 </property> 749 <property name="alignment"> 750 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 751 </property> 752 </widget> 753 </item> 754 <item> 755 <layout class="QVBoxLayout"> 756 <property name="spacing"> 757 <number>10</number> 758 </property> 759 <item> 760 <widget class="QILabel" name="mTextVDI"> 761 <property name="sizePolicy"> 762 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 763 <horstretch>0</horstretch> 764 <verstretch>0</verstretch> 765 </sizepolicy> 766 </property> 767 <property name="minimumSize"> 768 <size> 769 <width>300</width> 770 <height>0</height> 771 </size> 772 </property> 773 <property name="text"> 774 <string><p>Select a hard disk image to be used as the boot hard disk of the virtual machine. You can either create a new hard disk using the <b>New</b> button or select an existing hard disk image from the drop-down list or by pressing the <b>Existing</b> button (to invoke the Virtual Media Manager dialog).</p><p>If you need a more complicated hard disk setup, you can also skip this step and attach hard disks later using the VM Settings dialog.</p></string> 775 </property> 776 <property name="wordWrap"> 777 <bool>true</bool> 778 </property> 779 </widget> 780 </item> 781 <item> 782 <widget class="QILabel" name="mTextVDIBest"> 783 <property name="sizePolicy"> 784 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 785 <horstretch>0</horstretch> 786 <verstretch>0</verstretch> 787 </sizepolicy> 788 </property> 789 <property name="minimumSize"> 790 <size> 791 <width>300</width> 792 <height>0</height> 793 </size> 794 </property> 795 <property name="text"> 796 <string/> 797 </property> 798 <property name="wordWrap"> 799 <bool>true</bool> 800 </property> 801 </widget> 802 </item> 803 <item> 804 <widget class="QGroupBox" name="mGbHDA"> 805 <property name="sizePolicy"> 806 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 807 <horstretch>0</horstretch> 808 <verstretch>0</verstretch> 809 </sizepolicy> 810 </property> 811 <property name="title"> 812 <string>Boot Hard &Disk (Primary Master)</string> 813 </property> 814 <property name="checkable"> 815 <bool>true</bool> 816 </property> 817 <layout class="QGridLayout"> 818 <item row="0" column="0" colspan="3"> 819 <widget class="QRadioButton" name="mNewVDIRadio"> 820 <property name="text"> 821 <string>&Create new hard disk</string> 822 </property> 823 <property name="checked"> 824 <bool>true</bool> 825 </property> 826 </widget> 827 </item> 828 <item row="1" column="0" colspan="3"> 829 <widget class="QRadioButton" name="mExistRadio"> 830 <property name="text"> 831 <string>&Use existing hard disk</string> 832 </property> 833 </widget> 834 </item> 835 <item row="2" column="1"> 836 <widget class="VBoxMediaComboBox" name="mHDCombo"> 837 <property name="sizePolicy"> 838 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 839 <horstretch>0</horstretch> 840 <verstretch>0</verstretch> 841 </sizepolicy> 842 </property> 843 </widget> 844 </item> 845 <item row="2" column="2"> 846 <widget class="QToolButton" name="mTbVmm"> 847 <property name="autoRaise"> 848 <bool>true</bool> 849 </property> 850 </widget> 851 </item> 852 </layout> 853 </widget> 854 </item> 855 <item> 856 <spacer> 857 <property name="orientation"> 858 <enum>Qt::Vertical</enum> 859 </property> 860 <property name="sizeHint" stdset="0"> 861 <size> 862 <width>0</width> 863 <height>0</height> 864 </size> 865 </property> 866 </spacer> 867 </item> 868 </layout> 869 </item> 870 </layout> 871 </item> 872 <item> 873 <widget class="Line" name="line42"> 874 <property name="orientation"> 875 <enum>Qt::Horizontal</enum> 876 </property> 877 </widget> 878 </item> 879 <item> 880 <layout class="QHBoxLayout"> 881 <item> 882 <spacer> 883 <property name="orientation"> 884 <enum>Qt::Horizontal</enum> 885 </property> 886 <property name="sizeHint" stdset="0"> 887 <size> 888 <width>0</width> 889 <height>0</height> 890 </size> 891 </property> 892 </spacer> 893 </item> 894 <item> 895 <widget class="QPushButton" name="mBtnBack4"> 896 <property name="text"> 897 <string>< &Back</string> 898 </property> 899 </widget> 900 </item> 901 <item> 902 <widget class="QPushButton" name="mBtnNext4"> 903 <property name="text"> 904 <string>&Next ></string> 905 </property> 906 </widget> 907 </item> 908 <item> 909 <spacer> 910 <property name="orientation"> 911 <enum>Qt::Horizontal</enum> 912 </property> 913 <property name="sizeType"> 914 <enum>QSizePolicy::Fixed</enum> 915 </property> 916 <property name="sizeHint" stdset="0"> 917 <size> 918 <width>5</width> 919 <height>0</height> 920 </size> 921 </property> 922 </spacer> 923 </item> 924 <item> 925 <widget class="QPushButton" name="mBtnCancel4"> 926 <property name="text"> 927 <string>Cancel</string> 928 </property> 929 </widget> 930 </item> 931 </layout> 932 </item> 933 </layout> 934 </widget> 935 <widget class="QWidget" name="mPageSummary"> 936 <layout class="QVBoxLayout"> 937 <item> 938 <widget class="QLabel" name="mPageSummaryHdr"> 939 <property name="font"> 940 <font> 941 <family>Arial</family> 942 <pointsize>12</pointsize> 943 <weight>75</weight> 944 <bold>true</bold> 945 </font> 946 </property> 947 <property name="text"> 948 <string>Summary</string> 949 </property> 950 </widget> 951 </item> 952 <item> 953 <widget class="Line" name="line51"> 954 <property name="orientation"> 955 <enum>Qt::Horizontal</enum> 956 </property> 957 </widget> 958 </item> 959 <item> 960 <layout class="QHBoxLayout"> 961 <property name="spacing"> 962 <number>10</number> 963 </property> 964 <item> 965 <widget class="QLabel" name="mLogoSummary"> 966 <property name="sizePolicy"> 967 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 968 <horstretch>0</horstretch> 969 <verstretch>0</verstretch> 970 </sizepolicy> 971 </property> 972 <property name="autoFillBackground"> 973 <bool>true</bool> 974 </property> 975 <property name="text"> 976 <string/> 977 </property> 978 <property name="pixmap"> 979 <pixmap resource="../VirtualBox1.qrc">:/vmw_new_welcome.png</pixmap> 980 </property> 981 <property name="alignment"> 982 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 983 </property> 984 </widget> 985 </item> 986 <item> 987 <layout class="QVBoxLayout"> 988 <property name="spacing"> 989 <number>10</number> 990 </property> 991 <item> 992 <widget class="QILabel" name="mTextSummaryHdr"> 993 <property name="sizePolicy"> 994 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 995 <horstretch>0</horstretch> 996 <verstretch>0</verstretch> 997 </sizepolicy> 998 </property> 999 <property name="minimumSize"> 1000 <size> 1001 <width>300</width> 1002 <height>0</height> 1003 </size> 1004 </property> 1005 <property name="text"> 1006 <string><p>You are going to create a new virtual machine with the following parameters:</p></string> 1007 </property> 1008 <property name="wordWrap"> 1009 <bool>true</bool> 1010 </property> 1011 </widget> 1012 </item> 1013 <item> 1014 <widget class="QITextEdit" name="mTeSummary"> 1015 <property name="sizePolicy"> 1016 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 1017 <horstretch>0</horstretch> 1018 <verstretch>0</verstretch> 1019 </sizepolicy> 1020 </property> 1021 <property name="minimumSize"> 1022 <size> 1023 <width>300</width> 1024 <height>0</height> 1025 </size> 1026 </property> 1027 <property name="frameShape"> 1028 <enum>QFrame::NoFrame</enum> 1029 </property> 1030 <property name="autoFormatting"> 1031 <set>QTextEdit::AutoAll</set> 1032 </property> 1033 <property name="readOnly"> 1034 <bool>true</bool> 1035 </property> 1036 </widget> 1037 </item> 1038 <item> 1039 <widget class="QILabel" name="mTextSummaryFtr"> 1040 <property name="sizePolicy"> 1041 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 1042 <horstretch>0</horstretch> 1043 <verstretch>0</verstretch> 1044 </sizepolicy> 1045 </property> 1046 <property name="minimumSize"> 1047 <size> 1048 <width>300</width> 1049 <height>0</height> 1050 </size> 1051 </property> 1052 <property name="text"> 1053 <string><p>If the above is correct press the <b>Finish</b> button. Once you press it, a new virtual machine will be created. </p><p>Note that you can alter these and all other setting of the created virtual machine at any time using the <b>Settings</b> dialog accessible through the menu of the main window.</p></string> 1054 </property> 1055 <property name="wordWrap"> 1056 <bool>true</bool> 1057 </property> 1058 </widget> 1059 </item> 1060 <item> 1061 <spacer> 1062 <property name="orientation"> 1063 <enum>Qt::Vertical</enum> 1064 </property> 1065 <property name="sizeType"> 1066 <enum>QSizePolicy::Expanding</enum> 1067 </property> 1068 <property name="sizeHint" stdset="0"> 1069 <size> 1070 <width>0</width> 1071 <height>0</height> 1072 </size> 1073 </property> 1074 </spacer> 1075 </item> 1076 </layout> 1077 </item> 1078 </layout> 1079 </item> 1080 <item> 1081 <widget class="Line" name="line52"> 1082 <property name="orientation"> 1083 <enum>Qt::Horizontal</enum> 1084 </property> 1085 </widget> 1086 </item> 1087 <item> 1088 <layout class="QHBoxLayout"> 1089 <item> 1090 <spacer> 1091 <property name="orientation"> 1092 <enum>Qt::Horizontal</enum> 1093 </property> 1094 <property name="sizeHint" stdset="0"> 1095 <size> 1096 <width>0</width> 1097 <height>0</height> 1098 </size> 1099 </property> 1100 </spacer> 1101 </item> 1102 <item> 1103 <widget class="QPushButton" name="mBtnBack5"> 1104 <property name="text"> 1105 <string>< &Back</string> 1106 </property> 1107 </widget> 1108 </item> 1109 <item> 1110 <widget class="QPushButton" name="mBtnFinish"> 1111 <property name="text"> 1112 <string>&Finish</string> 1113 </property> 1114 </widget> 1115 </item> 1116 <item> 1117 <spacer> 1118 <property name="orientation"> 1119 <enum>Qt::Horizontal</enum> 1120 </property> 1121 <property name="sizeType"> 1122 <enum>QSizePolicy::Fixed</enum> 1123 </property> 1124 <property name="sizeHint" stdset="0"> 1125 <size> 1126 <width>5</width> 1127 <height>0</height> 1128 </size> 1129 </property> 1130 </spacer> 1131 </item> 1132 <item> 1133 <widget class="QPushButton" name="mBtnCancel5"> 1134 <property name="text"> 1135 <string>Cancel</string> 1136 </property> 1137 </widget> 1138 </item> 1139 </layout> 1140 </item> 1141 </layout> 1142 </widget> 51 <property name="wordWrap"> 52 <bool>true</bool> 53 </property> 1143 54 </widget> 55 </item> 56 <item> 57 <spacer name="m_pSpacer1"> 58 <property name="sizeHint" stdset="0"> 59 <size> 60 <width>0</width> 61 <height>0</height> 62 </size> 63 </property> 64 </spacer> 1144 65 </item> 1145 66 </layout> … … 1151 72 <header>QILabel.h</header> 1152 73 </customwidget> 1153 <customwidget>1154 <class>VBoxOSTypeSelectorWidget</class>1155 <extends>QWidget</extends>1156 <header>VBoxOSTypeSelectorWidget.h</header>1157 </customwidget>1158 <customwidget>1159 <class>VBoxMediaComboBox</class>1160 <extends>QComboBox</extends>1161 <header>VBoxMediaComboBox.h</header>1162 </customwidget>1163 <customwidget>1164 <class>QITextEdit</class>1165 <extends>QTextEdit</extends>1166 <header>QIAbstractWizard.h</header>1167 </customwidget>1168 <customwidget>1169 <class>QILineEdit</class>1170 <extends>QLineEdit</extends>1171 <header>QILineEdit.h</header>1172 </customwidget>1173 <customwidget>1174 <class>QIAdvancedSlider</class>1175 <extends>QSlider</extends>1176 <header>QIAdvancedSlider.h</header>1177 </customwidget>1178 <customwidget>1179 <class>VBoxGuestRAMSlider</class>1180 <extends>QIAdvancedSlider</extends>1181 <header>VBoxGuestRAMSlider.h</header>1182 </customwidget>1183 74 </customwidgets> 1184 <tabstops> 1185 <tabstop>mBtnNext1</tabstop> 1186 <tabstop>mBtnCancel1</tabstop> 1187 <tabstop>mLeName</tabstop> 1188 <tabstop>mOSTypeSelector</tabstop> 1189 <tabstop>mBtnBack2</tabstop> 1190 <tabstop>mBtnNext2</tabstop> 1191 <tabstop>mBtnCancel2</tabstop> 1192 <tabstop>mSlRAM</tabstop> 1193 <tabstop>mLeRAM</tabstop> 1194 <tabstop>mBtnBack3</tabstop> 1195 <tabstop>mBtnNext3</tabstop> 1196 <tabstop>mBtnCancel3</tabstop> 1197 <tabstop>mNewVDIRadio</tabstop> 1198 <tabstop>mExistRadio</tabstop> 1199 <tabstop>mHDCombo</tabstop> 1200 <tabstop>mTbVmm</tabstop> 1201 <tabstop>mBtnBack4</tabstop> 1202 <tabstop>mBtnNext4</tabstop> 1203 <tabstop>mBtnCancel4</tabstop> 1204 <tabstop>mBtnBack5</tabstop> 1205 <tabstop>mBtnFinish</tabstop> 1206 <tabstop>mBtnCancel5</tabstop> 1207 </tabstops> 1208 <resources> 1209 <include location="../VirtualBox1.qrc"/> 1210 </resources> 75 <resources/> 1211 76 <connections/> 1212 77 </ui> -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/newvm/UINewVMWzdPage2.ui
r25267 r26079 2 2 <ui version="4.0"> 3 3 <comment> 4 VBox frontends: Qt4 GUI ( "VirtualBox"):4 VBox frontends: Qt4 GUI ("VirtualBox"): 5 5 6 Copyright (C) 200 8Sun Microsystems, Inc.6 Copyright (C) 2009 Sun Microsystems, Inc. 7 7 8 8 This file is part of VirtualBox Open Source Edition (OSE), as … … 18 18 additional information or have any questions. 19 19 </comment> 20 <class>VBoxNewVMWzd</class> 21 <widget class="QDialog" name="VBoxNewVMWzd"> 20 <class>UINewVMWzdPage2</class> 21 <widget class="QWidget" name="UINewVMWzdPage2"> 22 <property name="sizePolicy"> 23 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 24 <horstretch>0</horstretch> 25 <verstretch>0</verstretch> 26 </sizepolicy> 27 </property> 22 28 <property name="geometry"> 23 29 <rect> 24 30 <x>0</x> 25 31 <y>0</y> 26 <width> 516</width>27 <height>4 98</height>32 <width>600</width> 33 <height>400</height> 28 34 </rect> 29 35 </property> 30 <property name="windowTitle"> 31 <string>Create New Virtual Machine</string> 36 <property name="sizePolicy"> 37 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 38 <horstretch>0</horstretch> 39 <verstretch>0</verstretch> 40 </sizepolicy> 32 41 </property> 33 <layout class="QVBoxLayout" >34 <property name=" margin">42 <layout class="QVBoxLayout" name="m_pLayout1"> 43 <property name="bottomMargin" > 35 44 <number>0</number> 36 45 </property> 37 46 <item> 38 <widget class="Q StackedWidget" name="mPageStack">39 <property name=" currentIndex">40 < number>2</number>47 <widget class="QILabel" name="m_pPage2Text1"> 48 <property name="text"> 49 <string><p>Enter a name for the new virtual machine and select the type of the guest operating system you plan to install onto the virtual machine.</p><p>The name of the virtual machine usually indicates its software and hardware configuration. It will be used by all VirtualBox components to identify your virtual machine.</p></string> 41 50 </property> 42 <widget class="QWidget" name="mPageWelcome"> 43 <layout class="QVBoxLayout"> 44 <item> 45 <widget class="QLabel" name="mPageWelcomeHdr"> 46 <property name="font"> 47 <font> 48 <family>Arial</family> 49 <pointsize>12</pointsize> 50 <weight>75</weight> 51 <bold>true</bold> 52 </font> 53 </property> 54 <property name="text"> 55 <string>Welcome to the New Virtual Machine Wizard!</string> 56 </property> 57 </widget> 58 </item> 59 <item> 60 <widget class="Line" name="line11"> 61 <property name="orientation"> 62 <enum>Qt::Horizontal</enum> 63 </property> 64 </widget> 65 </item> 66 <item> 67 <layout class="QHBoxLayout"> 68 <property name="spacing"> 69 <number>10</number> 70 </property> 71 <item> 72 <widget class="QLabel" name="mLogoWelcome"> 73 <property name="sizePolicy"> 74 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 75 <horstretch>0</horstretch> 76 <verstretch>0</verstretch> 77 </sizepolicy> 78 </property> 79 <property name="autoFillBackground"> 80 <bool>true</bool> 81 </property> 82 <property name="text"> 83 <string/> 84 </property> 85 <property name="pixmap"> 86 <pixmap resource="../VirtualBox1.qrc">:/vmw_new_welcome.png</pixmap> 87 </property> 88 <property name="alignment"> 89 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 90 </property> 91 </widget> 92 </item> 93 <item> 94 <layout class="QVBoxLayout"> 95 <property name="spacing"> 96 <number>10</number> 97 </property> 98 <item> 99 <widget class="QILabel" name="mTextWelcome"> 100 <property name="sizePolicy"> 101 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 102 <horstretch>0</horstretch> 103 <verstretch>0</verstretch> 104 </sizepolicy> 105 </property> 106 <property name="minimumSize"> 107 <size> 108 <width>300</width> 109 <height>0</height> 110 </size> 111 </property> 112 <property name="text"> 113 <string><p>This wizard will guide you through the steps that are necessary to create a new virtual machine for VirtualBox.</p><p>Use the <b>Next</b> button to go the next page of the wizard and the <b>Back</b> button to return to the previous page.</p></string> 114 </property> 115 <property name="wordWrap"> 116 <bool>true</bool> 117 </property> 118 </widget> 119 </item> 120 <item> 121 <spacer> 122 <property name="orientation"> 123 <enum>Qt::Vertical</enum> 124 </property> 125 <property name="sizeHint" stdset="0"> 126 <size> 127 <width>0</width> 128 <height>0</height> 129 </size> 130 </property> 131 </spacer> 132 </item> 133 </layout> 134 </item> 135 </layout> 136 </item> 137 <item> 138 <widget class="Line" name="line12"> 139 <property name="orientation"> 140 <enum>Qt::Horizontal</enum> 141 </property> 142 </widget> 143 </item> 144 <item> 145 <layout class="QHBoxLayout"> 146 <item> 147 <spacer> 148 <property name="orientation"> 149 <enum>Qt::Horizontal</enum> 150 </property> 151 <property name="sizeHint" stdset="0"> 152 <size> 153 <width>0</width> 154 <height>0</height> 155 </size> 156 </property> 157 </spacer> 158 </item> 159 <item> 160 <widget class="QPushButton" name="mBtnBack1"> 161 <property name="enabled"> 162 <bool>false</bool> 163 </property> 164 <property name="text"> 165 <string>< &Back</string> 166 </property> 167 </widget> 168 </item> 169 <item> 170 <widget class="QPushButton" name="mBtnNext1"> 171 <property name="text"> 172 <string>&Next ></string> 173 </property> 174 </widget> 175 </item> 176 <item> 177 <spacer> 178 <property name="orientation"> 179 <enum>Qt::Horizontal</enum> 180 </property> 181 <property name="sizeType"> 182 <enum>QSizePolicy::Fixed</enum> 183 </property> 184 <property name="sizeHint" stdset="0"> 185 <size> 186 <width>5</width> 187 <height>0</height> 188 </size> 189 </property> 190 </spacer> 191 </item> 192 <item> 193 <widget class="QPushButton" name="mBtnCancel1"> 194 <property name="text"> 195 <string>Cancel</string> 196 </property> 197 </widget> 198 </item> 199 </layout> 200 </item> 201 </layout> 202 </widget> 203 <widget class="QWidget" name="mPageNameAndOS"> 204 <layout class="QVBoxLayout"> 205 <item> 206 <widget class="QLabel" name="mPageNameAndOSHdr"> 207 <property name="font"> 208 <font> 209 <family>Arial</family> 210 <pointsize>12</pointsize> 211 <weight>75</weight> 212 <bold>true</bold> 213 </font> 214 </property> 215 <property name="text"> 216 <string>VM Name and OS Type</string> 217 </property> 218 </widget> 219 </item> 220 <item> 221 <widget class="Line" name="line21"> 222 <property name="orientation"> 223 <enum>Qt::Horizontal</enum> 224 </property> 225 </widget> 226 </item> 227 <item> 228 <layout class="QHBoxLayout"> 229 <property name="spacing"> 230 <number>10</number> 231 </property> 232 <item> 233 <widget class="QLabel" name="mLogoNameAndOS"> 234 <property name="sizePolicy"> 235 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 236 <horstretch>0</horstretch> 237 <verstretch>0</verstretch> 238 </sizepolicy> 239 </property> 240 <property name="autoFillBackground"> 241 <bool>true</bool> 242 </property> 243 <property name="text"> 244 <string/> 245 </property> 246 <property name="pixmap"> 247 <pixmap resource="../VirtualBox1.qrc">:/vmw_new_welcome.png</pixmap> 248 </property> 249 <property name="alignment"> 250 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 251 </property> 252 </widget> 253 </item> 254 <item> 255 <layout class="QVBoxLayout"> 256 <property name="spacing"> 257 <number>10</number> 258 </property> 259 <item> 260 <widget class="QILabel" name="mTextNameAndOS"> 261 <property name="sizePolicy"> 262 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 263 <horstretch>0</horstretch> 264 <verstretch>0</verstretch> 265 </sizepolicy> 266 </property> 267 <property name="minimumSize"> 268 <size> 269 <width>300</width> 270 <height>0</height> 271 </size> 272 </property> 273 <property name="text"> 274 <string><p>Enter a name for the new virtual machine and select the type of the guest operating system you plan to install onto the virtual machine.</p><p>The name of the virtual machine usually indicates its software and hardware configuration. It will be used by all VirtualBox components to identify your virtual machine.</p></string> 275 </property> 276 <property name="wordWrap"> 277 <bool>true</bool> 278 </property> 279 </widget> 280 </item> 281 <item> 282 <widget class="QGroupBox" name="gbName"> 283 <property name="sizePolicy"> 284 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 285 <horstretch>0</horstretch> 286 <verstretch>0</verstretch> 287 </sizepolicy> 288 </property> 289 <property name="title"> 290 <string>N&ame</string> 291 </property> 292 <layout class="QHBoxLayout"> 293 <property name="spacing"> 294 <number>0</number> 295 </property> 296 <property name="leftMargin"> 297 <number>9</number> 298 </property> 299 <property name="topMargin"> 300 <number>4</number> 301 </property> 302 <property name="rightMargin"> 303 <number>9</number> 304 </property> 305 <property name="bottomMargin"> 306 <number>9</number> 307 </property> 308 <item> 309 <widget class="QLineEdit" name="mLeName"/> 310 </item> 311 </layout> 312 </widget> 313 </item> 314 <item> 315 <widget class="QGroupBox" name="gbOSType"> 316 <property name="sizePolicy"> 317 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 318 <horstretch>0</horstretch> 319 <verstretch>0</verstretch> 320 </sizepolicy> 321 </property> 322 <property name="title"> 323 <string>OS &Type</string> 324 </property> 325 <layout class="QHBoxLayout"> 326 <property name="topMargin"> 327 <number>4</number> 328 </property> 329 <item> 330 <widget class="VBoxOSTypeSelectorWidget" name="mOSTypeSelector" native="true"/> 331 </item> 332 </layout> 333 </widget> 334 </item> 335 <item> 336 <spacer> 337 <property name="orientation"> 338 <enum>Qt::Vertical</enum> 339 </property> 340 <property name="sizeHint" stdset="0"> 341 <size> 342 <width>0</width> 343 <height>0</height> 344 </size> 345 </property> 346 </spacer> 347 </item> 348 </layout> 349 </item> 350 </layout> 351 </item> 352 <item> 353 <widget class="Line" name="line22"> 354 <property name="orientation"> 355 <enum>Qt::Horizontal</enum> 356 </property> 357 </widget> 358 </item> 359 <item> 360 <layout class="QHBoxLayout"> 361 <item> 362 <spacer> 363 <property name="orientation"> 364 <enum>Qt::Horizontal</enum> 365 </property> 366 <property name="sizeHint" stdset="0"> 367 <size> 368 <width>0</width> 369 <height>0</height> 370 </size> 371 </property> 372 </spacer> 373 </item> 374 <item> 375 <widget class="QPushButton" name="mBtnBack2"> 376 <property name="text"> 377 <string>< &Back</string> 378 </property> 379 </widget> 380 </item> 381 <item> 382 <widget class="QPushButton" name="mBtnNext2"> 383 <property name="text"> 384 <string>&Next ></string> 385 </property> 386 </widget> 387 </item> 388 <item> 389 <spacer> 390 <property name="orientation"> 391 <enum>Qt::Horizontal</enum> 392 </property> 393 <property name="sizeType"> 394 <enum>QSizePolicy::Fixed</enum> 395 </property> 396 <property name="sizeHint" stdset="0"> 397 <size> 398 <width>5</width> 399 <height>0</height> 400 </size> 401 </property> 402 </spacer> 403 </item> 404 <item> 405 <widget class="QPushButton" name="mBtnCancel2"> 406 <property name="text"> 407 <string>Cancel</string> 408 </property> 409 </widget> 410 </item> 411 </layout> 412 </item> 413 </layout> 414 </widget> 415 <widget class="QWidget" name="mPageMemory"> 416 <layout class="QVBoxLayout"> 417 <item> 418 <widget class="QLabel" name="mPageMemoryHdr"> 419 <property name="font"> 420 <font> 421 <family>Arial</family> 422 <pointsize>12</pointsize> 423 <weight>75</weight> 424 <bold>true</bold> 425 </font> 426 </property> 427 <property name="text"> 428 <string>Memory</string> 429 </property> 430 </widget> 431 </item> 432 <item> 433 <widget class="Line" name="line31"> 434 <property name="orientation"> 435 <enum>Qt::Horizontal</enum> 436 </property> 437 </widget> 438 </item> 439 <item> 440 <layout class="QHBoxLayout"> 441 <property name="spacing"> 442 <number>10</number> 443 </property> 444 <item> 445 <widget class="QLabel" name="mLogoMemory"> 446 <property name="sizePolicy"> 447 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 448 <horstretch>0</horstretch> 449 <verstretch>0</verstretch> 450 </sizepolicy> 451 </property> 452 <property name="autoFillBackground"> 453 <bool>true</bool> 454 </property> 455 <property name="text"> 456 <string/> 457 </property> 458 <property name="pixmap"> 459 <pixmap resource="../VirtualBox1.qrc">:/vmw_new_welcome.png</pixmap> 460 </property> 461 <property name="alignment"> 462 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 463 </property> 464 </widget> 465 </item> 466 <item> 467 <layout class="QVBoxLayout"> 468 <property name="spacing"> 469 <number>10</number> 470 </property> 471 <item> 472 <widget class="QILabel" name="mTextMemory"> 473 <property name="sizePolicy"> 474 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 475 <horstretch>0</horstretch> 476 <verstretch>0</verstretch> 477 </sizepolicy> 478 </property> 479 <property name="minimumSize"> 480 <size> 481 <width>300</width> 482 <height>0</height> 483 </size> 484 </property> 485 <property name="text"> 486 <string><p>Select the amount of base memory (RAM) in megabytes to be allocated to the virtual machine.</p></string> 487 </property> 488 <property name="wordWrap"> 489 <bool>true</bool> 490 </property> 491 </widget> 492 </item> 493 <item> 494 <widget class="QILabel" name="mTextRAMBest"> 495 <property name="sizePolicy"> 496 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 497 <horstretch>0</horstretch> 498 <verstretch>0</verstretch> 499 </sizepolicy> 500 </property> 501 <property name="minimumSize"> 502 <size> 503 <width>300</width> 504 <height>0</height> 505 </size> 506 </property> 507 <property name="text"> 508 <string/> 509 </property> 510 <property name="wordWrap"> 511 <bool>true</bool> 512 </property> 513 </widget> 514 </item> 515 <item> 516 <widget class="QGroupBox" name="gbMemory"> 517 <property name="sizePolicy"> 518 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 519 <horstretch>0</horstretch> 520 <verstretch>0</verstretch> 521 </sizepolicy> 522 </property> 523 <property name="title"> 524 <string>Base &Memory Size</string> 525 </property> 526 <layout class="QGridLayout"> 527 <property name="topMargin"> 528 <number>4</number> 529 </property> 530 <item row="0" column="0" colspan="3"> 531 <widget class="VBoxGuestRAMSlider" name="mSlRAM"> 532 <property name="sizePolicy"> 533 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 534 <horstretch>0</horstretch> 535 <verstretch>0</verstretch> 536 </sizepolicy> 537 </property> 538 <property name="minimumSize"> 539 <size> 540 <width>0</width> 541 <height>0</height> 542 </size> 543 </property> 544 <property name="orientation"> 545 <enum>Qt::Horizontal</enum> 546 </property> 547 <property name="tickPosition"> 548 <enum>QSlider::TicksBelow</enum> 549 </property> 550 </widget> 551 </item> 552 <item row="0" column="3"> 553 <widget class="QILineEdit" name="mLeRAM"> 554 <property name="sizePolicy"> 555 <sizepolicy hsizetype="Preferred" vsizetype="Fixed"> 556 <horstretch>0</horstretch> 557 <verstretch>0</verstretch> 558 </sizepolicy> 559 </property> 560 </widget> 561 </item> 562 <item row="0" column="4"> 563 <widget class="QLabel" name="txRAM"> 564 <property name="sizePolicy"> 565 <sizepolicy hsizetype="Fixed" vsizetype="Fixed"> 566 <horstretch>0</horstretch> 567 <verstretch>0</verstretch> 568 </sizepolicy> 569 </property> 570 <property name="text"> 571 <string>MB</string> 572 </property> 573 </widget> 574 </item> 575 <item row="1" column="0"> 576 <widget class="QLabel" name="mTxRAMMin"> 577 <property name="sizePolicy"> 578 <sizepolicy hsizetype="Minimum" vsizetype="Preferred"> 579 <horstretch>0</horstretch> 580 <verstretch>0</verstretch> 581 </sizepolicy> 582 </property> 583 <property name="text"> 584 <string/> 585 </property> 586 <property name="alignment"> 587 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 588 </property> 589 </widget> 590 </item> 591 <item row="1" column="2"> 592 <widget class="QLabel" name="mTxRAMMax"> 593 <property name="sizePolicy"> 594 <sizepolicy hsizetype="Minimum" vsizetype="Preferred"> 595 <horstretch>0</horstretch> 596 <verstretch>0</verstretch> 597 </sizepolicy> 598 </property> 599 <property name="text"> 600 <string/> 601 </property> 602 <property name="alignment"> 603 <set>Qt::AlignRight|Qt::AlignTop|Qt::AlignTrailing</set> 604 </property> 605 </widget> 606 </item> 607 <item row="1" column="1"> 608 <spacer> 609 <property name="orientation"> 610 <enum>Qt::Horizontal</enum> 611 </property> 612 <property name="sizeHint" stdset="0"> 613 <size> 614 <width>40</width> 615 <height>5</height> 616 </size> 617 </property> 618 </spacer> 619 </item> 620 </layout> 621 </widget> 622 </item> 623 <item> 624 <spacer> 625 <property name="orientation"> 626 <enum>Qt::Vertical</enum> 627 </property> 628 <property name="sizeHint" stdset="0"> 629 <size> 630 <width>0</width> 631 <height>0</height> 632 </size> 633 </property> 634 </spacer> 635 </item> 636 </layout> 637 </item> 638 </layout> 639 </item> 640 <item> 641 <widget class="Line" name="line32"> 642 <property name="orientation"> 643 <enum>Qt::Horizontal</enum> 644 </property> 645 </widget> 646 </item> 647 <item> 648 <layout class="QHBoxLayout"> 649 <item> 650 <spacer> 651 <property name="orientation"> 652 <enum>Qt::Horizontal</enum> 653 </property> 654 <property name="sizeHint" stdset="0"> 655 <size> 656 <width>0</width> 657 <height>0</height> 658 </size> 659 </property> 660 </spacer> 661 </item> 662 <item> 663 <widget class="QPushButton" name="mBtnBack3"> 664 <property name="text"> 665 <string>< &Back</string> 666 </property> 667 </widget> 668 </item> 669 <item> 670 <widget class="QPushButton" name="mBtnNext3"> 671 <property name="text"> 672 <string>&Next ></string> 673 </property> 674 </widget> 675 </item> 676 <item> 677 <spacer> 678 <property name="orientation"> 679 <enum>Qt::Horizontal</enum> 680 </property> 681 <property name="sizeType"> 682 <enum>QSizePolicy::Fixed</enum> 683 </property> 684 <property name="sizeHint" stdset="0"> 685 <size> 686 <width>5</width> 687 <height>0</height> 688 </size> 689 </property> 690 </spacer> 691 </item> 692 <item> 693 <widget class="QPushButton" name="mBtnCancel3"> 694 <property name="text"> 695 <string>Cancel</string> 696 </property> 697 </widget> 698 </item> 699 </layout> 700 </item> 701 </layout> 702 </widget> 703 <widget class="QWidget" name="mPageHDD"> 704 <layout class="QVBoxLayout"> 705 <item> 706 <widget class="QLabel" name="mPageHDDHdr"> 707 <property name="font"> 708 <font> 709 <family>Arial</family> 710 <pointsize>12</pointsize> 711 <weight>75</weight> 712 <bold>true</bold> 713 </font> 714 </property> 715 <property name="text"> 716 <string>Virtual Hard Disk</string> 717 </property> 718 </widget> 719 </item> 720 <item> 721 <widget class="Line" name="line41"> 722 <property name="orientation"> 723 <enum>Qt::Horizontal</enum> 724 </property> 725 </widget> 726 </item> 727 <item> 728 <layout class="QHBoxLayout"> 729 <property name="spacing"> 730 <number>10</number> 731 </property> 732 <item> 733 <widget class="QLabel" name="mLogoHDD"> 734 <property name="sizePolicy"> 735 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 736 <horstretch>0</horstretch> 737 <verstretch>0</verstretch> 738 </sizepolicy> 739 </property> 740 <property name="autoFillBackground"> 741 <bool>true</bool> 742 </property> 743 <property name="text"> 744 <string/> 745 </property> 746 <property name="pixmap"> 747 <pixmap resource="../VirtualBox1.qrc">:/vmw_new_welcome.png</pixmap> 748 </property> 749 <property name="alignment"> 750 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 751 </property> 752 </widget> 753 </item> 754 <item> 755 <layout class="QVBoxLayout"> 756 <property name="spacing"> 757 <number>10</number> 758 </property> 759 <item> 760 <widget class="QILabel" name="mTextVDI"> 761 <property name="sizePolicy"> 762 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 763 <horstretch>0</horstretch> 764 <verstretch>0</verstretch> 765 </sizepolicy> 766 </property> 767 <property name="minimumSize"> 768 <size> 769 <width>300</width> 770 <height>0</height> 771 </size> 772 </property> 773 <property name="text"> 774 <string><p>Select a hard disk image to be used as the boot hard disk of the virtual machine. You can either create a new hard disk using the <b>New</b> button or select an existing hard disk image from the drop-down list or by pressing the <b>Existing</b> button (to invoke the Virtual Media Manager dialog).</p><p>If you need a more complicated hard disk setup, you can also skip this step and attach hard disks later using the VM Settings dialog.</p></string> 775 </property> 776 <property name="wordWrap"> 777 <bool>true</bool> 778 </property> 779 </widget> 780 </item> 781 <item> 782 <widget class="QILabel" name="mTextVDIBest"> 783 <property name="sizePolicy"> 784 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 785 <horstretch>0</horstretch> 786 <verstretch>0</verstretch> 787 </sizepolicy> 788 </property> 789 <property name="minimumSize"> 790 <size> 791 <width>300</width> 792 <height>0</height> 793 </size> 794 </property> 795 <property name="text"> 796 <string/> 797 </property> 798 <property name="wordWrap"> 799 <bool>true</bool> 800 </property> 801 </widget> 802 </item> 803 <item> 804 <widget class="QGroupBox" name="mGbHDA"> 805 <property name="sizePolicy"> 806 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 807 <horstretch>0</horstretch> 808 <verstretch>0</verstretch> 809 </sizepolicy> 810 </property> 811 <property name="title"> 812 <string>Boot Hard &Disk (Primary Master)</string> 813 </property> 814 <property name="checkable"> 815 <bool>true</bool> 816 </property> 817 <layout class="QGridLayout"> 818 <item row="0" column="0" colspan="3"> 819 <widget class="QRadioButton" name="mNewVDIRadio"> 820 <property name="text"> 821 <string>&Create new hard disk</string> 822 </property> 823 <property name="checked"> 824 <bool>true</bool> 825 </property> 826 </widget> 827 </item> 828 <item row="1" column="0" colspan="3"> 829 <widget class="QRadioButton" name="mExistRadio"> 830 <property name="text"> 831 <string>&Use existing hard disk</string> 832 </property> 833 </widget> 834 </item> 835 <item row="2" column="1"> 836 <widget class="VBoxMediaComboBox" name="mHDCombo"> 837 <property name="sizePolicy"> 838 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 839 <horstretch>0</horstretch> 840 <verstretch>0</verstretch> 841 </sizepolicy> 842 </property> 843 </widget> 844 </item> 845 <item row="2" column="2"> 846 <widget class="QToolButton" name="mTbVmm"> 847 <property name="autoRaise"> 848 <bool>true</bool> 849 </property> 850 </widget> 851 </item> 852 </layout> 853 </widget> 854 </item> 855 <item> 856 <spacer> 857 <property name="orientation"> 858 <enum>Qt::Vertical</enum> 859 </property> 860 <property name="sizeHint" stdset="0"> 861 <size> 862 <width>0</width> 863 <height>0</height> 864 </size> 865 </property> 866 </spacer> 867 </item> 868 </layout> 869 </item> 870 </layout> 871 </item> 872 <item> 873 <widget class="Line" name="line42"> 874 <property name="orientation"> 875 <enum>Qt::Horizontal</enum> 876 </property> 877 </widget> 878 </item> 879 <item> 880 <layout class="QHBoxLayout"> 881 <item> 882 <spacer> 883 <property name="orientation"> 884 <enum>Qt::Horizontal</enum> 885 </property> 886 <property name="sizeHint" stdset="0"> 887 <size> 888 <width>0</width> 889 <height>0</height> 890 </size> 891 </property> 892 </spacer> 893 </item> 894 <item> 895 <widget class="QPushButton" name="mBtnBack4"> 896 <property name="text"> 897 <string>< &Back</string> 898 </property> 899 </widget> 900 </item> 901 <item> 902 <widget class="QPushButton" name="mBtnNext4"> 903 <property name="text"> 904 <string>&Next ></string> 905 </property> 906 </widget> 907 </item> 908 <item> 909 <spacer> 910 <property name="orientation"> 911 <enum>Qt::Horizontal</enum> 912 </property> 913 <property name="sizeType"> 914 <enum>QSizePolicy::Fixed</enum> 915 </property> 916 <property name="sizeHint" stdset="0"> 917 <size> 918 <width>5</width> 919 <height>0</height> 920 </size> 921 </property> 922 </spacer> 923 </item> 924 <item> 925 <widget class="QPushButton" name="mBtnCancel4"> 926 <property name="text"> 927 <string>Cancel</string> 928 </property> 929 </widget> 930 </item> 931 </layout> 932 </item> 933 </layout> 934 </widget> 935 <widget class="QWidget" name="mPageSummary"> 936 <layout class="QVBoxLayout"> 937 <item> 938 <widget class="QLabel" name="mPageSummaryHdr"> 939 <property name="font"> 940 <font> 941 <family>Arial</family> 942 <pointsize>12</pointsize> 943 <weight>75</weight> 944 <bold>true</bold> 945 </font> 946 </property> 947 <property name="text"> 948 <string>Summary</string> 949 </property> 950 </widget> 951 </item> 952 <item> 953 <widget class="Line" name="line51"> 954 <property name="orientation"> 955 <enum>Qt::Horizontal</enum> 956 </property> 957 </widget> 958 </item> 959 <item> 960 <layout class="QHBoxLayout"> 961 <property name="spacing"> 962 <number>10</number> 963 </property> 964 <item> 965 <widget class="QLabel" name="mLogoSummary"> 966 <property name="sizePolicy"> 967 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 968 <horstretch>0</horstretch> 969 <verstretch>0</verstretch> 970 </sizepolicy> 971 </property> 972 <property name="autoFillBackground"> 973 <bool>true</bool> 974 </property> 975 <property name="text"> 976 <string/> 977 </property> 978 <property name="pixmap"> 979 <pixmap resource="../VirtualBox1.qrc">:/vmw_new_welcome.png</pixmap> 980 </property> 981 <property name="alignment"> 982 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 983 </property> 984 </widget> 985 </item> 986 <item> 987 <layout class="QVBoxLayout"> 988 <property name="spacing"> 989 <number>10</number> 990 </property> 991 <item> 992 <widget class="QILabel" name="mTextSummaryHdr"> 993 <property name="sizePolicy"> 994 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 995 <horstretch>0</horstretch> 996 <verstretch>0</verstretch> 997 </sizepolicy> 998 </property> 999 <property name="minimumSize"> 1000 <size> 1001 <width>300</width> 1002 <height>0</height> 1003 </size> 1004 </property> 1005 <property name="text"> 1006 <string><p>You are going to create a new virtual machine with the following parameters:</p></string> 1007 </property> 1008 <property name="wordWrap"> 1009 <bool>true</bool> 1010 </property> 1011 </widget> 1012 </item> 1013 <item> 1014 <widget class="QITextEdit" name="mTeSummary"> 1015 <property name="sizePolicy"> 1016 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 1017 <horstretch>0</horstretch> 1018 <verstretch>0</verstretch> 1019 </sizepolicy> 1020 </property> 1021 <property name="minimumSize"> 1022 <size> 1023 <width>300</width> 1024 <height>0</height> 1025 </size> 1026 </property> 1027 <property name="frameShape"> 1028 <enum>QFrame::NoFrame</enum> 1029 </property> 1030 <property name="autoFormatting"> 1031 <set>QTextEdit::AutoAll</set> 1032 </property> 1033 <property name="readOnly"> 1034 <bool>true</bool> 1035 </property> 1036 </widget> 1037 </item> 1038 <item> 1039 <widget class="QILabel" name="mTextSummaryFtr"> 1040 <property name="sizePolicy"> 1041 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 1042 <horstretch>0</horstretch> 1043 <verstretch>0</verstretch> 1044 </sizepolicy> 1045 </property> 1046 <property name="minimumSize"> 1047 <size> 1048 <width>300</width> 1049 <height>0</height> 1050 </size> 1051 </property> 1052 <property name="text"> 1053 <string><p>If the above is correct press the <b>Finish</b> button. Once you press it, a new virtual machine will be created. </p><p>Note that you can alter these and all other setting of the created virtual machine at any time using the <b>Settings</b> dialog accessible through the menu of the main window.</p></string> 1054 </property> 1055 <property name="wordWrap"> 1056 <bool>true</bool> 1057 </property> 1058 </widget> 1059 </item> 1060 <item> 1061 <spacer> 1062 <property name="orientation"> 1063 <enum>Qt::Vertical</enum> 1064 </property> 1065 <property name="sizeType"> 1066 <enum>QSizePolicy::Expanding</enum> 1067 </property> 1068 <property name="sizeHint" stdset="0"> 1069 <size> 1070 <width>0</width> 1071 <height>0</height> 1072 </size> 1073 </property> 1074 </spacer> 1075 </item> 1076 </layout> 1077 </item> 1078 </layout> 1079 </item> 1080 <item> 1081 <widget class="Line" name="line52"> 1082 <property name="orientation"> 1083 <enum>Qt::Horizontal</enum> 1084 </property> 1085 </widget> 1086 </item> 1087 <item> 1088 <layout class="QHBoxLayout"> 1089 <item> 1090 <spacer> 1091 <property name="orientation"> 1092 <enum>Qt::Horizontal</enum> 1093 </property> 1094 <property name="sizeHint" stdset="0"> 1095 <size> 1096 <width>0</width> 1097 <height>0</height> 1098 </size> 1099 </property> 1100 </spacer> 1101 </item> 1102 <item> 1103 <widget class="QPushButton" name="mBtnBack5"> 1104 <property name="text"> 1105 <string>< &Back</string> 1106 </property> 1107 </widget> 1108 </item> 1109 <item> 1110 <widget class="QPushButton" name="mBtnFinish"> 1111 <property name="text"> 1112 <string>&Finish</string> 1113 </property> 1114 </widget> 1115 </item> 1116 <item> 1117 <spacer> 1118 <property name="orientation"> 1119 <enum>Qt::Horizontal</enum> 1120 </property> 1121 <property name="sizeType"> 1122 <enum>QSizePolicy::Fixed</enum> 1123 </property> 1124 <property name="sizeHint" stdset="0"> 1125 <size> 1126 <width>5</width> 1127 <height>0</height> 1128 </size> 1129 </property> 1130 </spacer> 1131 </item> 1132 <item> 1133 <widget class="QPushButton" name="mBtnCancel5"> 1134 <property name="text"> 1135 <string>Cancel</string> 1136 </property> 1137 </widget> 1138 </item> 1139 </layout> 1140 </item> 1141 </layout> 1142 </widget> 51 <property name="wordWrap"> 52 <bool>true</bool> 53 </property> 1143 54 </widget> 55 </item> 56 <item> 57 <widget class="QGroupBox" name="m_pNameEditorCnt"> 58 <property name="title"> 59 <string>N&ame</string> 60 </property> 61 <layout class="QHBoxLayout" name="m_pLayout2"> 62 <item> 63 <widget class="QLineEdit" name="m_pNameEditor"/> 64 </item> 65 </layout> 66 </widget> 67 </item> 68 <item> 69 <widget class="QGroupBox" name="m_pTypeSelectorCnt"> 70 <property name="title"> 71 <string>OS &Type</string> 72 </property> 73 <layout class="QHBoxLayout" name="m_pLayout3"> 74 <item> 75 <widget class="VBoxOSTypeSelectorWidget" name="m_pTypeSelector" native="true"/> 76 </item> 77 </layout> 78 </widget> 79 </item> 80 <item> 81 <spacer name="m_pSpacer1"> 82 <property name="sizeHint" stdset="0"> 83 <size> 84 <width>0</width> 85 <height>0</height> 86 </size> 87 </property> 88 </spacer> 1144 89 </item> 1145 90 </layout> … … 1156 101 <header>VBoxOSTypeSelectorWidget.h</header> 1157 102 </customwidget> 1158 <customwidget>1159 <class>VBoxMediaComboBox</class>1160 <extends>QComboBox</extends>1161 <header>VBoxMediaComboBox.h</header>1162 </customwidget>1163 <customwidget>1164 <class>QITextEdit</class>1165 <extends>QTextEdit</extends>1166 <header>QIAbstractWizard.h</header>1167 </customwidget>1168 <customwidget>1169 <class>QILineEdit</class>1170 <extends>QLineEdit</extends>1171 <header>QILineEdit.h</header>1172 </customwidget>1173 <customwidget>1174 <class>QIAdvancedSlider</class>1175 <extends>QSlider</extends>1176 <header>QIAdvancedSlider.h</header>1177 </customwidget>1178 <customwidget>1179 <class>VBoxGuestRAMSlider</class>1180 <extends>QIAdvancedSlider</extends>1181 <header>VBoxGuestRAMSlider.h</header>1182 </customwidget>1183 103 </customwidgets> 1184 <tabstops> 1185 <tabstop>mBtnNext1</tabstop> 1186 <tabstop>mBtnCancel1</tabstop> 1187 <tabstop>mLeName</tabstop> 1188 <tabstop>mOSTypeSelector</tabstop> 1189 <tabstop>mBtnBack2</tabstop> 1190 <tabstop>mBtnNext2</tabstop> 1191 <tabstop>mBtnCancel2</tabstop> 1192 <tabstop>mSlRAM</tabstop> 1193 <tabstop>mLeRAM</tabstop> 1194 <tabstop>mBtnBack3</tabstop> 1195 <tabstop>mBtnNext3</tabstop> 1196 <tabstop>mBtnCancel3</tabstop> 1197 <tabstop>mNewVDIRadio</tabstop> 1198 <tabstop>mExistRadio</tabstop> 1199 <tabstop>mHDCombo</tabstop> 1200 <tabstop>mTbVmm</tabstop> 1201 <tabstop>mBtnBack4</tabstop> 1202 <tabstop>mBtnNext4</tabstop> 1203 <tabstop>mBtnCancel4</tabstop> 1204 <tabstop>mBtnBack5</tabstop> 1205 <tabstop>mBtnFinish</tabstop> 1206 <tabstop>mBtnCancel5</tabstop> 1207 </tabstops> 1208 <resources> 1209 <include location="../VirtualBox1.qrc"/> 1210 </resources> 104 <resources/> 1211 105 <connections/> 1212 106 </ui> -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/newvm/UINewVMWzdPage3.ui
r25267 r26079 2 2 <ui version="4.0"> 3 3 <comment> 4 VBox frontends: Qt4 GUI ( "VirtualBox"):4 VBox frontends: Qt4 GUI ("VirtualBox"): 5 5 6 Copyright (C) 200 8Sun Microsystems, Inc.6 Copyright (C) 2009 Sun Microsystems, Inc. 7 7 8 8 This file is part of VirtualBox Open Source Edition (OSE), as … … 18 18 additional information or have any questions. 19 19 </comment> 20 <class>VBoxNewVMWzd</class> 21 <widget class="QDialog" name="VBoxNewVMWzd"> 20 <class>UINewVMWzdPage3</class> 21 <widget class="QWidget" name="UINewVMWzdPage3"> 22 <property name="sizePolicy"> 23 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 24 <horstretch>0</horstretch> 25 <verstretch>0</verstretch> 26 </sizepolicy> 27 </property> 22 28 <property name="geometry"> 23 29 <rect> 24 30 <x>0</x> 25 31 <y>0</y> 26 <width> 516</width>27 <height>4 98</height>32 <width>600</width> 33 <height>400</height> 28 34 </rect> 29 35 </property> 30 <property name="windowTitle"> 31 <string>Create New Virtual Machine</string> 36 <property name="sizePolicy"> 37 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 38 <horstretch>0</horstretch> 39 <verstretch>0</verstretch> 40 </sizepolicy> 32 41 </property> 33 <layout class="QVBoxLayout" >34 <property name=" margin">42 <layout class="QVBoxLayout" name="m_pLayout1"> 43 <property name="bottomMargin" > 35 44 <number>0</number> 36 45 </property> 37 46 <item> 38 <widget class="Q StackedWidget" name="mPageStack">39 <property name=" currentIndex">40 < number>2</number>47 <widget class="QILabel" name="m_pPage3Text1"> 48 <property name="text"> 49 <string><p>Select the amount of base memory (RAM) in megabytes to be allocated to the virtual machine.</p></string> 41 50 </property> 42 <widget class="QWidget" name="mPageWelcome"> 43 <layout class="QVBoxLayout"> 44 <item> 45 <widget class="QLabel" name="mPageWelcomeHdr"> 46 <property name="font"> 47 <font> 48 <family>Arial</family> 49 <pointsize>12</pointsize> 50 <weight>75</weight> 51 <bold>true</bold> 52 </font> 53 </property> 54 <property name="text"> 55 <string>Welcome to the New Virtual Machine Wizard!</string> 56 </property> 57 </widget> 58 </item> 59 <item> 60 <widget class="Line" name="line11"> 61 <property name="orientation"> 62 <enum>Qt::Horizontal</enum> 63 </property> 64 </widget> 65 </item> 66 <item> 67 <layout class="QHBoxLayout"> 68 <property name="spacing"> 69 <number>10</number> 70 </property> 71 <item> 72 <widget class="QLabel" name="mLogoWelcome"> 73 <property name="sizePolicy"> 74 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 75 <horstretch>0</horstretch> 76 <verstretch>0</verstretch> 77 </sizepolicy> 78 </property> 79 <property name="autoFillBackground"> 80 <bool>true</bool> 81 </property> 82 <property name="text"> 83 <string/> 84 </property> 85 <property name="pixmap"> 86 <pixmap resource="../VirtualBox1.qrc">:/vmw_new_welcome.png</pixmap> 87 </property> 88 <property name="alignment"> 89 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 90 </property> 91 </widget> 92 </item> 93 <item> 94 <layout class="QVBoxLayout"> 95 <property name="spacing"> 96 <number>10</number> 97 </property> 98 <item> 99 <widget class="QILabel" name="mTextWelcome"> 100 <property name="sizePolicy"> 101 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 102 <horstretch>0</horstretch> 103 <verstretch>0</verstretch> 104 </sizepolicy> 105 </property> 106 <property name="minimumSize"> 107 <size> 108 <width>300</width> 109 <height>0</height> 110 </size> 111 </property> 112 <property name="text"> 113 <string><p>This wizard will guide you through the steps that are necessary to create a new virtual machine for VirtualBox.</p><p>Use the <b>Next</b> button to go the next page of the wizard and the <b>Back</b> button to return to the previous page.</p></string> 114 </property> 115 <property name="wordWrap"> 116 <bool>true</bool> 117 </property> 118 </widget> 119 </item> 120 <item> 121 <spacer> 122 <property name="orientation"> 123 <enum>Qt::Vertical</enum> 124 </property> 125 <property name="sizeHint" stdset="0"> 126 <size> 127 <width>0</width> 128 <height>0</height> 129 </size> 130 </property> 131 </spacer> 132 </item> 133 </layout> 134 </item> 135 </layout> 136 </item> 137 <item> 138 <widget class="Line" name="line12"> 139 <property name="orientation"> 140 <enum>Qt::Horizontal</enum> 141 </property> 142 </widget> 143 </item> 144 <item> 145 <layout class="QHBoxLayout"> 146 <item> 147 <spacer> 148 <property name="orientation"> 149 <enum>Qt::Horizontal</enum> 150 </property> 151 <property name="sizeHint" stdset="0"> 152 <size> 153 <width>0</width> 154 <height>0</height> 155 </size> 156 </property> 157 </spacer> 158 </item> 159 <item> 160 <widget class="QPushButton" name="mBtnBack1"> 161 <property name="enabled"> 162 <bool>false</bool> 163 </property> 164 <property name="text"> 165 <string>< &Back</string> 166 </property> 167 </widget> 168 </item> 169 <item> 170 <widget class="QPushButton" name="mBtnNext1"> 171 <property name="text"> 172 <string>&Next ></string> 173 </property> 174 </widget> 175 </item> 176 <item> 177 <spacer> 178 <property name="orientation"> 179 <enum>Qt::Horizontal</enum> 180 </property> 181 <property name="sizeType"> 182 <enum>QSizePolicy::Fixed</enum> 183 </property> 184 <property name="sizeHint" stdset="0"> 185 <size> 186 <width>5</width> 187 <height>0</height> 188 </size> 189 </property> 190 </spacer> 191 </item> 192 <item> 193 <widget class="QPushButton" name="mBtnCancel1"> 194 <property name="text"> 195 <string>Cancel</string> 196 </property> 197 </widget> 198 </item> 199 </layout> 200 </item> 201 </layout> 202 </widget> 203 <widget class="QWidget" name="mPageNameAndOS"> 204 <layout class="QVBoxLayout"> 205 <item> 206 <widget class="QLabel" name="mPageNameAndOSHdr"> 207 <property name="font"> 208 <font> 209 <family>Arial</family> 210 <pointsize>12</pointsize> 211 <weight>75</weight> 212 <bold>true</bold> 213 </font> 214 </property> 215 <property name="text"> 216 <string>VM Name and OS Type</string> 217 </property> 218 </widget> 219 </item> 220 <item> 221 <widget class="Line" name="line21"> 222 <property name="orientation"> 223 <enum>Qt::Horizontal</enum> 224 </property> 225 </widget> 226 </item> 227 <item> 228 <layout class="QHBoxLayout"> 229 <property name="spacing"> 230 <number>10</number> 231 </property> 232 <item> 233 <widget class="QLabel" name="mLogoNameAndOS"> 234 <property name="sizePolicy"> 235 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 236 <horstretch>0</horstretch> 237 <verstretch>0</verstretch> 238 </sizepolicy> 239 </property> 240 <property name="autoFillBackground"> 241 <bool>true</bool> 242 </property> 243 <property name="text"> 244 <string/> 245 </property> 246 <property name="pixmap"> 247 <pixmap resource="../VirtualBox1.qrc">:/vmw_new_welcome.png</pixmap> 248 </property> 249 <property name="alignment"> 250 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 251 </property> 252 </widget> 253 </item> 254 <item> 255 <layout class="QVBoxLayout"> 256 <property name="spacing"> 257 <number>10</number> 258 </property> 259 <item> 260 <widget class="QILabel" name="mTextNameAndOS"> 261 <property name="sizePolicy"> 262 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 263 <horstretch>0</horstretch> 264 <verstretch>0</verstretch> 265 </sizepolicy> 266 </property> 267 <property name="minimumSize"> 268 <size> 269 <width>300</width> 270 <height>0</height> 271 </size> 272 </property> 273 <property name="text"> 274 <string><p>Enter a name for the new virtual machine and select the type of the guest operating system you plan to install onto the virtual machine.</p><p>The name of the virtual machine usually indicates its software and hardware configuration. It will be used by all VirtualBox components to identify your virtual machine.</p></string> 275 </property> 276 <property name="wordWrap"> 277 <bool>true</bool> 278 </property> 279 </widget> 280 </item> 281 <item> 282 <widget class="QGroupBox" name="gbName"> 283 <property name="sizePolicy"> 284 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 285 <horstretch>0</horstretch> 286 <verstretch>0</verstretch> 287 </sizepolicy> 288 </property> 289 <property name="title"> 290 <string>N&ame</string> 291 </property> 292 <layout class="QHBoxLayout"> 293 <property name="spacing"> 294 <number>0</number> 295 </property> 296 <property name="leftMargin"> 297 <number>9</number> 298 </property> 299 <property name="topMargin"> 300 <number>4</number> 301 </property> 302 <property name="rightMargin"> 303 <number>9</number> 304 </property> 305 <property name="bottomMargin"> 306 <number>9</number> 307 </property> 308 <item> 309 <widget class="QLineEdit" name="mLeName"/> 310 </item> 311 </layout> 312 </widget> 313 </item> 314 <item> 315 <widget class="QGroupBox" name="gbOSType"> 316 <property name="sizePolicy"> 317 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 318 <horstretch>0</horstretch> 319 <verstretch>0</verstretch> 320 </sizepolicy> 321 </property> 322 <property name="title"> 323 <string>OS &Type</string> 324 </property> 325 <layout class="QHBoxLayout"> 326 <property name="topMargin"> 327 <number>4</number> 328 </property> 329 <item> 330 <widget class="VBoxOSTypeSelectorWidget" name="mOSTypeSelector" native="true"/> 331 </item> 332 </layout> 333 </widget> 334 </item> 335 <item> 336 <spacer> 337 <property name="orientation"> 338 <enum>Qt::Vertical</enum> 339 </property> 340 <property name="sizeHint" stdset="0"> 341 <size> 342 <width>0</width> 343 <height>0</height> 344 </size> 345 </property> 346 </spacer> 347 </item> 348 </layout> 349 </item> 350 </layout> 351 </item> 352 <item> 353 <widget class="Line" name="line22"> 354 <property name="orientation"> 355 <enum>Qt::Horizontal</enum> 356 </property> 357 </widget> 358 </item> 359 <item> 360 <layout class="QHBoxLayout"> 361 <item> 362 <spacer> 363 <property name="orientation"> 364 <enum>Qt::Horizontal</enum> 365 </property> 366 <property name="sizeHint" stdset="0"> 367 <size> 368 <width>0</width> 369 <height>0</height> 370 </size> 371 </property> 372 </spacer> 373 </item> 374 <item> 375 <widget class="QPushButton" name="mBtnBack2"> 376 <property name="text"> 377 <string>< &Back</string> 378 </property> 379 </widget> 380 </item> 381 <item> 382 <widget class="QPushButton" name="mBtnNext2"> 383 <property name="text"> 384 <string>&Next ></string> 385 </property> 386 </widget> 387 </item> 388 <item> 389 <spacer> 390 <property name="orientation"> 391 <enum>Qt::Horizontal</enum> 392 </property> 393 <property name="sizeType"> 394 <enum>QSizePolicy::Fixed</enum> 395 </property> 396 <property name="sizeHint" stdset="0"> 397 <size> 398 <width>5</width> 399 <height>0</height> 400 </size> 401 </property> 402 </spacer> 403 </item> 404 <item> 405 <widget class="QPushButton" name="mBtnCancel2"> 406 <property name="text"> 407 <string>Cancel</string> 408 </property> 409 </widget> 410 </item> 411 </layout> 412 </item> 413 </layout> 414 </widget> 415 <widget class="QWidget" name="mPageMemory"> 416 <layout class="QVBoxLayout"> 417 <item> 418 <widget class="QLabel" name="mPageMemoryHdr"> 419 <property name="font"> 420 <font> 421 <family>Arial</family> 422 <pointsize>12</pointsize> 423 <weight>75</weight> 424 <bold>true</bold> 425 </font> 426 </property> 427 <property name="text"> 428 <string>Memory</string> 429 </property> 430 </widget> 431 </item> 432 <item> 433 <widget class="Line" name="line31"> 434 <property name="orientation"> 435 <enum>Qt::Horizontal</enum> 436 </property> 437 </widget> 438 </item> 439 <item> 440 <layout class="QHBoxLayout"> 441 <property name="spacing"> 442 <number>10</number> 443 </property> 444 <item> 445 <widget class="QLabel" name="mLogoMemory"> 446 <property name="sizePolicy"> 447 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 448 <horstretch>0</horstretch> 449 <verstretch>0</verstretch> 450 </sizepolicy> 451 </property> 452 <property name="autoFillBackground"> 453 <bool>true</bool> 454 </property> 455 <property name="text"> 456 <string/> 457 </property> 458 <property name="pixmap"> 459 <pixmap resource="../VirtualBox1.qrc">:/vmw_new_welcome.png</pixmap> 460 </property> 461 <property name="alignment"> 462 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 463 </property> 464 </widget> 465 </item> 466 <item> 467 <layout class="QVBoxLayout"> 468 <property name="spacing"> 469 <number>10</number> 470 </property> 471 <item> 472 <widget class="QILabel" name="mTextMemory"> 473 <property name="sizePolicy"> 474 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 475 <horstretch>0</horstretch> 476 <verstretch>0</verstretch> 477 </sizepolicy> 478 </property> 479 <property name="minimumSize"> 480 <size> 481 <width>300</width> 482 <height>0</height> 483 </size> 484 </property> 485 <property name="text"> 486 <string><p>Select the amount of base memory (RAM) in megabytes to be allocated to the virtual machine.</p></string> 487 </property> 488 <property name="wordWrap"> 489 <bool>true</bool> 490 </property> 491 </widget> 492 </item> 493 <item> 494 <widget class="QILabel" name="mTextRAMBest"> 495 <property name="sizePolicy"> 496 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 497 <horstretch>0</horstretch> 498 <verstretch>0</verstretch> 499 </sizepolicy> 500 </property> 501 <property name="minimumSize"> 502 <size> 503 <width>300</width> 504 <height>0</height> 505 </size> 506 </property> 507 <property name="text"> 508 <string/> 509 </property> 510 <property name="wordWrap"> 511 <bool>true</bool> 512 </property> 513 </widget> 514 </item> 515 <item> 516 <widget class="QGroupBox" name="gbMemory"> 517 <property name="sizePolicy"> 518 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 519 <horstretch>0</horstretch> 520 <verstretch>0</verstretch> 521 </sizepolicy> 522 </property> 523 <property name="title"> 524 <string>Base &Memory Size</string> 525 </property> 526 <layout class="QGridLayout"> 527 <property name="topMargin"> 528 <number>4</number> 529 </property> 530 <item row="0" column="0" colspan="3"> 531 <widget class="VBoxGuestRAMSlider" name="mSlRAM"> 532 <property name="sizePolicy"> 533 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 534 <horstretch>0</horstretch> 535 <verstretch>0</verstretch> 536 </sizepolicy> 537 </property> 538 <property name="minimumSize"> 539 <size> 540 <width>0</width> 541 <height>0</height> 542 </size> 543 </property> 544 <property name="orientation"> 545 <enum>Qt::Horizontal</enum> 546 </property> 547 <property name="tickPosition"> 548 <enum>QSlider::TicksBelow</enum> 549 </property> 550 </widget> 551 </item> 552 <item row="0" column="3"> 553 <widget class="QILineEdit" name="mLeRAM"> 554 <property name="sizePolicy"> 555 <sizepolicy hsizetype="Preferred" vsizetype="Fixed"> 556 <horstretch>0</horstretch> 557 <verstretch>0</verstretch> 558 </sizepolicy> 559 </property> 560 </widget> 561 </item> 562 <item row="0" column="4"> 563 <widget class="QLabel" name="txRAM"> 564 <property name="sizePolicy"> 565 <sizepolicy hsizetype="Fixed" vsizetype="Fixed"> 566 <horstretch>0</horstretch> 567 <verstretch>0</verstretch> 568 </sizepolicy> 569 </property> 570 <property name="text"> 571 <string>MB</string> 572 </property> 573 </widget> 574 </item> 575 <item row="1" column="0"> 576 <widget class="QLabel" name="mTxRAMMin"> 577 <property name="sizePolicy"> 578 <sizepolicy hsizetype="Minimum" vsizetype="Preferred"> 579 <horstretch>0</horstretch> 580 <verstretch>0</verstretch> 581 </sizepolicy> 582 </property> 583 <property name="text"> 584 <string/> 585 </property> 586 <property name="alignment"> 587 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 588 </property> 589 </widget> 590 </item> 591 <item row="1" column="2"> 592 <widget class="QLabel" name="mTxRAMMax"> 593 <property name="sizePolicy"> 594 <sizepolicy hsizetype="Minimum" vsizetype="Preferred"> 595 <horstretch>0</horstretch> 596 <verstretch>0</verstretch> 597 </sizepolicy> 598 </property> 599 <property name="text"> 600 <string/> 601 </property> 602 <property name="alignment"> 603 <set>Qt::AlignRight|Qt::AlignTop|Qt::AlignTrailing</set> 604 </property> 605 </widget> 606 </item> 607 <item row="1" column="1"> 608 <spacer> 609 <property name="orientation"> 610 <enum>Qt::Horizontal</enum> 611 </property> 612 <property name="sizeHint" stdset="0"> 613 <size> 614 <width>40</width> 615 <height>5</height> 616 </size> 617 </property> 618 </spacer> 619 </item> 620 </layout> 621 </widget> 622 </item> 623 <item> 624 <spacer> 625 <property name="orientation"> 626 <enum>Qt::Vertical</enum> 627 </property> 628 <property name="sizeHint" stdset="0"> 629 <size> 630 <width>0</width> 631 <height>0</height> 632 </size> 633 </property> 634 </spacer> 635 </item> 636 </layout> 637 </item> 638 </layout> 639 </item> 640 <item> 641 <widget class="Line" name="line32"> 642 <property name="orientation"> 643 <enum>Qt::Horizontal</enum> 644 </property> 645 </widget> 646 </item> 647 <item> 648 <layout class="QHBoxLayout"> 649 <item> 650 <spacer> 651 <property name="orientation"> 652 <enum>Qt::Horizontal</enum> 653 </property> 654 <property name="sizeHint" stdset="0"> 655 <size> 656 <width>0</width> 657 <height>0</height> 658 </size> 659 </property> 660 </spacer> 661 </item> 662 <item> 663 <widget class="QPushButton" name="mBtnBack3"> 664 <property name="text"> 665 <string>< &Back</string> 666 </property> 667 </widget> 668 </item> 669 <item> 670 <widget class="QPushButton" name="mBtnNext3"> 671 <property name="text"> 672 <string>&Next ></string> 673 </property> 674 </widget> 675 </item> 676 <item> 677 <spacer> 678 <property name="orientation"> 679 <enum>Qt::Horizontal</enum> 680 </property> 681 <property name="sizeType"> 682 <enum>QSizePolicy::Fixed</enum> 683 </property> 684 <property name="sizeHint" stdset="0"> 685 <size> 686 <width>5</width> 687 <height>0</height> 688 </size> 689 </property> 690 </spacer> 691 </item> 692 <item> 693 <widget class="QPushButton" name="mBtnCancel3"> 694 <property name="text"> 695 <string>Cancel</string> 696 </property> 697 </widget> 698 </item> 699 </layout> 700 </item> 701 </layout> 702 </widget> 703 <widget class="QWidget" name="mPageHDD"> 704 <layout class="QVBoxLayout"> 705 <item> 706 <widget class="QLabel" name="mPageHDDHdr"> 707 <property name="font"> 708 <font> 709 <family>Arial</family> 710 <pointsize>12</pointsize> 711 <weight>75</weight> 712 <bold>true</bold> 713 </font> 714 </property> 715 <property name="text"> 716 <string>Virtual Hard Disk</string> 717 </property> 718 </widget> 719 </item> 720 <item> 721 <widget class="Line" name="line41"> 722 <property name="orientation"> 723 <enum>Qt::Horizontal</enum> 724 </property> 725 </widget> 726 </item> 727 <item> 728 <layout class="QHBoxLayout"> 729 <property name="spacing"> 730 <number>10</number> 731 </property> 732 <item> 733 <widget class="QLabel" name="mLogoHDD"> 734 <property name="sizePolicy"> 735 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 736 <horstretch>0</horstretch> 737 <verstretch>0</verstretch> 738 </sizepolicy> 739 </property> 740 <property name="autoFillBackground"> 741 <bool>true</bool> 742 </property> 743 <property name="text"> 744 <string/> 745 </property> 746 <property name="pixmap"> 747 <pixmap resource="../VirtualBox1.qrc">:/vmw_new_welcome.png</pixmap> 748 </property> 749 <property name="alignment"> 750 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 751 </property> 752 </widget> 753 </item> 754 <item> 755 <layout class="QVBoxLayout"> 756 <property name="spacing"> 757 <number>10</number> 758 </property> 759 <item> 760 <widget class="QILabel" name="mTextVDI"> 761 <property name="sizePolicy"> 762 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 763 <horstretch>0</horstretch> 764 <verstretch>0</verstretch> 765 </sizepolicy> 766 </property> 767 <property name="minimumSize"> 768 <size> 769 <width>300</width> 770 <height>0</height> 771 </size> 772 </property> 773 <property name="text"> 774 <string><p>Select a hard disk image to be used as the boot hard disk of the virtual machine. You can either create a new hard disk using the <b>New</b> button or select an existing hard disk image from the drop-down list or by pressing the <b>Existing</b> button (to invoke the Virtual Media Manager dialog).</p><p>If you need a more complicated hard disk setup, you can also skip this step and attach hard disks later using the VM Settings dialog.</p></string> 775 </property> 776 <property name="wordWrap"> 777 <bool>true</bool> 778 </property> 779 </widget> 780 </item> 781 <item> 782 <widget class="QILabel" name="mTextVDIBest"> 783 <property name="sizePolicy"> 784 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 785 <horstretch>0</horstretch> 786 <verstretch>0</verstretch> 787 </sizepolicy> 788 </property> 789 <property name="minimumSize"> 790 <size> 791 <width>300</width> 792 <height>0</height> 793 </size> 794 </property> 795 <property name="text"> 796 <string/> 797 </property> 798 <property name="wordWrap"> 799 <bool>true</bool> 800 </property> 801 </widget> 802 </item> 803 <item> 804 <widget class="QGroupBox" name="mGbHDA"> 805 <property name="sizePolicy"> 806 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 807 <horstretch>0</horstretch> 808 <verstretch>0</verstretch> 809 </sizepolicy> 810 </property> 811 <property name="title"> 812 <string>Boot Hard &Disk (Primary Master)</string> 813 </property> 814 <property name="checkable"> 815 <bool>true</bool> 816 </property> 817 <layout class="QGridLayout"> 818 <item row="0" column="0" colspan="3"> 819 <widget class="QRadioButton" name="mNewVDIRadio"> 820 <property name="text"> 821 <string>&Create new hard disk</string> 822 </property> 823 <property name="checked"> 824 <bool>true</bool> 825 </property> 826 </widget> 827 </item> 828 <item row="1" column="0" colspan="3"> 829 <widget class="QRadioButton" name="mExistRadio"> 830 <property name="text"> 831 <string>&Use existing hard disk</string> 832 </property> 833 </widget> 834 </item> 835 <item row="2" column="1"> 836 <widget class="VBoxMediaComboBox" name="mHDCombo"> 837 <property name="sizePolicy"> 838 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 839 <horstretch>0</horstretch> 840 <verstretch>0</verstretch> 841 </sizepolicy> 842 </property> 843 </widget> 844 </item> 845 <item row="2" column="2"> 846 <widget class="QToolButton" name="mTbVmm"> 847 <property name="autoRaise"> 848 <bool>true</bool> 849 </property> 850 </widget> 851 </item> 852 </layout> 853 </widget> 854 </item> 855 <item> 856 <spacer> 857 <property name="orientation"> 858 <enum>Qt::Vertical</enum> 859 </property> 860 <property name="sizeHint" stdset="0"> 861 <size> 862 <width>0</width> 863 <height>0</height> 864 </size> 865 </property> 866 </spacer> 867 </item> 868 </layout> 869 </item> 870 </layout> 871 </item> 872 <item> 873 <widget class="Line" name="line42"> 874 <property name="orientation"> 875 <enum>Qt::Horizontal</enum> 876 </property> 877 </widget> 878 </item> 879 <item> 880 <layout class="QHBoxLayout"> 881 <item> 882 <spacer> 883 <property name="orientation"> 884 <enum>Qt::Horizontal</enum> 885 </property> 886 <property name="sizeHint" stdset="0"> 887 <size> 888 <width>0</width> 889 <height>0</height> 890 </size> 891 </property> 892 </spacer> 893 </item> 894 <item> 895 <widget class="QPushButton" name="mBtnBack4"> 896 <property name="text"> 897 <string>< &Back</string> 898 </property> 899 </widget> 900 </item> 901 <item> 902 <widget class="QPushButton" name="mBtnNext4"> 903 <property name="text"> 904 <string>&Next ></string> 905 </property> 906 </widget> 907 </item> 908 <item> 909 <spacer> 910 <property name="orientation"> 911 <enum>Qt::Horizontal</enum> 912 </property> 913 <property name="sizeType"> 914 <enum>QSizePolicy::Fixed</enum> 915 </property> 916 <property name="sizeHint" stdset="0"> 917 <size> 918 <width>5</width> 919 <height>0</height> 920 </size> 921 </property> 922 </spacer> 923 </item> 924 <item> 925 <widget class="QPushButton" name="mBtnCancel4"> 926 <property name="text"> 927 <string>Cancel</string> 928 </property> 929 </widget> 930 </item> 931 </layout> 932 </item> 933 </layout> 934 </widget> 935 <widget class="QWidget" name="mPageSummary"> 936 <layout class="QVBoxLayout"> 937 <item> 938 <widget class="QLabel" name="mPageSummaryHdr"> 939 <property name="font"> 940 <font> 941 <family>Arial</family> 942 <pointsize>12</pointsize> 943 <weight>75</weight> 944 <bold>true</bold> 945 </font> 946 </property> 947 <property name="text"> 948 <string>Summary</string> 949 </property> 950 </widget> 951 </item> 952 <item> 953 <widget class="Line" name="line51"> 954 <property name="orientation"> 955 <enum>Qt::Horizontal</enum> 956 </property> 957 </widget> 958 </item> 959 <item> 960 <layout class="QHBoxLayout"> 961 <property name="spacing"> 962 <number>10</number> 963 </property> 964 <item> 965 <widget class="QLabel" name="mLogoSummary"> 966 <property name="sizePolicy"> 967 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 968 <horstretch>0</horstretch> 969 <verstretch>0</verstretch> 970 </sizepolicy> 971 </property> 972 <property name="autoFillBackground"> 973 <bool>true</bool> 974 </property> 975 <property name="text"> 976 <string/> 977 </property> 978 <property name="pixmap"> 979 <pixmap resource="../VirtualBox1.qrc">:/vmw_new_welcome.png</pixmap> 980 </property> 981 <property name="alignment"> 982 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 983 </property> 984 </widget> 985 </item> 986 <item> 987 <layout class="QVBoxLayout"> 988 <property name="spacing"> 989 <number>10</number> 990 </property> 991 <item> 992 <widget class="QILabel" name="mTextSummaryHdr"> 993 <property name="sizePolicy"> 994 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 995 <horstretch>0</horstretch> 996 <verstretch>0</verstretch> 997 </sizepolicy> 998 </property> 999 <property name="minimumSize"> 1000 <size> 1001 <width>300</width> 1002 <height>0</height> 1003 </size> 1004 </property> 1005 <property name="text"> 1006 <string><p>You are going to create a new virtual machine with the following parameters:</p></string> 1007 </property> 1008 <property name="wordWrap"> 1009 <bool>true</bool> 1010 </property> 1011 </widget> 1012 </item> 1013 <item> 1014 <widget class="QITextEdit" name="mTeSummary"> 1015 <property name="sizePolicy"> 1016 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 1017 <horstretch>0</horstretch> 1018 <verstretch>0</verstretch> 1019 </sizepolicy> 1020 </property> 1021 <property name="minimumSize"> 1022 <size> 1023 <width>300</width> 1024 <height>0</height> 1025 </size> 1026 </property> 1027 <property name="frameShape"> 1028 <enum>QFrame::NoFrame</enum> 1029 </property> 1030 <property name="autoFormatting"> 1031 <set>QTextEdit::AutoAll</set> 1032 </property> 1033 <property name="readOnly"> 1034 <bool>true</bool> 1035 </property> 1036 </widget> 1037 </item> 1038 <item> 1039 <widget class="QILabel" name="mTextSummaryFtr"> 1040 <property name="sizePolicy"> 1041 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 1042 <horstretch>0</horstretch> 1043 <verstretch>0</verstretch> 1044 </sizepolicy> 1045 </property> 1046 <property name="minimumSize"> 1047 <size> 1048 <width>300</width> 1049 <height>0</height> 1050 </size> 1051 </property> 1052 <property name="text"> 1053 <string><p>If the above is correct press the <b>Finish</b> button. Once you press it, a new virtual machine will be created. </p><p>Note that you can alter these and all other setting of the created virtual machine at any time using the <b>Settings</b> dialog accessible through the menu of the main window.</p></string> 1054 </property> 1055 <property name="wordWrap"> 1056 <bool>true</bool> 1057 </property> 1058 </widget> 1059 </item> 1060 <item> 1061 <spacer> 1062 <property name="orientation"> 1063 <enum>Qt::Vertical</enum> 1064 </property> 1065 <property name="sizeType"> 1066 <enum>QSizePolicy::Expanding</enum> 1067 </property> 1068 <property name="sizeHint" stdset="0"> 1069 <size> 1070 <width>0</width> 1071 <height>0</height> 1072 </size> 1073 </property> 1074 </spacer> 1075 </item> 1076 </layout> 1077 </item> 1078 </layout> 1079 </item> 1080 <item> 1081 <widget class="Line" name="line52"> 1082 <property name="orientation"> 1083 <enum>Qt::Horizontal</enum> 1084 </property> 1085 </widget> 1086 </item> 1087 <item> 1088 <layout class="QHBoxLayout"> 1089 <item> 1090 <spacer> 1091 <property name="orientation"> 1092 <enum>Qt::Horizontal</enum> 1093 </property> 1094 <property name="sizeHint" stdset="0"> 1095 <size> 1096 <width>0</width> 1097 <height>0</height> 1098 </size> 1099 </property> 1100 </spacer> 1101 </item> 1102 <item> 1103 <widget class="QPushButton" name="mBtnBack5"> 1104 <property name="text"> 1105 <string>< &Back</string> 1106 </property> 1107 </widget> 1108 </item> 1109 <item> 1110 <widget class="QPushButton" name="mBtnFinish"> 1111 <property name="text"> 1112 <string>&Finish</string> 1113 </property> 1114 </widget> 1115 </item> 1116 <item> 1117 <spacer> 1118 <property name="orientation"> 1119 <enum>Qt::Horizontal</enum> 1120 </property> 1121 <property name="sizeType"> 1122 <enum>QSizePolicy::Fixed</enum> 1123 </property> 1124 <property name="sizeHint" stdset="0"> 1125 <size> 1126 <width>5</width> 1127 <height>0</height> 1128 </size> 1129 </property> 1130 </spacer> 1131 </item> 1132 <item> 1133 <widget class="QPushButton" name="mBtnCancel5"> 1134 <property name="text"> 1135 <string>Cancel</string> 1136 </property> 1137 </widget> 1138 </item> 1139 </layout> 1140 </item> 1141 </layout> 1142 </widget> 51 <property name="wordWrap"> 52 <bool>true</bool> 53 </property> 1143 54 </widget> 55 </item> 56 <item> 57 <widget class="QILabel" name="m_pPage3Text2"> 58 <property name="wordWrap"> 59 <bool>true</bool> 60 </property> 61 </widget> 62 </item> 63 <item> 64 <widget class="QGroupBox" name="m_pMemoryCnt"> 65 <property name="title"> 66 <string>Base &Memory Size</string> 67 </property> 68 <layout class="QGridLayout" name="m_pLayout2"> 69 <item row="0" column="0" colspan="3"> 70 <widget class="VBoxGuestRAMSlider" name="m_pRamSlider"> 71 <property name="sizePolicy"> 72 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 73 <horstretch>0</horstretch> 74 <verstretch>0</verstretch> 75 </sizepolicy> 76 </property> 77 <property name="orientation"> 78 <enum>Qt::Horizontal</enum> 79 </property> 80 <property name="tickPosition"> 81 <enum>QSlider::TicksBelow</enum> 82 </property> 83 </widget> 84 </item> 85 <item row="0" column="3"> 86 <widget class="QILineEdit" name="m_pRamEditor"> 87 <property name="sizePolicy"> 88 <sizepolicy hsizetype="Preferred" vsizetype="Fixed"> 89 <horstretch>0</horstretch> 90 <verstretch>0</verstretch> 91 </sizepolicy> 92 </property> 93 </widget> 94 </item> 95 <item row="0" column="4"> 96 <widget class="QLabel" name="m_pRamUnits"> 97 <property name="text"> 98 <string>MB</string> 99 </property> 100 </widget> 101 </item> 102 <item row="1" column="0"> 103 <widget class="QLabel" name="m_pRamMin"> 104 <property name="sizePolicy"> 105 <sizepolicy hsizetype="Maximum" vsizetype="Preferred"> 106 <horstretch>0</horstretch> 107 <verstretch>0</verstretch> 108 </sizepolicy> 109 </property> 110 </widget> 111 </item> 112 <item row="1" column="1"> 113 <spacer name="m_pSpacer1"> 114 <property name="orientation"> 115 <enum>Qt::Horizontal</enum> 116 </property> 117 <property name="sizeHint" stdset="0"> 118 <size> 119 <width>0</width> 120 <height>0</height> 121 </size> 122 </property> 123 </spacer> 124 </item> 125 <item row="1" column="2"> 126 <widget class="QLabel" name="m_pRamMax"> 127 <property name="sizePolicy"> 128 <sizepolicy hsizetype="Maximum" vsizetype="Preferred"> 129 <horstretch>0</horstretch> 130 <verstretch>0</verstretch> 131 </sizepolicy> 132 </property> 133 </widget> 134 </item> 135 </layout> 136 </widget> 137 </item> 138 <item> 139 <spacer name="m_pSpacer2"> 140 <property name="sizeHint" stdset="0"> 141 <size> 142 <width>0</width> 143 <height>0</height> 144 </size> 145 </property> 146 </spacer> 1144 147 </item> 1145 148 </layout> … … 1150 153 <extends>QLabel</extends> 1151 154 <header>QILabel.h</header> 1152 </customwidget>1153 <customwidget>1154 <class>VBoxOSTypeSelectorWidget</class>1155 <extends>QWidget</extends>1156 <header>VBoxOSTypeSelectorWidget.h</header>1157 </customwidget>1158 <customwidget>1159 <class>VBoxMediaComboBox</class>1160 <extends>QComboBox</extends>1161 <header>VBoxMediaComboBox.h</header>1162 </customwidget>1163 <customwidget>1164 <class>QITextEdit</class>1165 <extends>QTextEdit</extends>1166 <header>QIAbstractWizard.h</header>1167 155 </customwidget> 1168 156 <customwidget> … … 1182 170 </customwidget> 1183 171 </customwidgets> 1184 <tabstops> 1185 <tabstop>mBtnNext1</tabstop> 1186 <tabstop>mBtnCancel1</tabstop> 1187 <tabstop>mLeName</tabstop> 1188 <tabstop>mOSTypeSelector</tabstop> 1189 <tabstop>mBtnBack2</tabstop> 1190 <tabstop>mBtnNext2</tabstop> 1191 <tabstop>mBtnCancel2</tabstop> 1192 <tabstop>mSlRAM</tabstop> 1193 <tabstop>mLeRAM</tabstop> 1194 <tabstop>mBtnBack3</tabstop> 1195 <tabstop>mBtnNext3</tabstop> 1196 <tabstop>mBtnCancel3</tabstop> 1197 <tabstop>mNewVDIRadio</tabstop> 1198 <tabstop>mExistRadio</tabstop> 1199 <tabstop>mHDCombo</tabstop> 1200 <tabstop>mTbVmm</tabstop> 1201 <tabstop>mBtnBack4</tabstop> 1202 <tabstop>mBtnNext4</tabstop> 1203 <tabstop>mBtnCancel4</tabstop> 1204 <tabstop>mBtnBack5</tabstop> 1205 <tabstop>mBtnFinish</tabstop> 1206 <tabstop>mBtnCancel5</tabstop> 1207 </tabstops> 1208 <resources> 1209 <include location="../VirtualBox1.qrc"/> 1210 </resources> 172 <resources/> 1211 173 <connections/> 1212 174 </ui> -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/newvm/UINewVMWzdPage4.ui
r25267 r26079 2 2 <ui version="4.0"> 3 3 <comment> 4 VBox frontends: Qt4 GUI ( "VirtualBox"):4 VBox frontends: Qt4 GUI ("VirtualBox"): 5 5 6 Copyright (C) 200 8Sun Microsystems, Inc.6 Copyright (C) 2009 Sun Microsystems, Inc. 7 7 8 8 This file is part of VirtualBox Open Source Edition (OSE), as … … 18 18 additional information or have any questions. 19 19 </comment> 20 <class>VBoxNewVMWzd</class> 21 <widget class="QDialog" name="VBoxNewVMWzd"> 20 <class>UINewVMWzdPage4</class> 21 <widget class="QWidget" name="UINewVMWzdPage4"> 22 <property name="sizePolicy"> 23 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 24 <horstretch>0</horstretch> 25 <verstretch>0</verstretch> 26 </sizepolicy> 27 </property> 22 28 <property name="geometry"> 23 29 <rect> 24 30 <x>0</x> 25 31 <y>0</y> 26 <width> 516</width>27 <height>4 98</height>32 <width>600</width> 33 <height>400</height> 28 34 </rect> 29 35 </property> 30 <property name="windowTitle"> 31 <string>Create New Virtual Machine</string> 36 <property name="sizePolicy"> 37 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 38 <horstretch>0</horstretch> 39 <verstretch>0</verstretch> 40 </sizepolicy> 32 41 </property> 33 <layout class="QVBoxLayout" >34 <property name=" margin">42 <layout class="QVBoxLayout" name="m_pLayout1"> 43 <property name="bottomMargin" > 35 44 <number>0</number> 36 45 </property> 37 46 <item> 38 <widget class="Q StackedWidget" name="mPageStack">39 <property name=" currentIndex">40 < number>2</number>47 <widget class="QILabel" name="m_pPage4Text1"> 48 <property name="text"> 49 <string><p>Select a hard disk image to be used as the boot hard disk of the virtual machine. You can either create a new hard disk using the <b>New</b> button or select an existing hard disk image from the drop-down list or by pressing the <b>Existing</b> button (to invoke the Virtual Media Manager dialog).</p><p>If you need a more complicated hard disk setup, you can also skip this step and attach hard disks later using the VM Settings dialog.</p></string> 41 50 </property> 42 <widget class="QWidget" name="mPageWelcome"> 43 <layout class="QVBoxLayout"> 44 <item> 45 <widget class="QLabel" name="mPageWelcomeHdr"> 46 <property name="font"> 47 <font> 48 <family>Arial</family> 49 <pointsize>12</pointsize> 50 <weight>75</weight> 51 <bold>true</bold> 52 </font> 53 </property> 54 <property name="text"> 55 <string>Welcome to the New Virtual Machine Wizard!</string> 56 </property> 57 </widget> 58 </item> 59 <item> 60 <widget class="Line" name="line11"> 61 <property name="orientation"> 62 <enum>Qt::Horizontal</enum> 63 </property> 64 </widget> 65 </item> 66 <item> 67 <layout class="QHBoxLayout"> 68 <property name="spacing"> 69 <number>10</number> 70 </property> 71 <item> 72 <widget class="QLabel" name="mLogoWelcome"> 73 <property name="sizePolicy"> 74 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 75 <horstretch>0</horstretch> 76 <verstretch>0</verstretch> 77 </sizepolicy> 78 </property> 79 <property name="autoFillBackground"> 80 <bool>true</bool> 81 </property> 82 <property name="text"> 83 <string/> 84 </property> 85 <property name="pixmap"> 86 <pixmap resource="../VirtualBox1.qrc">:/vmw_new_welcome.png</pixmap> 87 </property> 88 <property name="alignment"> 89 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 90 </property> 91 </widget> 92 </item> 93 <item> 94 <layout class="QVBoxLayout"> 95 <property name="spacing"> 96 <number>10</number> 97 </property> 98 <item> 99 <widget class="QILabel" name="mTextWelcome"> 100 <property name="sizePolicy"> 101 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 102 <horstretch>0</horstretch> 103 <verstretch>0</verstretch> 104 </sizepolicy> 105 </property> 106 <property name="minimumSize"> 107 <size> 108 <width>300</width> 109 <height>0</height> 110 </size> 111 </property> 112 <property name="text"> 113 <string><p>This wizard will guide you through the steps that are necessary to create a new virtual machine for VirtualBox.</p><p>Use the <b>Next</b> button to go the next page of the wizard and the <b>Back</b> button to return to the previous page.</p></string> 114 </property> 115 <property name="wordWrap"> 116 <bool>true</bool> 117 </property> 118 </widget> 119 </item> 120 <item> 121 <spacer> 122 <property name="orientation"> 123 <enum>Qt::Vertical</enum> 124 </property> 125 <property name="sizeHint" stdset="0"> 126 <size> 127 <width>0</width> 128 <height>0</height> 129 </size> 130 </property> 131 </spacer> 132 </item> 133 </layout> 134 </item> 135 </layout> 136 </item> 137 <item> 138 <widget class="Line" name="line12"> 139 <property name="orientation"> 140 <enum>Qt::Horizontal</enum> 141 </property> 142 </widget> 143 </item> 144 <item> 145 <layout class="QHBoxLayout"> 146 <item> 147 <spacer> 148 <property name="orientation"> 149 <enum>Qt::Horizontal</enum> 150 </property> 151 <property name="sizeHint" stdset="0"> 152 <size> 153 <width>0</width> 154 <height>0</height> 155 </size> 156 </property> 157 </spacer> 158 </item> 159 <item> 160 <widget class="QPushButton" name="mBtnBack1"> 161 <property name="enabled"> 162 <bool>false</bool> 163 </property> 164 <property name="text"> 165 <string>< &Back</string> 166 </property> 167 </widget> 168 </item> 169 <item> 170 <widget class="QPushButton" name="mBtnNext1"> 171 <property name="text"> 172 <string>&Next ></string> 173 </property> 174 </widget> 175 </item> 176 <item> 177 <spacer> 178 <property name="orientation"> 179 <enum>Qt::Horizontal</enum> 180 </property> 181 <property name="sizeType"> 182 <enum>QSizePolicy::Fixed</enum> 183 </property> 184 <property name="sizeHint" stdset="0"> 185 <size> 186 <width>5</width> 187 <height>0</height> 188 </size> 189 </property> 190 </spacer> 191 </item> 192 <item> 193 <widget class="QPushButton" name="mBtnCancel1"> 194 <property name="text"> 195 <string>Cancel</string> 196 </property> 197 </widget> 198 </item> 199 </layout> 200 </item> 201 </layout> 202 </widget> 203 <widget class="QWidget" name="mPageNameAndOS"> 204 <layout class="QVBoxLayout"> 205 <item> 206 <widget class="QLabel" name="mPageNameAndOSHdr"> 207 <property name="font"> 208 <font> 209 <family>Arial</family> 210 <pointsize>12</pointsize> 211 <weight>75</weight> 212 <bold>true</bold> 213 </font> 214 </property> 215 <property name="text"> 216 <string>VM Name and OS Type</string> 217 </property> 218 </widget> 219 </item> 220 <item> 221 <widget class="Line" name="line21"> 222 <property name="orientation"> 223 <enum>Qt::Horizontal</enum> 224 </property> 225 </widget> 226 </item> 227 <item> 228 <layout class="QHBoxLayout"> 229 <property name="spacing"> 230 <number>10</number> 231 </property> 232 <item> 233 <widget class="QLabel" name="mLogoNameAndOS"> 234 <property name="sizePolicy"> 235 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 236 <horstretch>0</horstretch> 237 <verstretch>0</verstretch> 238 </sizepolicy> 239 </property> 240 <property name="autoFillBackground"> 241 <bool>true</bool> 242 </property> 243 <property name="text"> 244 <string/> 245 </property> 246 <property name="pixmap"> 247 <pixmap resource="../VirtualBox1.qrc">:/vmw_new_welcome.png</pixmap> 248 </property> 249 <property name="alignment"> 250 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 251 </property> 252 </widget> 253 </item> 254 <item> 255 <layout class="QVBoxLayout"> 256 <property name="spacing"> 257 <number>10</number> 258 </property> 259 <item> 260 <widget class="QILabel" name="mTextNameAndOS"> 261 <property name="sizePolicy"> 262 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 263 <horstretch>0</horstretch> 264 <verstretch>0</verstretch> 265 </sizepolicy> 266 </property> 267 <property name="minimumSize"> 268 <size> 269 <width>300</width> 270 <height>0</height> 271 </size> 272 </property> 273 <property name="text"> 274 <string><p>Enter a name for the new virtual machine and select the type of the guest operating system you plan to install onto the virtual machine.</p><p>The name of the virtual machine usually indicates its software and hardware configuration. It will be used by all VirtualBox components to identify your virtual machine.</p></string> 275 </property> 276 <property name="wordWrap"> 277 <bool>true</bool> 278 </property> 279 </widget> 280 </item> 281 <item> 282 <widget class="QGroupBox" name="gbName"> 283 <property name="sizePolicy"> 284 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 285 <horstretch>0</horstretch> 286 <verstretch>0</verstretch> 287 </sizepolicy> 288 </property> 289 <property name="title"> 290 <string>N&ame</string> 291 </property> 292 <layout class="QHBoxLayout"> 293 <property name="spacing"> 294 <number>0</number> 295 </property> 296 <property name="leftMargin"> 297 <number>9</number> 298 </property> 299 <property name="topMargin"> 300 <number>4</number> 301 </property> 302 <property name="rightMargin"> 303 <number>9</number> 304 </property> 305 <property name="bottomMargin"> 306 <number>9</number> 307 </property> 308 <item> 309 <widget class="QLineEdit" name="mLeName"/> 310 </item> 311 </layout> 312 </widget> 313 </item> 314 <item> 315 <widget class="QGroupBox" name="gbOSType"> 316 <property name="sizePolicy"> 317 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 318 <horstretch>0</horstretch> 319 <verstretch>0</verstretch> 320 </sizepolicy> 321 </property> 322 <property name="title"> 323 <string>OS &Type</string> 324 </property> 325 <layout class="QHBoxLayout"> 326 <property name="topMargin"> 327 <number>4</number> 328 </property> 329 <item> 330 <widget class="VBoxOSTypeSelectorWidget" name="mOSTypeSelector" native="true"/> 331 </item> 332 </layout> 333 </widget> 334 </item> 335 <item> 336 <spacer> 337 <property name="orientation"> 338 <enum>Qt::Vertical</enum> 339 </property> 340 <property name="sizeHint" stdset="0"> 341 <size> 342 <width>0</width> 343 <height>0</height> 344 </size> 345 </property> 346 </spacer> 347 </item> 348 </layout> 349 </item> 350 </layout> 351 </item> 352 <item> 353 <widget class="Line" name="line22"> 354 <property name="orientation"> 355 <enum>Qt::Horizontal</enum> 356 </property> 357 </widget> 358 </item> 359 <item> 360 <layout class="QHBoxLayout"> 361 <item> 362 <spacer> 363 <property name="orientation"> 364 <enum>Qt::Horizontal</enum> 365 </property> 366 <property name="sizeHint" stdset="0"> 367 <size> 368 <width>0</width> 369 <height>0</height> 370 </size> 371 </property> 372 </spacer> 373 </item> 374 <item> 375 <widget class="QPushButton" name="mBtnBack2"> 376 <property name="text"> 377 <string>< &Back</string> 378 </property> 379 </widget> 380 </item> 381 <item> 382 <widget class="QPushButton" name="mBtnNext2"> 383 <property name="text"> 384 <string>&Next ></string> 385 </property> 386 </widget> 387 </item> 388 <item> 389 <spacer> 390 <property name="orientation"> 391 <enum>Qt::Horizontal</enum> 392 </property> 393 <property name="sizeType"> 394 <enum>QSizePolicy::Fixed</enum> 395 </property> 396 <property name="sizeHint" stdset="0"> 397 <size> 398 <width>5</width> 399 <height>0</height> 400 </size> 401 </property> 402 </spacer> 403 </item> 404 <item> 405 <widget class="QPushButton" name="mBtnCancel2"> 406 <property name="text"> 407 <string>Cancel</string> 408 </property> 409 </widget> 410 </item> 411 </layout> 412 </item> 413 </layout> 414 </widget> 415 <widget class="QWidget" name="mPageMemory"> 416 <layout class="QVBoxLayout"> 417 <item> 418 <widget class="QLabel" name="mPageMemoryHdr"> 419 <property name="font"> 420 <font> 421 <family>Arial</family> 422 <pointsize>12</pointsize> 423 <weight>75</weight> 424 <bold>true</bold> 425 </font> 426 </property> 427 <property name="text"> 428 <string>Memory</string> 429 </property> 430 </widget> 431 </item> 432 <item> 433 <widget class="Line" name="line31"> 434 <property name="orientation"> 435 <enum>Qt::Horizontal</enum> 436 </property> 437 </widget> 438 </item> 439 <item> 440 <layout class="QHBoxLayout"> 441 <property name="spacing"> 442 <number>10</number> 443 </property> 444 <item> 445 <widget class="QLabel" name="mLogoMemory"> 446 <property name="sizePolicy"> 447 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 448 <horstretch>0</horstretch> 449 <verstretch>0</verstretch> 450 </sizepolicy> 451 </property> 452 <property name="autoFillBackground"> 453 <bool>true</bool> 454 </property> 455 <property name="text"> 456 <string/> 457 </property> 458 <property name="pixmap"> 459 <pixmap resource="../VirtualBox1.qrc">:/vmw_new_welcome.png</pixmap> 460 </property> 461 <property name="alignment"> 462 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 463 </property> 464 </widget> 465 </item> 466 <item> 467 <layout class="QVBoxLayout"> 468 <property name="spacing"> 469 <number>10</number> 470 </property> 471 <item> 472 <widget class="QILabel" name="mTextMemory"> 473 <property name="sizePolicy"> 474 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 475 <horstretch>0</horstretch> 476 <verstretch>0</verstretch> 477 </sizepolicy> 478 </property> 479 <property name="minimumSize"> 480 <size> 481 <width>300</width> 482 <height>0</height> 483 </size> 484 </property> 485 <property name="text"> 486 <string><p>Select the amount of base memory (RAM) in megabytes to be allocated to the virtual machine.</p></string> 487 </property> 488 <property name="wordWrap"> 489 <bool>true</bool> 490 </property> 491 </widget> 492 </item> 493 <item> 494 <widget class="QILabel" name="mTextRAMBest"> 495 <property name="sizePolicy"> 496 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 497 <horstretch>0</horstretch> 498 <verstretch>0</verstretch> 499 </sizepolicy> 500 </property> 501 <property name="minimumSize"> 502 <size> 503 <width>300</width> 504 <height>0</height> 505 </size> 506 </property> 507 <property name="text"> 508 <string/> 509 </property> 510 <property name="wordWrap"> 511 <bool>true</bool> 512 </property> 513 </widget> 514 </item> 515 <item> 516 <widget class="QGroupBox" name="gbMemory"> 517 <property name="sizePolicy"> 518 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 519 <horstretch>0</horstretch> 520 <verstretch>0</verstretch> 521 </sizepolicy> 522 </property> 523 <property name="title"> 524 <string>Base &Memory Size</string> 525 </property> 526 <layout class="QGridLayout"> 527 <property name="topMargin"> 528 <number>4</number> 529 </property> 530 <item row="0" column="0" colspan="3"> 531 <widget class="VBoxGuestRAMSlider" name="mSlRAM"> 532 <property name="sizePolicy"> 533 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 534 <horstretch>0</horstretch> 535 <verstretch>0</verstretch> 536 </sizepolicy> 537 </property> 538 <property name="minimumSize"> 539 <size> 540 <width>0</width> 541 <height>0</height> 542 </size> 543 </property> 544 <property name="orientation"> 545 <enum>Qt::Horizontal</enum> 546 </property> 547 <property name="tickPosition"> 548 <enum>QSlider::TicksBelow</enum> 549 </property> 550 </widget> 551 </item> 552 <item row="0" column="3"> 553 <widget class="QILineEdit" name="mLeRAM"> 554 <property name="sizePolicy"> 555 <sizepolicy hsizetype="Preferred" vsizetype="Fixed"> 556 <horstretch>0</horstretch> 557 <verstretch>0</verstretch> 558 </sizepolicy> 559 </property> 560 </widget> 561 </item> 562 <item row="0" column="4"> 563 <widget class="QLabel" name="txRAM"> 564 <property name="sizePolicy"> 565 <sizepolicy hsizetype="Fixed" vsizetype="Fixed"> 566 <horstretch>0</horstretch> 567 <verstretch>0</verstretch> 568 </sizepolicy> 569 </property> 570 <property name="text"> 571 <string>MB</string> 572 </property> 573 </widget> 574 </item> 575 <item row="1" column="0"> 576 <widget class="QLabel" name="mTxRAMMin"> 577 <property name="sizePolicy"> 578 <sizepolicy hsizetype="Minimum" vsizetype="Preferred"> 579 <horstretch>0</horstretch> 580 <verstretch>0</verstretch> 581 </sizepolicy> 582 </property> 583 <property name="text"> 584 <string/> 585 </property> 586 <property name="alignment"> 587 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 588 </property> 589 </widget> 590 </item> 591 <item row="1" column="2"> 592 <widget class="QLabel" name="mTxRAMMax"> 593 <property name="sizePolicy"> 594 <sizepolicy hsizetype="Minimum" vsizetype="Preferred"> 595 <horstretch>0</horstretch> 596 <verstretch>0</verstretch> 597 </sizepolicy> 598 </property> 599 <property name="text"> 600 <string/> 601 </property> 602 <property name="alignment"> 603 <set>Qt::AlignRight|Qt::AlignTop|Qt::AlignTrailing</set> 604 </property> 605 </widget> 606 </item> 607 <item row="1" column="1"> 608 <spacer> 609 <property name="orientation"> 610 <enum>Qt::Horizontal</enum> 611 </property> 612 <property name="sizeHint" stdset="0"> 613 <size> 614 <width>40</width> 615 <height>5</height> 616 </size> 617 </property> 618 </spacer> 619 </item> 620 </layout> 621 </widget> 622 </item> 623 <item> 624 <spacer> 625 <property name="orientation"> 626 <enum>Qt::Vertical</enum> 627 </property> 628 <property name="sizeHint" stdset="0"> 629 <size> 630 <width>0</width> 631 <height>0</height> 632 </size> 633 </property> 634 </spacer> 635 </item> 636 </layout> 637 </item> 638 </layout> 639 </item> 640 <item> 641 <widget class="Line" name="line32"> 642 <property name="orientation"> 643 <enum>Qt::Horizontal</enum> 644 </property> 645 </widget> 646 </item> 647 <item> 648 <layout class="QHBoxLayout"> 649 <item> 650 <spacer> 651 <property name="orientation"> 652 <enum>Qt::Horizontal</enum> 653 </property> 654 <property name="sizeHint" stdset="0"> 655 <size> 656 <width>0</width> 657 <height>0</height> 658 </size> 659 </property> 660 </spacer> 661 </item> 662 <item> 663 <widget class="QPushButton" name="mBtnBack3"> 664 <property name="text"> 665 <string>< &Back</string> 666 </property> 667 </widget> 668 </item> 669 <item> 670 <widget class="QPushButton" name="mBtnNext3"> 671 <property name="text"> 672 <string>&Next ></string> 673 </property> 674 </widget> 675 </item> 676 <item> 677 <spacer> 678 <property name="orientation"> 679 <enum>Qt::Horizontal</enum> 680 </property> 681 <property name="sizeType"> 682 <enum>QSizePolicy::Fixed</enum> 683 </property> 684 <property name="sizeHint" stdset="0"> 685 <size> 686 <width>5</width> 687 <height>0</height> 688 </size> 689 </property> 690 </spacer> 691 </item> 692 <item> 693 <widget class="QPushButton" name="mBtnCancel3"> 694 <property name="text"> 695 <string>Cancel</string> 696 </property> 697 </widget> 698 </item> 699 </layout> 700 </item> 701 </layout> 702 </widget> 703 <widget class="QWidget" name="mPageHDD"> 704 <layout class="QVBoxLayout"> 705 <item> 706 <widget class="QLabel" name="mPageHDDHdr"> 707 <property name="font"> 708 <font> 709 <family>Arial</family> 710 <pointsize>12</pointsize> 711 <weight>75</weight> 712 <bold>true</bold> 713 </font> 714 </property> 715 <property name="text"> 716 <string>Virtual Hard Disk</string> 717 </property> 718 </widget> 719 </item> 720 <item> 721 <widget class="Line" name="line41"> 722 <property name="orientation"> 723 <enum>Qt::Horizontal</enum> 724 </property> 725 </widget> 726 </item> 727 <item> 728 <layout class="QHBoxLayout"> 729 <property name="spacing"> 730 <number>10</number> 731 </property> 732 <item> 733 <widget class="QLabel" name="mLogoHDD"> 734 <property name="sizePolicy"> 735 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 736 <horstretch>0</horstretch> 737 <verstretch>0</verstretch> 738 </sizepolicy> 739 </property> 740 <property name="autoFillBackground"> 741 <bool>true</bool> 742 </property> 743 <property name="text"> 744 <string/> 745 </property> 746 <property name="pixmap"> 747 <pixmap resource="../VirtualBox1.qrc">:/vmw_new_welcome.png</pixmap> 748 </property> 749 <property name="alignment"> 750 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 751 </property> 752 </widget> 753 </item> 754 <item> 755 <layout class="QVBoxLayout"> 756 <property name="spacing"> 757 <number>10</number> 758 </property> 759 <item> 760 <widget class="QILabel" name="mTextVDI"> 761 <property name="sizePolicy"> 762 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 763 <horstretch>0</horstretch> 764 <verstretch>0</verstretch> 765 </sizepolicy> 766 </property> 767 <property name="minimumSize"> 768 <size> 769 <width>300</width> 770 <height>0</height> 771 </size> 772 </property> 773 <property name="text"> 774 <string><p>Select a hard disk image to be used as the boot hard disk of the virtual machine. You can either create a new hard disk using the <b>New</b> button or select an existing hard disk image from the drop-down list or by pressing the <b>Existing</b> button (to invoke the Virtual Media Manager dialog).</p><p>If you need a more complicated hard disk setup, you can also skip this step and attach hard disks later using the VM Settings dialog.</p></string> 775 </property> 776 <property name="wordWrap"> 777 <bool>true</bool> 778 </property> 779 </widget> 780 </item> 781 <item> 782 <widget class="QILabel" name="mTextVDIBest"> 783 <property name="sizePolicy"> 784 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 785 <horstretch>0</horstretch> 786 <verstretch>0</verstretch> 787 </sizepolicy> 788 </property> 789 <property name="minimumSize"> 790 <size> 791 <width>300</width> 792 <height>0</height> 793 </size> 794 </property> 795 <property name="text"> 796 <string/> 797 </property> 798 <property name="wordWrap"> 799 <bool>true</bool> 800 </property> 801 </widget> 802 </item> 803 <item> 804 <widget class="QGroupBox" name="mGbHDA"> 805 <property name="sizePolicy"> 806 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 807 <horstretch>0</horstretch> 808 <verstretch>0</verstretch> 809 </sizepolicy> 810 </property> 811 <property name="title"> 812 <string>Boot Hard &Disk (Primary Master)</string> 813 </property> 814 <property name="checkable"> 815 <bool>true</bool> 816 </property> 817 <layout class="QGridLayout"> 818 <item row="0" column="0" colspan="3"> 819 <widget class="QRadioButton" name="mNewVDIRadio"> 820 <property name="text"> 821 <string>&Create new hard disk</string> 822 </property> 823 <property name="checked"> 824 <bool>true</bool> 825 </property> 826 </widget> 827 </item> 828 <item row="1" column="0" colspan="3"> 829 <widget class="QRadioButton" name="mExistRadio"> 830 <property name="text"> 831 <string>&Use existing hard disk</string> 832 </property> 833 </widget> 834 </item> 835 <item row="2" column="1"> 836 <widget class="VBoxMediaComboBox" name="mHDCombo"> 837 <property name="sizePolicy"> 838 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 839 <horstretch>0</horstretch> 840 <verstretch>0</verstretch> 841 </sizepolicy> 842 </property> 843 </widget> 844 </item> 845 <item row="2" column="2"> 846 <widget class="QToolButton" name="mTbVmm"> 847 <property name="autoRaise"> 848 <bool>true</bool> 849 </property> 850 </widget> 851 </item> 852 </layout> 853 </widget> 854 </item> 855 <item> 856 <spacer> 857 <property name="orientation"> 858 <enum>Qt::Vertical</enum> 859 </property> 860 <property name="sizeHint" stdset="0"> 861 <size> 862 <width>0</width> 863 <height>0</height> 864 </size> 865 </property> 866 </spacer> 867 </item> 868 </layout> 869 </item> 870 </layout> 871 </item> 872 <item> 873 <widget class="Line" name="line42"> 874 <property name="orientation"> 875 <enum>Qt::Horizontal</enum> 876 </property> 877 </widget> 878 </item> 879 <item> 880 <layout class="QHBoxLayout"> 881 <item> 882 <spacer> 883 <property name="orientation"> 884 <enum>Qt::Horizontal</enum> 885 </property> 886 <property name="sizeHint" stdset="0"> 887 <size> 888 <width>0</width> 889 <height>0</height> 890 </size> 891 </property> 892 </spacer> 893 </item> 894 <item> 895 <widget class="QPushButton" name="mBtnBack4"> 896 <property name="text"> 897 <string>< &Back</string> 898 </property> 899 </widget> 900 </item> 901 <item> 902 <widget class="QPushButton" name="mBtnNext4"> 903 <property name="text"> 904 <string>&Next ></string> 905 </property> 906 </widget> 907 </item> 908 <item> 909 <spacer> 910 <property name="orientation"> 911 <enum>Qt::Horizontal</enum> 912 </property> 913 <property name="sizeType"> 914 <enum>QSizePolicy::Fixed</enum> 915 </property> 916 <property name="sizeHint" stdset="0"> 917 <size> 918 <width>5</width> 919 <height>0</height> 920 </size> 921 </property> 922 </spacer> 923 </item> 924 <item> 925 <widget class="QPushButton" name="mBtnCancel4"> 926 <property name="text"> 927 <string>Cancel</string> 928 </property> 929 </widget> 930 </item> 931 </layout> 932 </item> 933 </layout> 934 </widget> 935 <widget class="QWidget" name="mPageSummary"> 936 <layout class="QVBoxLayout"> 937 <item> 938 <widget class="QLabel" name="mPageSummaryHdr"> 939 <property name="font"> 940 <font> 941 <family>Arial</family> 942 <pointsize>12</pointsize> 943 <weight>75</weight> 944 <bold>true</bold> 945 </font> 946 </property> 947 <property name="text"> 948 <string>Summary</string> 949 </property> 950 </widget> 951 </item> 952 <item> 953 <widget class="Line" name="line51"> 954 <property name="orientation"> 955 <enum>Qt::Horizontal</enum> 956 </property> 957 </widget> 958 </item> 959 <item> 960 <layout class="QHBoxLayout"> 961 <property name="spacing"> 962 <number>10</number> 963 </property> 964 <item> 965 <widget class="QLabel" name="mLogoSummary"> 966 <property name="sizePolicy"> 967 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 968 <horstretch>0</horstretch> 969 <verstretch>0</verstretch> 970 </sizepolicy> 971 </property> 972 <property name="autoFillBackground"> 973 <bool>true</bool> 974 </property> 975 <property name="text"> 976 <string/> 977 </property> 978 <property name="pixmap"> 979 <pixmap resource="../VirtualBox1.qrc">:/vmw_new_welcome.png</pixmap> 980 </property> 981 <property name="alignment"> 982 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 983 </property> 984 </widget> 985 </item> 986 <item> 987 <layout class="QVBoxLayout"> 988 <property name="spacing"> 989 <number>10</number> 990 </property> 991 <item> 992 <widget class="QILabel" name="mTextSummaryHdr"> 993 <property name="sizePolicy"> 994 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 995 <horstretch>0</horstretch> 996 <verstretch>0</verstretch> 997 </sizepolicy> 998 </property> 999 <property name="minimumSize"> 1000 <size> 1001 <width>300</width> 1002 <height>0</height> 1003 </size> 1004 </property> 1005 <property name="text"> 1006 <string><p>You are going to create a new virtual machine with the following parameters:</p></string> 1007 </property> 1008 <property name="wordWrap"> 1009 <bool>true</bool> 1010 </property> 1011 </widget> 1012 </item> 1013 <item> 1014 <widget class="QITextEdit" name="mTeSummary"> 1015 <property name="sizePolicy"> 1016 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 1017 <horstretch>0</horstretch> 1018 <verstretch>0</verstretch> 1019 </sizepolicy> 1020 </property> 1021 <property name="minimumSize"> 1022 <size> 1023 <width>300</width> 1024 <height>0</height> 1025 </size> 1026 </property> 1027 <property name="frameShape"> 1028 <enum>QFrame::NoFrame</enum> 1029 </property> 1030 <property name="autoFormatting"> 1031 <set>QTextEdit::AutoAll</set> 1032 </property> 1033 <property name="readOnly"> 1034 <bool>true</bool> 1035 </property> 1036 </widget> 1037 </item> 1038 <item> 1039 <widget class="QILabel" name="mTextSummaryFtr"> 1040 <property name="sizePolicy"> 1041 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 1042 <horstretch>0</horstretch> 1043 <verstretch>0</verstretch> 1044 </sizepolicy> 1045 </property> 1046 <property name="minimumSize"> 1047 <size> 1048 <width>300</width> 1049 <height>0</height> 1050 </size> 1051 </property> 1052 <property name="text"> 1053 <string><p>If the above is correct press the <b>Finish</b> button. Once you press it, a new virtual machine will be created. </p><p>Note that you can alter these and all other setting of the created virtual machine at any time using the <b>Settings</b> dialog accessible through the menu of the main window.</p></string> 1054 </property> 1055 <property name="wordWrap"> 1056 <bool>true</bool> 1057 </property> 1058 </widget> 1059 </item> 1060 <item> 1061 <spacer> 1062 <property name="orientation"> 1063 <enum>Qt::Vertical</enum> 1064 </property> 1065 <property name="sizeType"> 1066 <enum>QSizePolicy::Expanding</enum> 1067 </property> 1068 <property name="sizeHint" stdset="0"> 1069 <size> 1070 <width>0</width> 1071 <height>0</height> 1072 </size> 1073 </property> 1074 </spacer> 1075 </item> 1076 </layout> 1077 </item> 1078 </layout> 1079 </item> 1080 <item> 1081 <widget class="Line" name="line52"> 1082 <property name="orientation"> 1083 <enum>Qt::Horizontal</enum> 1084 </property> 1085 </widget> 1086 </item> 1087 <item> 1088 <layout class="QHBoxLayout"> 1089 <item> 1090 <spacer> 1091 <property name="orientation"> 1092 <enum>Qt::Horizontal</enum> 1093 </property> 1094 <property name="sizeHint" stdset="0"> 1095 <size> 1096 <width>0</width> 1097 <height>0</height> 1098 </size> 1099 </property> 1100 </spacer> 1101 </item> 1102 <item> 1103 <widget class="QPushButton" name="mBtnBack5"> 1104 <property name="text"> 1105 <string>< &Back</string> 1106 </property> 1107 </widget> 1108 </item> 1109 <item> 1110 <widget class="QPushButton" name="mBtnFinish"> 1111 <property name="text"> 1112 <string>&Finish</string> 1113 </property> 1114 </widget> 1115 </item> 1116 <item> 1117 <spacer> 1118 <property name="orientation"> 1119 <enum>Qt::Horizontal</enum> 1120 </property> 1121 <property name="sizeType"> 1122 <enum>QSizePolicy::Fixed</enum> 1123 </property> 1124 <property name="sizeHint" stdset="0"> 1125 <size> 1126 <width>5</width> 1127 <height>0</height> 1128 </size> 1129 </property> 1130 </spacer> 1131 </item> 1132 <item> 1133 <widget class="QPushButton" name="mBtnCancel5"> 1134 <property name="text"> 1135 <string>Cancel</string> 1136 </property> 1137 </widget> 1138 </item> 1139 </layout> 1140 </item> 1141 </layout> 1142 </widget> 51 <property name="wordWrap"> 52 <bool>true</bool> 53 </property> 1143 54 </widget> 55 </item> 56 <item> 57 <widget class="QILabel" name="m_pPage4Text2"> 58 <property name="wordWrap"> 59 <bool>true</bool> 60 </property> 61 </widget> 62 </item> 63 <item> 64 <widget class="QGroupBox" name="m_pBootHDCnt"> 65 <property name="title"> 66 <string>Boot Hard &Disk (Primary Master)</string> 67 </property> 68 <property name="checkable"> 69 <bool>true</bool> 70 </property> 71 <layout class="QGridLayout" name="m_pLayout2"> 72 <item row="0" column="0" colspan="3"> 73 <widget class="QRadioButton" name="m_pDiskCreate"> 74 <property name="text"> 75 <string>&Create new hard disk</string> 76 </property> 77 <property name="checked"> 78 <bool>true</bool> 79 </property> 80 </widget> 81 </item> 82 <item row="1" column="0" colspan="3"> 83 <widget class="QRadioButton" name="m_pDiskPresent"> 84 <property name="text"> 85 <string>&Use existing hard disk</string> 86 </property> 87 </widget> 88 </item> 89 <item row="2" column="1"> 90 <widget class="VBoxMediaComboBox" name="m_pDiskSelector"/> 91 </item> 92 <item row="2" column="2"> 93 <widget class="QToolButton" name="m_pVMMButton"> 94 <property name="autoRaise"> 95 <bool>true</bool> 96 </property> 97 </widget> 98 </item> 99 </layout> 100 </widget> 101 </item> 102 <item> 103 <spacer name="m_pSpacer1"> 104 <property name="sizeHint" stdset="0"> 105 <size> 106 <width>0</width> 107 <height>0</height> 108 </size> 109 </property> 110 </spacer> 1144 111 </item> 1145 112 </layout> … … 1152 119 </customwidget> 1153 120 <customwidget> 1154 <class>VBoxOSTypeSelectorWidget</class>1155 <extends>QWidget</extends>1156 <header>VBoxOSTypeSelectorWidget.h</header>1157 </customwidget>1158 <customwidget>1159 121 <class>VBoxMediaComboBox</class> 1160 122 <extends>QComboBox</extends> 1161 123 <header>VBoxMediaComboBox.h</header> 1162 124 </customwidget> 1163 <customwidget>1164 <class>QITextEdit</class>1165 <extends>QTextEdit</extends>1166 <header>QIAbstractWizard.h</header>1167 </customwidget>1168 <customwidget>1169 <class>QILineEdit</class>1170 <extends>QLineEdit</extends>1171 <header>QILineEdit.h</header>1172 </customwidget>1173 <customwidget>1174 <class>QIAdvancedSlider</class>1175 <extends>QSlider</extends>1176 <header>QIAdvancedSlider.h</header>1177 </customwidget>1178 <customwidget>1179 <class>VBoxGuestRAMSlider</class>1180 <extends>QIAdvancedSlider</extends>1181 <header>VBoxGuestRAMSlider.h</header>1182 </customwidget>1183 125 </customwidgets> 1184 <tabstops> 1185 <tabstop>mBtnNext1</tabstop> 1186 <tabstop>mBtnCancel1</tabstop> 1187 <tabstop>mLeName</tabstop> 1188 <tabstop>mOSTypeSelector</tabstop> 1189 <tabstop>mBtnBack2</tabstop> 1190 <tabstop>mBtnNext2</tabstop> 1191 <tabstop>mBtnCancel2</tabstop> 1192 <tabstop>mSlRAM</tabstop> 1193 <tabstop>mLeRAM</tabstop> 1194 <tabstop>mBtnBack3</tabstop> 1195 <tabstop>mBtnNext3</tabstop> 1196 <tabstop>mBtnCancel3</tabstop> 1197 <tabstop>mNewVDIRadio</tabstop> 1198 <tabstop>mExistRadio</tabstop> 1199 <tabstop>mHDCombo</tabstop> 1200 <tabstop>mTbVmm</tabstop> 1201 <tabstop>mBtnBack4</tabstop> 1202 <tabstop>mBtnNext4</tabstop> 1203 <tabstop>mBtnCancel4</tabstop> 1204 <tabstop>mBtnBack5</tabstop> 1205 <tabstop>mBtnFinish</tabstop> 1206 <tabstop>mBtnCancel5</tabstop> 1207 </tabstops> 1208 <resources> 1209 <include location="../VirtualBox1.qrc"/> 1210 </resources> 126 <resources/> 1211 127 <connections/> 1212 128 </ui> -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/newvm/UINewVMWzdPage5.ui
r25267 r26079 2 2 <ui version="4.0"> 3 3 <comment> 4 VBox frontends: Qt4 GUI ( "VirtualBox"):4 VBox frontends: Qt4 GUI ("VirtualBox"): 5 5 6 Copyright (C) 200 8Sun Microsystems, Inc.6 Copyright (C) 2009 Sun Microsystems, Inc. 7 7 8 8 This file is part of VirtualBox Open Source Edition (OSE), as … … 18 18 additional information or have any questions. 19 19 </comment> 20 <class>VBoxNewVMWzd</class> 21 <widget class="QDialog" name="VBoxNewVMWzd"> 20 <class>UINewVMWzdPage5</class> 21 <widget class="QWidget" name="UINewVMWzdPage5"> 22 <property name="sizePolicy"> 23 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 24 <horstretch>0</horstretch> 25 <verstretch>0</verstretch> 26 </sizepolicy> 27 </property> 22 28 <property name="geometry"> 23 29 <rect> 24 30 <x>0</x> 25 31 <y>0</y> 26 <width> 516</width>27 <height>4 98</height>32 <width>600</width> 33 <height>400</height> 28 34 </rect> 29 35 </property> 30 <property name="windowTitle"> 31 <string>Create New Virtual Machine</string> 36 <property name="sizePolicy"> 37 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 38 <horstretch>0</horstretch> 39 <verstretch>0</verstretch> 40 </sizepolicy> 32 41 </property> 33 <layout class="QVBoxLayout" >34 <property name=" margin">42 <layout class="QVBoxLayout" name="m_pLayout1"> 43 <property name="bottomMargin" > 35 44 <number>0</number> 36 45 </property> 37 46 <item> 38 <widget class="Q StackedWidget" name="mPageStack">39 <property name=" currentIndex">40 < number>2</number>47 <widget class="QILabel" name="m_pPage5Text1"> 48 <property name="text"> 49 <string><p>You are going to create a new virtual machine with the following parameters:</p></string> 41 50 </property> 42 <widget class="QWidget" name="mPageWelcome"> 43 <layout class="QVBoxLayout"> 44 <item> 45 <widget class="QLabel" name="mPageWelcomeHdr"> 46 <property name="font"> 47 <font> 48 <family>Arial</family> 49 <pointsize>12</pointsize> 50 <weight>75</weight> 51 <bold>true</bold> 52 </font> 53 </property> 54 <property name="text"> 55 <string>Welcome to the New Virtual Machine Wizard!</string> 56 </property> 57 </widget> 58 </item> 59 <item> 60 <widget class="Line" name="line11"> 61 <property name="orientation"> 62 <enum>Qt::Horizontal</enum> 63 </property> 64 </widget> 65 </item> 66 <item> 67 <layout class="QHBoxLayout"> 68 <property name="spacing"> 69 <number>10</number> 70 </property> 71 <item> 72 <widget class="QLabel" name="mLogoWelcome"> 73 <property name="sizePolicy"> 74 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 75 <horstretch>0</horstretch> 76 <verstretch>0</verstretch> 77 </sizepolicy> 78 </property> 79 <property name="autoFillBackground"> 80 <bool>true</bool> 81 </property> 82 <property name="text"> 83 <string/> 84 </property> 85 <property name="pixmap"> 86 <pixmap resource="../VirtualBox1.qrc">:/vmw_new_welcome.png</pixmap> 87 </property> 88 <property name="alignment"> 89 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 90 </property> 91 </widget> 92 </item> 93 <item> 94 <layout class="QVBoxLayout"> 95 <property name="spacing"> 96 <number>10</number> 97 </property> 98 <item> 99 <widget class="QILabel" name="mTextWelcome"> 100 <property name="sizePolicy"> 101 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 102 <horstretch>0</horstretch> 103 <verstretch>0</verstretch> 104 </sizepolicy> 105 </property> 106 <property name="minimumSize"> 107 <size> 108 <width>300</width> 109 <height>0</height> 110 </size> 111 </property> 112 <property name="text"> 113 <string><p>This wizard will guide you through the steps that are necessary to create a new virtual machine for VirtualBox.</p><p>Use the <b>Next</b> button to go the next page of the wizard and the <b>Back</b> button to return to the previous page.</p></string> 114 </property> 115 <property name="wordWrap"> 116 <bool>true</bool> 117 </property> 118 </widget> 119 </item> 120 <item> 121 <spacer> 122 <property name="orientation"> 123 <enum>Qt::Vertical</enum> 124 </property> 125 <property name="sizeHint" stdset="0"> 126 <size> 127 <width>0</width> 128 <height>0</height> 129 </size> 130 </property> 131 </spacer> 132 </item> 133 </layout> 134 </item> 135 </layout> 136 </item> 137 <item> 138 <widget class="Line" name="line12"> 139 <property name="orientation"> 140 <enum>Qt::Horizontal</enum> 141 </property> 142 </widget> 143 </item> 144 <item> 145 <layout class="QHBoxLayout"> 146 <item> 147 <spacer> 148 <property name="orientation"> 149 <enum>Qt::Horizontal</enum> 150 </property> 151 <property name="sizeHint" stdset="0"> 152 <size> 153 <width>0</width> 154 <height>0</height> 155 </size> 156 </property> 157 </spacer> 158 </item> 159 <item> 160 <widget class="QPushButton" name="mBtnBack1"> 161 <property name="enabled"> 162 <bool>false</bool> 163 </property> 164 <property name="text"> 165 <string>< &Back</string> 166 </property> 167 </widget> 168 </item> 169 <item> 170 <widget class="QPushButton" name="mBtnNext1"> 171 <property name="text"> 172 <string>&Next ></string> 173 </property> 174 </widget> 175 </item> 176 <item> 177 <spacer> 178 <property name="orientation"> 179 <enum>Qt::Horizontal</enum> 180 </property> 181 <property name="sizeType"> 182 <enum>QSizePolicy::Fixed</enum> 183 </property> 184 <property name="sizeHint" stdset="0"> 185 <size> 186 <width>5</width> 187 <height>0</height> 188 </size> 189 </property> 190 </spacer> 191 </item> 192 <item> 193 <widget class="QPushButton" name="mBtnCancel1"> 194 <property name="text"> 195 <string>Cancel</string> 196 </property> 197 </widget> 198 </item> 199 </layout> 200 </item> 201 </layout> 202 </widget> 203 <widget class="QWidget" name="mPageNameAndOS"> 204 <layout class="QVBoxLayout"> 205 <item> 206 <widget class="QLabel" name="mPageNameAndOSHdr"> 207 <property name="font"> 208 <font> 209 <family>Arial</family> 210 <pointsize>12</pointsize> 211 <weight>75</weight> 212 <bold>true</bold> 213 </font> 214 </property> 215 <property name="text"> 216 <string>VM Name and OS Type</string> 217 </property> 218 </widget> 219 </item> 220 <item> 221 <widget class="Line" name="line21"> 222 <property name="orientation"> 223 <enum>Qt::Horizontal</enum> 224 </property> 225 </widget> 226 </item> 227 <item> 228 <layout class="QHBoxLayout"> 229 <property name="spacing"> 230 <number>10</number> 231 </property> 232 <item> 233 <widget class="QLabel" name="mLogoNameAndOS"> 234 <property name="sizePolicy"> 235 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 236 <horstretch>0</horstretch> 237 <verstretch>0</verstretch> 238 </sizepolicy> 239 </property> 240 <property name="autoFillBackground"> 241 <bool>true</bool> 242 </property> 243 <property name="text"> 244 <string/> 245 </property> 246 <property name="pixmap"> 247 <pixmap resource="../VirtualBox1.qrc">:/vmw_new_welcome.png</pixmap> 248 </property> 249 <property name="alignment"> 250 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 251 </property> 252 </widget> 253 </item> 254 <item> 255 <layout class="QVBoxLayout"> 256 <property name="spacing"> 257 <number>10</number> 258 </property> 259 <item> 260 <widget class="QILabel" name="mTextNameAndOS"> 261 <property name="sizePolicy"> 262 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 263 <horstretch>0</horstretch> 264 <verstretch>0</verstretch> 265 </sizepolicy> 266 </property> 267 <property name="minimumSize"> 268 <size> 269 <width>300</width> 270 <height>0</height> 271 </size> 272 </property> 273 <property name="text"> 274 <string><p>Enter a name for the new virtual machine and select the type of the guest operating system you plan to install onto the virtual machine.</p><p>The name of the virtual machine usually indicates its software and hardware configuration. It will be used by all VirtualBox components to identify your virtual machine.</p></string> 275 </property> 276 <property name="wordWrap"> 277 <bool>true</bool> 278 </property> 279 </widget> 280 </item> 281 <item> 282 <widget class="QGroupBox" name="gbName"> 283 <property name="sizePolicy"> 284 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 285 <horstretch>0</horstretch> 286 <verstretch>0</verstretch> 287 </sizepolicy> 288 </property> 289 <property name="title"> 290 <string>N&ame</string> 291 </property> 292 <layout class="QHBoxLayout"> 293 <property name="spacing"> 294 <number>0</number> 295 </property> 296 <property name="leftMargin"> 297 <number>9</number> 298 </property> 299 <property name="topMargin"> 300 <number>4</number> 301 </property> 302 <property name="rightMargin"> 303 <number>9</number> 304 </property> 305 <property name="bottomMargin"> 306 <number>9</number> 307 </property> 308 <item> 309 <widget class="QLineEdit" name="mLeName"/> 310 </item> 311 </layout> 312 </widget> 313 </item> 314 <item> 315 <widget class="QGroupBox" name="gbOSType"> 316 <property name="sizePolicy"> 317 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 318 <horstretch>0</horstretch> 319 <verstretch>0</verstretch> 320 </sizepolicy> 321 </property> 322 <property name="title"> 323 <string>OS &Type</string> 324 </property> 325 <layout class="QHBoxLayout"> 326 <property name="topMargin"> 327 <number>4</number> 328 </property> 329 <item> 330 <widget class="VBoxOSTypeSelectorWidget" name="mOSTypeSelector" native="true"/> 331 </item> 332 </layout> 333 </widget> 334 </item> 335 <item> 336 <spacer> 337 <property name="orientation"> 338 <enum>Qt::Vertical</enum> 339 </property> 340 <property name="sizeHint" stdset="0"> 341 <size> 342 <width>0</width> 343 <height>0</height> 344 </size> 345 </property> 346 </spacer> 347 </item> 348 </layout> 349 </item> 350 </layout> 351 </item> 352 <item> 353 <widget class="Line" name="line22"> 354 <property name="orientation"> 355 <enum>Qt::Horizontal</enum> 356 </property> 357 </widget> 358 </item> 359 <item> 360 <layout class="QHBoxLayout"> 361 <item> 362 <spacer> 363 <property name="orientation"> 364 <enum>Qt::Horizontal</enum> 365 </property> 366 <property name="sizeHint" stdset="0"> 367 <size> 368 <width>0</width> 369 <height>0</height> 370 </size> 371 </property> 372 </spacer> 373 </item> 374 <item> 375 <widget class="QPushButton" name="mBtnBack2"> 376 <property name="text"> 377 <string>< &Back</string> 378 </property> 379 </widget> 380 </item> 381 <item> 382 <widget class="QPushButton" name="mBtnNext2"> 383 <property name="text"> 384 <string>&Next ></string> 385 </property> 386 </widget> 387 </item> 388 <item> 389 <spacer> 390 <property name="orientation"> 391 <enum>Qt::Horizontal</enum> 392 </property> 393 <property name="sizeType"> 394 <enum>QSizePolicy::Fixed</enum> 395 </property> 396 <property name="sizeHint" stdset="0"> 397 <size> 398 <width>5</width> 399 <height>0</height> 400 </size> 401 </property> 402 </spacer> 403 </item> 404 <item> 405 <widget class="QPushButton" name="mBtnCancel2"> 406 <property name="text"> 407 <string>Cancel</string> 408 </property> 409 </widget> 410 </item> 411 </layout> 412 </item> 413 </layout> 414 </widget> 415 <widget class="QWidget" name="mPageMemory"> 416 <layout class="QVBoxLayout"> 417 <item> 418 <widget class="QLabel" name="mPageMemoryHdr"> 419 <property name="font"> 420 <font> 421 <family>Arial</family> 422 <pointsize>12</pointsize> 423 <weight>75</weight> 424 <bold>true</bold> 425 </font> 426 </property> 427 <property name="text"> 428 <string>Memory</string> 429 </property> 430 </widget> 431 </item> 432 <item> 433 <widget class="Line" name="line31"> 434 <property name="orientation"> 435 <enum>Qt::Horizontal</enum> 436 </property> 437 </widget> 438 </item> 439 <item> 440 <layout class="QHBoxLayout"> 441 <property name="spacing"> 442 <number>10</number> 443 </property> 444 <item> 445 <widget class="QLabel" name="mLogoMemory"> 446 <property name="sizePolicy"> 447 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 448 <horstretch>0</horstretch> 449 <verstretch>0</verstretch> 450 </sizepolicy> 451 </property> 452 <property name="autoFillBackground"> 453 <bool>true</bool> 454 </property> 455 <property name="text"> 456 <string/> 457 </property> 458 <property name="pixmap"> 459 <pixmap resource="../VirtualBox1.qrc">:/vmw_new_welcome.png</pixmap> 460 </property> 461 <property name="alignment"> 462 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 463 </property> 464 </widget> 465 </item> 466 <item> 467 <layout class="QVBoxLayout"> 468 <property name="spacing"> 469 <number>10</number> 470 </property> 471 <item> 472 <widget class="QILabel" name="mTextMemory"> 473 <property name="sizePolicy"> 474 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 475 <horstretch>0</horstretch> 476 <verstretch>0</verstretch> 477 </sizepolicy> 478 </property> 479 <property name="minimumSize"> 480 <size> 481 <width>300</width> 482 <height>0</height> 483 </size> 484 </property> 485 <property name="text"> 486 <string><p>Select the amount of base memory (RAM) in megabytes to be allocated to the virtual machine.</p></string> 487 </property> 488 <property name="wordWrap"> 489 <bool>true</bool> 490 </property> 491 </widget> 492 </item> 493 <item> 494 <widget class="QILabel" name="mTextRAMBest"> 495 <property name="sizePolicy"> 496 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 497 <horstretch>0</horstretch> 498 <verstretch>0</verstretch> 499 </sizepolicy> 500 </property> 501 <property name="minimumSize"> 502 <size> 503 <width>300</width> 504 <height>0</height> 505 </size> 506 </property> 507 <property name="text"> 508 <string/> 509 </property> 510 <property name="wordWrap"> 511 <bool>true</bool> 512 </property> 513 </widget> 514 </item> 515 <item> 516 <widget class="QGroupBox" name="gbMemory"> 517 <property name="sizePolicy"> 518 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 519 <horstretch>0</horstretch> 520 <verstretch>0</verstretch> 521 </sizepolicy> 522 </property> 523 <property name="title"> 524 <string>Base &Memory Size</string> 525 </property> 526 <layout class="QGridLayout"> 527 <property name="topMargin"> 528 <number>4</number> 529 </property> 530 <item row="0" column="0" colspan="3"> 531 <widget class="VBoxGuestRAMSlider" name="mSlRAM"> 532 <property name="sizePolicy"> 533 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 534 <horstretch>0</horstretch> 535 <verstretch>0</verstretch> 536 </sizepolicy> 537 </property> 538 <property name="minimumSize"> 539 <size> 540 <width>0</width> 541 <height>0</height> 542 </size> 543 </property> 544 <property name="orientation"> 545 <enum>Qt::Horizontal</enum> 546 </property> 547 <property name="tickPosition"> 548 <enum>QSlider::TicksBelow</enum> 549 </property> 550 </widget> 551 </item> 552 <item row="0" column="3"> 553 <widget class="QILineEdit" name="mLeRAM"> 554 <property name="sizePolicy"> 555 <sizepolicy hsizetype="Preferred" vsizetype="Fixed"> 556 <horstretch>0</horstretch> 557 <verstretch>0</verstretch> 558 </sizepolicy> 559 </property> 560 </widget> 561 </item> 562 <item row="0" column="4"> 563 <widget class="QLabel" name="txRAM"> 564 <property name="sizePolicy"> 565 <sizepolicy hsizetype="Fixed" vsizetype="Fixed"> 566 <horstretch>0</horstretch> 567 <verstretch>0</verstretch> 568 </sizepolicy> 569 </property> 570 <property name="text"> 571 <string>MB</string> 572 </property> 573 </widget> 574 </item> 575 <item row="1" column="0"> 576 <widget class="QLabel" name="mTxRAMMin"> 577 <property name="sizePolicy"> 578 <sizepolicy hsizetype="Minimum" vsizetype="Preferred"> 579 <horstretch>0</horstretch> 580 <verstretch>0</verstretch> 581 </sizepolicy> 582 </property> 583 <property name="text"> 584 <string/> 585 </property> 586 <property name="alignment"> 587 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 588 </property> 589 </widget> 590 </item> 591 <item row="1" column="2"> 592 <widget class="QLabel" name="mTxRAMMax"> 593 <property name="sizePolicy"> 594 <sizepolicy hsizetype="Minimum" vsizetype="Preferred"> 595 <horstretch>0</horstretch> 596 <verstretch>0</verstretch> 597 </sizepolicy> 598 </property> 599 <property name="text"> 600 <string/> 601 </property> 602 <property name="alignment"> 603 <set>Qt::AlignRight|Qt::AlignTop|Qt::AlignTrailing</set> 604 </property> 605 </widget> 606 </item> 607 <item row="1" column="1"> 608 <spacer> 609 <property name="orientation"> 610 <enum>Qt::Horizontal</enum> 611 </property> 612 <property name="sizeHint" stdset="0"> 613 <size> 614 <width>40</width> 615 <height>5</height> 616 </size> 617 </property> 618 </spacer> 619 </item> 620 </layout> 621 </widget> 622 </item> 623 <item> 624 <spacer> 625 <property name="orientation"> 626 <enum>Qt::Vertical</enum> 627 </property> 628 <property name="sizeHint" stdset="0"> 629 <size> 630 <width>0</width> 631 <height>0</height> 632 </size> 633 </property> 634 </spacer> 635 </item> 636 </layout> 637 </item> 638 </layout> 639 </item> 640 <item> 641 <widget class="Line" name="line32"> 642 <property name="orientation"> 643 <enum>Qt::Horizontal</enum> 644 </property> 645 </widget> 646 </item> 647 <item> 648 <layout class="QHBoxLayout"> 649 <item> 650 <spacer> 651 <property name="orientation"> 652 <enum>Qt::Horizontal</enum> 653 </property> 654 <property name="sizeHint" stdset="0"> 655 <size> 656 <width>0</width> 657 <height>0</height> 658 </size> 659 </property> 660 </spacer> 661 </item> 662 <item> 663 <widget class="QPushButton" name="mBtnBack3"> 664 <property name="text"> 665 <string>< &Back</string> 666 </property> 667 </widget> 668 </item> 669 <item> 670 <widget class="QPushButton" name="mBtnNext3"> 671 <property name="text"> 672 <string>&Next ></string> 673 </property> 674 </widget> 675 </item> 676 <item> 677 <spacer> 678 <property name="orientation"> 679 <enum>Qt::Horizontal</enum> 680 </property> 681 <property name="sizeType"> 682 <enum>QSizePolicy::Fixed</enum> 683 </property> 684 <property name="sizeHint" stdset="0"> 685 <size> 686 <width>5</width> 687 <height>0</height> 688 </size> 689 </property> 690 </spacer> 691 </item> 692 <item> 693 <widget class="QPushButton" name="mBtnCancel3"> 694 <property name="text"> 695 <string>Cancel</string> 696 </property> 697 </widget> 698 </item> 699 </layout> 700 </item> 701 </layout> 702 </widget> 703 <widget class="QWidget" name="mPageHDD"> 704 <layout class="QVBoxLayout"> 705 <item> 706 <widget class="QLabel" name="mPageHDDHdr"> 707 <property name="font"> 708 <font> 709 <family>Arial</family> 710 <pointsize>12</pointsize> 711 <weight>75</weight> 712 <bold>true</bold> 713 </font> 714 </property> 715 <property name="text"> 716 <string>Virtual Hard Disk</string> 717 </property> 718 </widget> 719 </item> 720 <item> 721 <widget class="Line" name="line41"> 722 <property name="orientation"> 723 <enum>Qt::Horizontal</enum> 724 </property> 725 </widget> 726 </item> 727 <item> 728 <layout class="QHBoxLayout"> 729 <property name="spacing"> 730 <number>10</number> 731 </property> 732 <item> 733 <widget class="QLabel" name="mLogoHDD"> 734 <property name="sizePolicy"> 735 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 736 <horstretch>0</horstretch> 737 <verstretch>0</verstretch> 738 </sizepolicy> 739 </property> 740 <property name="autoFillBackground"> 741 <bool>true</bool> 742 </property> 743 <property name="text"> 744 <string/> 745 </property> 746 <property name="pixmap"> 747 <pixmap resource="../VirtualBox1.qrc">:/vmw_new_welcome.png</pixmap> 748 </property> 749 <property name="alignment"> 750 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 751 </property> 752 </widget> 753 </item> 754 <item> 755 <layout class="QVBoxLayout"> 756 <property name="spacing"> 757 <number>10</number> 758 </property> 759 <item> 760 <widget class="QILabel" name="mTextVDI"> 761 <property name="sizePolicy"> 762 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 763 <horstretch>0</horstretch> 764 <verstretch>0</verstretch> 765 </sizepolicy> 766 </property> 767 <property name="minimumSize"> 768 <size> 769 <width>300</width> 770 <height>0</height> 771 </size> 772 </property> 773 <property name="text"> 774 <string><p>Select a hard disk image to be used as the boot hard disk of the virtual machine. You can either create a new hard disk using the <b>New</b> button or select an existing hard disk image from the drop-down list or by pressing the <b>Existing</b> button (to invoke the Virtual Media Manager dialog).</p><p>If you need a more complicated hard disk setup, you can also skip this step and attach hard disks later using the VM Settings dialog.</p></string> 775 </property> 776 <property name="wordWrap"> 777 <bool>true</bool> 778 </property> 779 </widget> 780 </item> 781 <item> 782 <widget class="QILabel" name="mTextVDIBest"> 783 <property name="sizePolicy"> 784 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 785 <horstretch>0</horstretch> 786 <verstretch>0</verstretch> 787 </sizepolicy> 788 </property> 789 <property name="minimumSize"> 790 <size> 791 <width>300</width> 792 <height>0</height> 793 </size> 794 </property> 795 <property name="text"> 796 <string/> 797 </property> 798 <property name="wordWrap"> 799 <bool>true</bool> 800 </property> 801 </widget> 802 </item> 803 <item> 804 <widget class="QGroupBox" name="mGbHDA"> 805 <property name="sizePolicy"> 806 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 807 <horstretch>0</horstretch> 808 <verstretch>0</verstretch> 809 </sizepolicy> 810 </property> 811 <property name="title"> 812 <string>Boot Hard &Disk (Primary Master)</string> 813 </property> 814 <property name="checkable"> 815 <bool>true</bool> 816 </property> 817 <layout class="QGridLayout"> 818 <item row="0" column="0" colspan="3"> 819 <widget class="QRadioButton" name="mNewVDIRadio"> 820 <property name="text"> 821 <string>&Create new hard disk</string> 822 </property> 823 <property name="checked"> 824 <bool>true</bool> 825 </property> 826 </widget> 827 </item> 828 <item row="1" column="0" colspan="3"> 829 <widget class="QRadioButton" name="mExistRadio"> 830 <property name="text"> 831 <string>&Use existing hard disk</string> 832 </property> 833 </widget> 834 </item> 835 <item row="2" column="1"> 836 <widget class="VBoxMediaComboBox" name="mHDCombo"> 837 <property name="sizePolicy"> 838 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 839 <horstretch>0</horstretch> 840 <verstretch>0</verstretch> 841 </sizepolicy> 842 </property> 843 </widget> 844 </item> 845 <item row="2" column="2"> 846 <widget class="QToolButton" name="mTbVmm"> 847 <property name="autoRaise"> 848 <bool>true</bool> 849 </property> 850 </widget> 851 </item> 852 </layout> 853 </widget> 854 </item> 855 <item> 856 <spacer> 857 <property name="orientation"> 858 <enum>Qt::Vertical</enum> 859 </property> 860 <property name="sizeHint" stdset="0"> 861 <size> 862 <width>0</width> 863 <height>0</height> 864 </size> 865 </property> 866 </spacer> 867 </item> 868 </layout> 869 </item> 870 </layout> 871 </item> 872 <item> 873 <widget class="Line" name="line42"> 874 <property name="orientation"> 875 <enum>Qt::Horizontal</enum> 876 </property> 877 </widget> 878 </item> 879 <item> 880 <layout class="QHBoxLayout"> 881 <item> 882 <spacer> 883 <property name="orientation"> 884 <enum>Qt::Horizontal</enum> 885 </property> 886 <property name="sizeHint" stdset="0"> 887 <size> 888 <width>0</width> 889 <height>0</height> 890 </size> 891 </property> 892 </spacer> 893 </item> 894 <item> 895 <widget class="QPushButton" name="mBtnBack4"> 896 <property name="text"> 897 <string>< &Back</string> 898 </property> 899 </widget> 900 </item> 901 <item> 902 <widget class="QPushButton" name="mBtnNext4"> 903 <property name="text"> 904 <string>&Next ></string> 905 </property> 906 </widget> 907 </item> 908 <item> 909 <spacer> 910 <property name="orientation"> 911 <enum>Qt::Horizontal</enum> 912 </property> 913 <property name="sizeType"> 914 <enum>QSizePolicy::Fixed</enum> 915 </property> 916 <property name="sizeHint" stdset="0"> 917 <size> 918 <width>5</width> 919 <height>0</height> 920 </size> 921 </property> 922 </spacer> 923 </item> 924 <item> 925 <widget class="QPushButton" name="mBtnCancel4"> 926 <property name="text"> 927 <string>Cancel</string> 928 </property> 929 </widget> 930 </item> 931 </layout> 932 </item> 933 </layout> 934 </widget> 935 <widget class="QWidget" name="mPageSummary"> 936 <layout class="QVBoxLayout"> 937 <item> 938 <widget class="QLabel" name="mPageSummaryHdr"> 939 <property name="font"> 940 <font> 941 <family>Arial</family> 942 <pointsize>12</pointsize> 943 <weight>75</weight> 944 <bold>true</bold> 945 </font> 946 </property> 947 <property name="text"> 948 <string>Summary</string> 949 </property> 950 </widget> 951 </item> 952 <item> 953 <widget class="Line" name="line51"> 954 <property name="orientation"> 955 <enum>Qt::Horizontal</enum> 956 </property> 957 </widget> 958 </item> 959 <item> 960 <layout class="QHBoxLayout"> 961 <property name="spacing"> 962 <number>10</number> 963 </property> 964 <item> 965 <widget class="QLabel" name="mLogoSummary"> 966 <property name="sizePolicy"> 967 <sizepolicy hsizetype="Maximum" vsizetype="Minimum"> 968 <horstretch>0</horstretch> 969 <verstretch>0</verstretch> 970 </sizepolicy> 971 </property> 972 <property name="autoFillBackground"> 973 <bool>true</bool> 974 </property> 975 <property name="text"> 976 <string/> 977 </property> 978 <property name="pixmap"> 979 <pixmap resource="../VirtualBox1.qrc">:/vmw_new_welcome.png</pixmap> 980 </property> 981 <property name="alignment"> 982 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 983 </property> 984 </widget> 985 </item> 986 <item> 987 <layout class="QVBoxLayout"> 988 <property name="spacing"> 989 <number>10</number> 990 </property> 991 <item> 992 <widget class="QILabel" name="mTextSummaryHdr"> 993 <property name="sizePolicy"> 994 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 995 <horstretch>0</horstretch> 996 <verstretch>0</verstretch> 997 </sizepolicy> 998 </property> 999 <property name="minimumSize"> 1000 <size> 1001 <width>300</width> 1002 <height>0</height> 1003 </size> 1004 </property> 1005 <property name="text"> 1006 <string><p>You are going to create a new virtual machine with the following parameters:</p></string> 1007 </property> 1008 <property name="wordWrap"> 1009 <bool>true</bool> 1010 </property> 1011 </widget> 1012 </item> 1013 <item> 1014 <widget class="QITextEdit" name="mTeSummary"> 1015 <property name="sizePolicy"> 1016 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 1017 <horstretch>0</horstretch> 1018 <verstretch>0</verstretch> 1019 </sizepolicy> 1020 </property> 1021 <property name="minimumSize"> 1022 <size> 1023 <width>300</width> 1024 <height>0</height> 1025 </size> 1026 </property> 1027 <property name="frameShape"> 1028 <enum>QFrame::NoFrame</enum> 1029 </property> 1030 <property name="autoFormatting"> 1031 <set>QTextEdit::AutoAll</set> 1032 </property> 1033 <property name="readOnly"> 1034 <bool>true</bool> 1035 </property> 1036 </widget> 1037 </item> 1038 <item> 1039 <widget class="QILabel" name="mTextSummaryFtr"> 1040 <property name="sizePolicy"> 1041 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 1042 <horstretch>0</horstretch> 1043 <verstretch>0</verstretch> 1044 </sizepolicy> 1045 </property> 1046 <property name="minimumSize"> 1047 <size> 1048 <width>300</width> 1049 <height>0</height> 1050 </size> 1051 </property> 1052 <property name="text"> 1053 <string><p>If the above is correct press the <b>Finish</b> button. Once you press it, a new virtual machine will be created. </p><p>Note that you can alter these and all other setting of the created virtual machine at any time using the <b>Settings</b> dialog accessible through the menu of the main window.</p></string> 1054 </property> 1055 <property name="wordWrap"> 1056 <bool>true</bool> 1057 </property> 1058 </widget> 1059 </item> 1060 <item> 1061 <spacer> 1062 <property name="orientation"> 1063 <enum>Qt::Vertical</enum> 1064 </property> 1065 <property name="sizeType"> 1066 <enum>QSizePolicy::Expanding</enum> 1067 </property> 1068 <property name="sizeHint" stdset="0"> 1069 <size> 1070 <width>0</width> 1071 <height>0</height> 1072 </size> 1073 </property> 1074 </spacer> 1075 </item> 1076 </layout> 1077 </item> 1078 </layout> 1079 </item> 1080 <item> 1081 <widget class="Line" name="line52"> 1082 <property name="orientation"> 1083 <enum>Qt::Horizontal</enum> 1084 </property> 1085 </widget> 1086 </item> 1087 <item> 1088 <layout class="QHBoxLayout"> 1089 <item> 1090 <spacer> 1091 <property name="orientation"> 1092 <enum>Qt::Horizontal</enum> 1093 </property> 1094 <property name="sizeHint" stdset="0"> 1095 <size> 1096 <width>0</width> 1097 <height>0</height> 1098 </size> 1099 </property> 1100 </spacer> 1101 </item> 1102 <item> 1103 <widget class="QPushButton" name="mBtnBack5"> 1104 <property name="text"> 1105 <string>< &Back</string> 1106 </property> 1107 </widget> 1108 </item> 1109 <item> 1110 <widget class="QPushButton" name="mBtnFinish"> 1111 <property name="text"> 1112 <string>&Finish</string> 1113 </property> 1114 </widget> 1115 </item> 1116 <item> 1117 <spacer> 1118 <property name="orientation"> 1119 <enum>Qt::Horizontal</enum> 1120 </property> 1121 <property name="sizeType"> 1122 <enum>QSizePolicy::Fixed</enum> 1123 </property> 1124 <property name="sizeHint" stdset="0"> 1125 <size> 1126 <width>5</width> 1127 <height>0</height> 1128 </size> 1129 </property> 1130 </spacer> 1131 </item> 1132 <item> 1133 <widget class="QPushButton" name="mBtnCancel5"> 1134 <property name="text"> 1135 <string>Cancel</string> 1136 </property> 1137 </widget> 1138 </item> 1139 </layout> 1140 </item> 1141 </layout> 1142 </widget> 51 <property name="wordWrap"> 52 <bool>true</bool> 53 </property> 1143 54 </widget> 55 </item> 56 <item> 57 <widget class="QTextEdit" name="m_pSummaryText"> 58 <property name="sizePolicy"> 59 <sizepolicy hsizetype="Expanding" vsizetype="Fixed"> 60 <horstretch>0</horstretch> 61 <verstretch>0</verstretch> 62 </sizepolicy> 63 </property> 64 <property name="frameShape"> 65 <enum>QFrame::NoFrame</enum> 66 </property> 67 <property name="readOnly"> 68 <bool>true</bool> 69 </property> 70 </widget> 71 </item> 72 <item> 73 <widget class="QILabel" name="m_pPage5Text2"> 74 <property name="text"> 75 <string><p>If the above is correct press the <b>Finish</b> button. Once you press it, a new virtual machine will be created. </p><p>Note that you can alter these and all other setting of the created virtual machine at any time using the <b>Settings</b> dialog accessible through the menu of the main window.</p></string> 76 </property> 77 <property name="wordWrap"> 78 <bool>true</bool> 79 </property> 80 </widget> 81 </item> 82 <item> 83 <spacer name="m_pSpacer1"> 84 <property name="sizeHint" stdset="0"> 85 <size> 86 <width>0</width> 87 <height>0</height> 88 </size> 89 </property> 90 </spacer> 1144 91 </item> 1145 92 </layout> … … 1151 98 <header>QILabel.h</header> 1152 99 </customwidget> 1153 <customwidget>1154 <class>VBoxOSTypeSelectorWidget</class>1155 <extends>QWidget</extends>1156 <header>VBoxOSTypeSelectorWidget.h</header>1157 </customwidget>1158 <customwidget>1159 <class>VBoxMediaComboBox</class>1160 <extends>QComboBox</extends>1161 <header>VBoxMediaComboBox.h</header>1162 </customwidget>1163 <customwidget>1164 <class>QITextEdit</class>1165 <extends>QTextEdit</extends>1166 <header>QIAbstractWizard.h</header>1167 </customwidget>1168 <customwidget>1169 <class>QILineEdit</class>1170 <extends>QLineEdit</extends>1171 <header>QILineEdit.h</header>1172 </customwidget>1173 <customwidget>1174 <class>QIAdvancedSlider</class>1175 <extends>QSlider</extends>1176 <header>QIAdvancedSlider.h</header>1177 </customwidget>1178 <customwidget>1179 <class>VBoxGuestRAMSlider</class>1180 <extends>QIAdvancedSlider</extends>1181 <header>VBoxGuestRAMSlider.h</header>1182 </customwidget>1183 100 </customwidgets> 1184 <tabstops> 1185 <tabstop>mBtnNext1</tabstop> 1186 <tabstop>mBtnCancel1</tabstop> 1187 <tabstop>mLeName</tabstop> 1188 <tabstop>mOSTypeSelector</tabstop> 1189 <tabstop>mBtnBack2</tabstop> 1190 <tabstop>mBtnNext2</tabstop> 1191 <tabstop>mBtnCancel2</tabstop> 1192 <tabstop>mSlRAM</tabstop> 1193 <tabstop>mLeRAM</tabstop> 1194 <tabstop>mBtnBack3</tabstop> 1195 <tabstop>mBtnNext3</tabstop> 1196 <tabstop>mBtnCancel3</tabstop> 1197 <tabstop>mNewVDIRadio</tabstop> 1198 <tabstop>mExistRadio</tabstop> 1199 <tabstop>mHDCombo</tabstop> 1200 <tabstop>mTbVmm</tabstop> 1201 <tabstop>mBtnBack4</tabstop> 1202 <tabstop>mBtnNext4</tabstop> 1203 <tabstop>mBtnCancel4</tabstop> 1204 <tabstop>mBtnBack5</tabstop> 1205 <tabstop>mBtnFinish</tabstop> 1206 <tabstop>mBtnCancel5</tabstop> 1207 </tabstops> 1208 <resources> 1209 <include location="../VirtualBox1.qrc"/> 1210 </resources> 101 <resources/> 1211 102 <connections/> 1212 103 </ui> -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/registration/UIRegistrationWzd.cpp
r25432 r26079 2 2 * 3 3 * VBox frontends: Qt4 GUI ("VirtualBox"): 4 * VBoxRegistrationDlgclass implementation4 * UIRegistrationWzd class implementation 5 5 */ 6 6 7 7 /* 8 * Copyright (C) 200 6-2008Sun Microsystems, Inc.8 * Copyright (C) 2008-2010 Sun Microsystems, Inc. 9 9 * 10 10 * This file is part of VirtualBox Open Source Edition (OSE), as … … 21 21 */ 22 22 23 #include "QIHttp.h" 23 /* Global includes */ 24 #include <QTimer> 25 #include <QUrl> 26 27 /* Local includes */ 28 #include "UIRegistrationWzd.h" 24 29 #include "VBoxGlobal.h" 25 30 #include "VBoxProblemReporter.h" 26 #include "VBoxRegistrationDlg.h" 27 28 /* Qt includes */ 29 #include <QTimer> 31 #include "QIHttp.h" 30 32 31 33 /** 32 34 * This class is used to encode/decode the registration data. 33 35 */ 34 class VBoxRegistrationData36 class RegistrationData 35 37 { 36 38 public: 37 39 38 VBoxRegistrationData (const QString &aString, bool aEncode) 39 : mIsValid (aEncode), mIsRegistered (aEncode) 40 , mTriesLeft (3 /* the initial tries value */) 41 { 42 aEncode ? encode (aString) : decode (aString); 43 } 44 45 bool isValid() const { return mIsValid; } 46 bool isRegistered() const { return mIsRegistered; } 47 48 const QString &data() const { return mData; } 49 const QString &account() const { return mAccount; } 50 51 uint triesLeft() const { return mTriesLeft; } 40 RegistrationData(const QString &strData, bool bEncode) 41 : m_bValid(bEncode) 42 , m_bRegistered(bEncode) 43 , m_cTriesLeft(3 /* the initial tries value */) 44 { 45 bEncode ? encode(strData) : decode(strData); 46 } 47 48 bool isValid() const { return m_bValid; } 49 bool isRegistered() const { return m_bRegistered; } 50 51 const QString &data() const { return m_strData; } 52 const QString &account() const { return m_strAccount; } 53 54 uint triesLeft() const { return m_cTriesLeft; } 52 55 53 56 private: 54 57 55 void decode (const QString &aData)56 { 57 if ( aData.isEmpty())58 void decode(const QString &strData) 59 { 60 if (strData.isEmpty()) 58 61 return; 59 62 60 m Data = aData;63 m_strData = strData; 61 64 62 65 /* Decoding number of left tries */ 63 if (m Data.startsWith("triesLeft="))66 if (m_strData.startsWith("triesLeft=")) 64 67 { 65 68 bool ok = false; 66 uint triesLeft = mData.section ('=', 1, 1).toUInt(&ok);69 uint cTriesLeft = m_strData.section('=', 1, 1).toUInt(&ok); 67 70 if (!ok) 68 71 return; 69 m TriesLeft = triesLeft;70 m IsValid = true;72 m_cTriesLeft = cTriesLeft; 73 m_bValid = true; 71 74 return; 72 75 } 73 76 74 77 /* Decoding CRC32 */ 75 QString data = mData;76 QString crcData = data.right (2 * sizeof(ulong));77 ulong crcNeed = 0;78 for (long i = 0; i < crcData.length(); i += 2)78 QString strDataCopy = m_strData; 79 QString strCrcData = strDataCopy.right(2 * sizeof(ulong)); 80 ulong uCrcNeed = 0; 81 for (long i = 0; i < strCrcData.length(); i += 2) 79 82 { 80 crcNeed <<= 8;81 uchar curByte = (uchar) crcData.mid (i, 2).toUShort(0, 16);82 crcNeed += curByte;83 uCrcNeed <<= 8; 84 uchar uCurByte = (uchar)strCrcData.mid(i, 2).toUShort(0, 16); 85 uCrcNeed += uCurByte; 83 86 } 84 data.truncate (data.length() - 2 * sizeof(ulong));87 strDataCopy.truncate(strDataCopy.length() - 2 * sizeof(ulong)); 85 88 86 89 /* Decoding data */ 87 QString result;88 for (long i = 0; i < data.length(); i += 4)89 result += QChar (data.mid (i, 4).toUShort(0, 16));90 ulong crcNow = crc32 ((uchar*)result.toAscii().constData(), result.length());90 QString strResult; 91 for (long i = 0; i < strDataCopy.length(); i += 4) 92 strResult += QChar(strDataCopy.mid(i, 4).toUShort(0, 16)); 93 ulong uCrcNow = crc32((uchar*)strResult.toAscii().constData(), strResult.length()); 91 94 92 95 /* Check the CRC32 */ 93 if ( crcNeed != crcNow)96 if (uCrcNeed != uCrcNow) 94 97 return; 95 98 96 99 /* Split values list */ 97 QStringList list (result.split ("|"));100 QStringList list(strResult.split('|')); 98 101 99 102 /* Ignore the old format */ … … 102 105 103 106 /* Result value */ 104 m IsValid = true;105 m IsRegistered = true;106 m Account = list[0];107 } 108 109 void encode (const QString &aAccount)110 { 111 if ( aAccount.isEmpty())107 m_bValid = true; 108 m_bRegistered = true; 109 m_strAccount = list[0]; 110 } 111 112 void encode(const QString &strAccount) 113 { 114 if (strAccount.isEmpty()) 112 115 return; 113 116 114 m Account = aAccount;117 m_strAccount = strAccount; 115 118 116 119 /* Encoding data */ 117 QString data = QString ("%1").arg (mAccount);118 m Data = QString::null;119 for (long i = 0; i < data.length(); ++ i)120 QString strData = m_strAccount; 121 m_strData = QString::null; 122 for (long i = 0; i < strData.length(); ++ i) 120 123 { 121 QString curPair = QString::number (data.at(i).unicode(), 16);122 while ( curPair.length() < 4)123 curPair.prepend('0');124 m Data += curPair;124 QString strCurPair = QString::number(strData.at(i).unicode(), 16); 125 while (strCurPair.length() < 4) 126 strCurPair.prepend('0'); 127 m_strData += strCurPair; 125 128 } 126 129 127 130 /* Enconding CRC32 */ 128 ulong crcNow = crc32 ((uchar*)data.toAscii().constData(), data.length());129 QString crcData;130 for (ulong i = 0; i < sizeof 131 ulong uCrcNow = crc32((uchar*)strData.toAscii().constData(), strData.length()); 132 QString strCrcData; 133 for (ulong i = 0; i < sizeof(ulong); ++ i) 131 134 { 132 ushort curByte = crcNow & 0xFF;133 QString curPair = QString::number (curByte, 16);134 if ( curPair.length() == 1)135 curPair.prepend ("0");136 crcData = curPair + crcData;137 crcNow >>= 8;135 ushort uCurByte = uCrcNow & 0xFF; 136 QString strCurPair = QString::number(uCurByte, 16); 137 if (strCurPair.length() == 1) 138 strCurPair.prepend('0'); 139 strCrcData = strCurPair + strCrcData; 140 uCrcNow >>= 8; 138 141 } 139 142 140 m Data += crcData;141 } 142 143 ulong crc32 (unsigned char *aBufer, int aSize)143 m_strData += strCrcData; 144 } 145 146 ulong crc32(unsigned char *strBufer, int iSize) 144 147 { 145 148 /* Filling CRC32 table */ 146 ulong crc32;147 ulong crc_table[256];148 ulong temp;149 ulong uCrc32; 150 ulong aCrcTable[256]; 151 ulong uTemp; 149 152 for (int i = 0; i < 256; ++ i) 150 153 { 151 temp = i;154 uTemp = i; 152 155 for (int j = 8; j > 0; -- j) 153 156 { 154 if ( temp & 1)155 temp = (temp >> 1) ^ 0xedb88320;157 if (uTemp & 1) 158 uTemp = (uTemp >> 1) ^ 0xedb88320; 156 159 else 157 temp >>= 1;160 uTemp >>= 1; 158 161 }; 159 crc_table [i] = temp;162 aCrcTable[i] = uTemp; 160 163 } 161 164 162 165 /* CRC32 calculation */ 163 crc32 = 0xffffffff;164 for (int i = 0; i < aSize; ++ i)166 uCrc32 = 0xffffffff; 167 for (int i = 0; i < iSize; ++ i) 165 168 { 166 crc32 = crc_table [(crc32 ^ (*aBufer ++)) & 0xff] ^ (crc32 >> 8);169 uCrc32 = aCrcTable[(uCrc32 ^ (*strBufer ++)) & 0xff] ^ (uCrc32 >> 8); 167 170 } 168 crc32 = crc32 ^ 0xffffffff;169 return crc32;171 uCrc32 = uCrc32 ^ 0xffffffff; 172 return uCrc32; 170 173 }; 171 174 172 bool m IsValid : 1;173 bool m IsRegistered : 1;174 175 uint m TriesLeft;176 177 QString m Account;178 QString m Data;175 bool m_bValid : 1; 176 bool m_bRegistered : 1; 177 178 uint m_cTriesLeft; 179 180 QString m_strAccount; 181 QString m_strData; 179 182 }; 180 183 181 /* Static member to check if registration dialog necessary. */ 182 bool VBoxRegistrationDlg::hasToBeShown() 183 { 184 VBoxRegistrationData data (vboxGlobal().virtualBox(). 185 GetExtraData (VBoxDefs::GUI_RegistrationData), false); 186 187 return (!data.isValid()) || 188 (!data.isRegistered() && data.triesLeft() > 0); 189 } 190 191 VBoxRegistrationDlg::VBoxRegistrationDlg (VBoxRegistrationDlg **aSelf, QWidget * /* aParent */) 192 : QIWithRetranslateUI <QIAbstractWizard> (0) 193 , mSelf (aSelf) 194 , mWvalReg (0) 195 , mUrl ("http://registration.virtualbox.org/register763.php") 196 , mHttp (new QIHttp (this, mUrl.host())) 184 /** 185 * This class is used to perform the registration actions. 186 */ 187 class RegistrationEngine : public QEventLoop 188 { 189 Q_OBJECT; 190 191 public: 192 193 RegistrationEngine(QWidget *pParent) : QEventLoop(pParent) 194 { 195 /* Registration address */ 196 m_Url = QUrl("http://registration.virtualbox.org/register763.php"); 197 198 /* HTTP Engine */ 199 m_pHttp = new QIHttp(this, m_Url.host()); 200 201 /* Initial values */ 202 m_bPresent = false; 203 m_bResult = false; 204 } 205 206 void setOldData(const QString &strVersion, const QString &strPlatform, 207 const QString &strOldEmail, const QString &strOldPassword) 208 { 209 /* Case for present account */ 210 resetFields(); 211 m_bPresent = true; 212 m_strVersion = strVersion; 213 m_strPlatform = strPlatform; 214 m_strOldEmail = strOldEmail; 215 m_strOldPassword = strOldPassword; 216 } 217 218 void setNewData(const QString &strVersion, const QString &strPlatform, 219 const QString &strNewEmail, const QString &strNewPassword, 220 const QString &strNewFirstName, const QString &strNewLastName, 221 const QString &strNewCompany, const QString &strNewCountry) 222 { 223 /* Case for account creation */ 224 resetFields(); 225 m_bPresent = false; 226 m_strVersion = strVersion; 227 m_strPlatform = strPlatform; 228 m_strNewEmail = strNewEmail; 229 m_strNewPassword = strNewPassword; 230 m_strNewFirstName = strNewFirstName; 231 m_strNewLastName = strNewLastName; 232 m_strNewCompany = strNewCompany; 233 m_strNewCountry = strNewCountry; 234 } 235 236 int start() 237 { 238 /* Request handshake */ 239 QTimer::singleShot(0, this, SLOT(sltHandshakeStart())); 240 return QEventLoop::exec(QEventLoop::AllEvents); 241 } 242 243 bool result() const 244 { 245 return m_bResult; 246 } 247 248 private slots: 249 250 void sltHandshakeStart() 251 { 252 /* Compose query */ 253 QUrl url(m_Url); 254 url.addQueryItem("version", m_strVersion); 255 256 /* Handshake */ 257 connect(m_pHttp, SIGNAL(allIsDone(bool)), this, SLOT(sltHandshakeResponse(bool))); 258 m_pHttp->post(url.toEncoded()); 259 } 260 261 void sltHandshakeResponse(bool bError) 262 { 263 /* Block all the other incoming signals */ 264 m_pHttp->disconnect(this); 265 266 /* Process error if present */ 267 if (bError) 268 return abortRequest(m_pHttp->errorString()); 269 270 /* Read received key */ 271 m_strKey = m_pHttp->readAll(); 272 273 /* Verifying key correctness */ 274 if (QString(m_strKey).indexOf(QRegExp("^[a-zA-Z0-9]{32}$"))) 275 return abortRequest(tr("Could not perform connection handshake.")); 276 277 /* Request registration */ 278 QTimer::singleShot(0, this, SLOT(sltRegistrationStart())); 279 } 280 281 void sltRegistrationStart() 282 { 283 /* Compose query */ 284 QUrl url(m_Url); 285 286 /* Basic set */ 287 url.addQueryItem("version", m_strVersion); 288 url.addQueryItem("key", m_strKey); 289 url.addQueryItem("platform", m_strPlatform); 290 291 if (m_bPresent) 292 { 293 /* Set for present account */ 294 url.addQueryItem("email", m_strOldEmail); 295 url.addQueryItem("password", m_strOldPassword); 296 } 297 else 298 { 299 /* Set for account creation */ 300 url.addQueryItem("email", m_strNewEmail); 301 url.addQueryItem("password", m_strNewPassword); 302 url.addQueryItem("firstname", m_strNewFirstName); 303 url.addQueryItem("lastname", m_strNewLastName); 304 url.addQueryItem("company", m_strNewCompany); 305 url.addQueryItem("country", m_strNewCountry); 306 } 307 308 /* Registration */ 309 connect(m_pHttp, SIGNAL(allIsDone(bool)), this, SLOT(sltRegistrationResponse(bool))); 310 m_pHttp->post(url.toEncoded()); 311 } 312 313 void sltRegistrationResponse(bool bError) 314 { 315 /* Block all the other incoming signals */ 316 m_pHttp->disconnect(this); 317 318 /* Process error if present */ 319 if (bError) 320 return abortRequest(m_pHttp->errorString()); 321 322 /* Read received result */ 323 m_strData = m_pHttp->readAll(); 324 325 /* Show registration result */ 326 vboxProblem().showRegisterResult(qobject_cast<QWidget*>(parent()), m_strData); 327 328 /* Set result */ 329 m_bResult = m_strData == "OK"; 330 331 /* Allows all the queued events to be processed before leaving loop */ 332 QTimer::singleShot(0, this, SLOT(quit())); 333 } 334 335 private: 336 337 void resetFields() 338 { 339 m_bResult = false; 340 m_bPresent = false; 341 m_strVersion = QString(); 342 m_strKey = QString(); 343 m_strPlatform = QString(); 344 m_strOldEmail = QString(); 345 m_strOldPassword = QString(); 346 m_strNewEmail = QString(); 347 m_strNewPassword = QString(); 348 m_strNewFirstName = QString(); 349 m_strNewLastName = QString(); 350 m_strNewCompany = QString(); 351 m_strNewCountry = QString(); 352 m_strData = QString(); 353 } 354 355 void abortRequest(const QString &strReason) 356 { 357 /* Show reason if present */ 358 if (!strReason.isNull()) 359 vboxProblem().cannotConnectRegister(qobject_cast<QWidget*>(parent()), m_Url.toString(), strReason); 360 361 /* Result = FAILED */ 362 m_bResult = false; 363 364 /* Allows all the queued events to be processed before leaving loop */ 365 QTimer::singleShot(0, this, SLOT(quit())); 366 } 367 368 QUrl m_Url; 369 QIHttp *m_pHttp; 370 371 bool m_bResult; 372 bool m_bPresent; 373 374 QString m_strVersion; 375 QString m_strKey; 376 QString m_strPlatform; 377 QString m_strOldEmail; 378 QString m_strOldPassword; 379 QString m_strNewEmail; 380 QString m_strNewPassword; 381 QString m_strNewFirstName; 382 QString m_strNewLastName; 383 QString m_strNewCompany; 384 QString m_strNewCountry; 385 QString m_strData; 386 }; 387 388 /* Check if registration dialog necessary */ 389 bool UIRegistrationWzd::hasToBeShown() 390 { 391 RegistrationData data(vboxGlobal().virtualBox().GetExtraData(VBoxDefs::GUI_RegistrationData), false); 392 return (!data.isValid()) || (!data.isRegistered() && data.triesLeft() > 0); 393 } 394 395 UIRegistrationWzd::UIRegistrationWzd(UIRegistrationWzd **ppSelf) 396 : QIWizard(0) 397 , m_ppThis(ppSelf) 197 398 { 198 399 /* Store external pointer to this dialog */ 199 *mSelf = this; 200 201 /* Apply UI decorations */ 202 Ui::VBoxRegistrationDlg::setupUi (this); 400 *m_ppThis = this; 203 401 204 402 /* Apply window icons */ 205 setWindowIcon (vboxGlobal().iconSetFull (QSize (32, 32), QSize (16, 16), 206 ":/register_32px.png", ":/register_16px.png")); 207 208 /* Setup widgets */ 209 QSizePolicy sp (mTextRegInfo->sizePolicy()); 210 sp.setHeightForWidth (true); 211 mTextRegInfo->setSizePolicy (sp); 212 213 /* Initialize wizard hdr */ 214 initializeWizardHdr(); 215 216 /* Setup validations for line-edit fields */ 403 setWindowIcon(vboxGlobal().iconSetFull(QSize(32, 32), QSize(16, 16), 404 ":/register_32px.png", ":/register_16px.png")); 405 406 /* Create & add page */ 407 addPage(new UIRegistrationWzdPage1); 408 409 /* Translate */ 410 retranslateUi(); 411 412 /* Resize to 'golden ratio' */ 413 resizeToGoldenRatio(); 414 415 /* Assign watermark */ 416 assignWatermark(":/vmw_new_user.png"); 417 418 /* Setup connections */ 419 connect(vboxGlobal().mainWindow(), SIGNAL(closing()), this, SLOT(reject())); 420 } 421 422 UIRegistrationWzd::~UIRegistrationWzd() 423 { 424 /* Erase dialog handle in config file */ 425 vboxGlobal().virtualBox().SetExtraData(VBoxDefs::GUI_RegistrationDlgWinID, QString::null); 426 427 /* Erase external pointer to this dialog */ 428 *m_ppThis = 0; 429 } 430 431 void UIRegistrationWzd::retranslateUi() 432 { 433 /* Wizard title */ 434 setWindowTitle(tr("VirtualBox Registration Dialog")); 435 } 436 437 void UIRegistrationWzd::reject() 438 { 439 /* Decrement the triesLeft */ 440 RegistrationData data(vboxGlobal().virtualBox().GetExtraData(VBoxDefs::GUI_RegistrationData), false); 441 if (!data.isValid() || !data.isRegistered()) 442 { 443 uint cTriesLeft = data.triesLeft(); 444 if (cTriesLeft) 445 { 446 -- cTriesLeft; 447 vboxGlobal().virtualBox().SetExtraData(VBoxDefs::GUI_RegistrationData, QString("triesLeft=%1").arg(cTriesLeft)); 448 } 449 } 450 /* And close the dialog */ 451 QWizard::reject(); 452 } 453 454 UIRegistrationWzdPage1::UIRegistrationWzdPage1() 455 { 456 /* Decorate page */ 457 Ui::UIRegistrationWzdPage1::setupUi(this); 458 459 /* Setup fields validations */ 217 460 QRegExp nameExp ("[\\S\\s]+"); 218 461 /* E-mail address is validated according to RFC2821, RFC2822, … … 229 472 QRegExp passwordExp ("[a-zA-Z0-9_\\-\\+=`~!@#$%^&\\*\\(\\)?\\[\\]:;,\\./]+"); 230 473 231 m LeOldEmail->setMaxLength(50);474 m_pLeOldEmail->setMaxLength(50); 232 475 /* New accounts *must* have a valid email as user name. Thats not the case 233 476 * for old existing accounts. So we don't force the email format, so that 234 477 * old accounts could be used for registration also. */ 235 mLeOldEmail->setValidator (new QRegExpValidator (nameExp, this)); 236 237 mLeOldPassword->setMaxLength (20); 238 mLeOldPassword->setValidator (new QRegExpValidator (passwordExp, this)); 239 240 mLeNewFirstName->setMaxLength (50); 241 mLeNewFirstName->setValidator (new QRegExpValidator (nameExp, this)); 242 243 mLeNewLastName->setMaxLength (50); 244 mLeNewLastName->setValidator (new QRegExpValidator (nameExp, this)); 245 246 mLeNewCompany->setMaxLength (50); 247 mLeNewCompany->setValidator (new QRegExpValidator (nameExp, this)); 248 249 mLeNewEmail->setMaxLength (50); 250 mLeNewEmail->setValidator (new QRegExpValidator (emailExp, this)); 251 252 mLeNewPassword->setMaxLength (20); 253 mLeNewPassword->setValidator (new QRegExpValidator (passwordExp, this)); 254 255 mLeNewPassword2->setMaxLength (20); 256 mLeNewPassword2->setValidator (new QRegExpValidator (passwordExp, this)); 257 478 m_pLeOldEmail->setValidator(new QRegExpValidator(nameExp, this)); 479 480 m_pLeOldPassword->setMaxLength(20); 481 m_pLeOldPassword->setValidator(new QRegExpValidator(passwordExp, this)); 482 483 m_pLeNewFirstName->setMaxLength(50); 484 m_pLeNewFirstName->setValidator(new QRegExpValidator (nameExp, this)); 485 486 m_pLeNewLastName->setMaxLength(50); 487 m_pLeNewLastName->setValidator(new QRegExpValidator(nameExp, this)); 488 489 m_pLeNewCompany->setMaxLength(50); 490 m_pLeNewCompany->setValidator(new QRegExpValidator(nameExp, this)); 491 492 m_pLeNewEmail->setMaxLength(50); 493 m_pLeNewEmail->setValidator(new QRegExpValidator(emailExp, this)); 494 495 m_pLeNewPassword->setMaxLength(20); 496 m_pLeNewPassword->setValidator(new QRegExpValidator(passwordExp, this)); 497 498 m_pLeNewConfirmPassword->setMaxLength(20); 499 m_pLeNewConfirmPassword->setValidator(new QRegExpValidator(passwordExp, this)); 500 501 /* Populate countries list */ 258 502 populateCountries(); 259 503 260 /* Setup validation */ 261 mWvalReg = new QIWidgetValidator (mPageReg, this); 262 connect (mWvalReg, SIGNAL (validityChanged (const QIWidgetValidator *)), 263 this, SLOT (enableNext (const QIWidgetValidator *))); 264 connect (mWvalReg, SIGNAL (isValidRequested (QIWidgetValidator *)), 265 this, SLOT (revalidate (QIWidgetValidator *))); 266 267 connect (mRbOld, SIGNAL (toggled (bool)), this, SLOT (radioButtonToggled())); 268 connect (mRbNew, SIGNAL (toggled (bool)), this, SLOT (radioButtonToggled())); 269 connect (mCbNewCountry, SIGNAL (currentIndexChanged (int)), mWvalReg, SLOT (revalidate())); 270 271 /* Setup other connections */ 272 connect (vboxGlobal().mainWindow(), SIGNAL (closing()), this, SLOT (reject())); 273 274 /* Setup initial dialog parameters. */ 275 VBoxRegistrationData data (vboxGlobal().virtualBox(). 276 GetExtraData (VBoxDefs::GUI_RegistrationData), false); 277 mLeOldEmail->setText (data.account()); 278 279 radioButtonToggled(); 280 281 /* Initialize wizard hdr */ 282 initializeWizardFtr(); 283 504 /* Setup connections */ 505 connect(m_pRbPresent, SIGNAL(toggled(bool)), this, SLOT(sltAccountTypeChanged())); 506 connect(m_pRbCreate, SIGNAL(toggled(bool)), this, SLOT(sltAccountTypeChanged())); 507 connect(m_pLeOldEmail, SIGNAL(textEdited(const QString &)), this, SIGNAL(completeChanged())); 508 connect(m_pLeOldPassword, SIGNAL(textEdited(const QString &)), this, SIGNAL(completeChanged())); 509 connect(m_pLeNewFirstName, SIGNAL(textEdited(const QString &)), this, SIGNAL(completeChanged())); 510 connect(m_pLeNewLastName, SIGNAL(textEdited(const QString &)), this, SIGNAL(completeChanged())); 511 connect(m_pLeNewCompany, SIGNAL(textEdited(const QString &)), this, SIGNAL(completeChanged())); 512 connect(m_pCbNewCountry, SIGNAL(currentIndexChanged(int)), this, SIGNAL(completeChanged())); 513 connect(m_pLeNewEmail, SIGNAL(textEdited(const QString &)), this, SIGNAL(completeChanged())); 514 connect(m_pLeNewPassword, SIGNAL(textEdited(const QString &)), this, SIGNAL(completeChanged())); 515 connect(m_pLeNewConfirmPassword, SIGNAL(textEdited(const QString &)), this, SIGNAL(completeChanged())); 516 517 /* Initial values */ 518 m_pRbPresent->click(); 519 RegistrationData data(vboxGlobal().virtualBox().GetExtraData(VBoxDefs::GUI_RegistrationData), false); 520 m_pLeOldEmail->setText(data.account()); 521 m_pLeOldEmail->setFocus(); 522 523 /* Translate */ 284 524 retranslateUi(); 285 286 /* Fix minimum possible size */ 287 resize (minimumSizeHint()); 288 qApp->processEvents(); 289 setFixedSize (size()); 290 } 291 292 VBoxRegistrationDlg::~VBoxRegistrationDlg() 293 { 294 /* Erase dialog handle in config file. */ 295 vboxGlobal().virtualBox().SetExtraData (VBoxDefs::GUI_RegistrationDlgWinID, 296 QString::null); 297 298 /* Erase external pointer to this dialog. */ 299 *mSelf = 0; 300 } 301 302 void VBoxRegistrationDlg::retranslateUi() 525 } 526 527 void UIRegistrationWzdPage1::retranslateUi() 303 528 { 304 529 /* Translate uic generated strings */ 305 Ui::VBoxRegistrationDlg::retranslateUi (this); 530 Ui::UIRegistrationWzdPage1::retranslateUi(this); 531 532 /* Wizard page 1 title */ 533 setTitle(tr("Welcome to the VirtualBox Registration Form!")); 306 534 307 535 /* Translate the first element of countries list */ 308 mCbNewCountry->setItemText (0, tr ("Select Country/Territory")); 309 } 310 311 void VBoxRegistrationDlg::radioButtonToggled() 312 { 313 QRadioButton *current = mRbOld->isChecked() ? mRbOld : mRbNew; 314 315 mLeOldEmail->setEnabled (current == mRbOld); 316 mLeOldPassword->setEnabled (current == mRbOld); 317 mLeNewFirstName->setEnabled (current == mRbNew); 318 mLeNewLastName->setEnabled (current == mRbNew); 319 mLeNewCompany->setEnabled (current == mRbNew); 320 mCbNewCountry->setEnabled (current == mRbNew); 321 mLeNewEmail->setEnabled (current == mRbNew); 322 mLeNewPassword->setEnabled (current == mRbNew); 323 mLeNewPassword2->setEnabled (current == mRbNew); 324 325 mWvalReg->revalidate(); 326 } 327 328 /* Post the handshake request into the register site. */ 329 void VBoxRegistrationDlg::accept() 330 { 331 /* Disable control elements */ 332 mLeOldEmail->setEnabled (false); 333 mLeOldPassword->setEnabled (false); 334 mLeNewFirstName->setEnabled (false); 335 mLeNewLastName->setEnabled (false); 336 mLeNewCompany->setEnabled (false); 337 mCbNewCountry->setEnabled (false); 338 mLeNewEmail->setEnabled (false); 339 mLeNewPassword->setEnabled (false); 340 mLeNewPassword2->setEnabled (false); 341 finishButton()->setEnabled (false); 342 cancelButton()->setEnabled (false); 536 m_pCbNewCountry->setItemText(0, tr("Select Country/Territory")); 537 } 538 539 bool UIRegistrationWzdPage1::isComplete() const 540 { 541 if (m_pRbPresent->isChecked()) 542 { 543 /* Check for fields correctness */ 544 if (!isFieldValid(m_pLeOldEmail) || !isFieldValid(m_pLeOldPassword)) 545 return false; 546 } 547 if (m_pRbCreate->isChecked()) 548 { 549 /* Check for fields correctness */ 550 if (!isFieldValid (m_pLeNewFirstName) || !isFieldValid (m_pLeNewLastName) || 551 !isFieldValid (m_pLeNewCompany) || !isFieldValid (m_pCbNewCountry) || 552 !isFieldValid (m_pLeNewEmail) || 553 !isFieldValid (m_pLeNewPassword) || !isFieldValid (m_pLeNewConfirmPassword)) 554 return false; 555 556 /* Check for password correctness */ 557 if (m_pLeNewPassword->text() != m_pLeNewConfirmPassword->text()) 558 return false; 559 } 560 return true; 561 } 562 563 bool UIRegistrationWzdPage1::validatePage() 564 { 565 /* Create registration engine */ 566 RegistrationEngine engine(this); 567 568 /* Initialize registration engine */ 569 if (m_pRbPresent->isChecked()) 570 { 571 engine.setOldData(vboxGlobal().virtualBox().GetVersion(), vboxGlobal().platformInfo(), 572 m_pLeOldEmail->text(), m_pLeOldPassword->text()); 573 } 574 if (m_pRbCreate->isChecked()) 575 { 576 engine.setNewData(vboxGlobal().virtualBox().GetVersion(), vboxGlobal().platformInfo(), 577 m_pLeNewEmail->text(), m_pLeNewPassword->text(), 578 m_pLeNewFirstName->text(), m_pLeNewLastName->text(), 579 m_pLeNewCompany->text(), m_pCbNewCountry->currentText()); 580 } 581 582 /* Disable wizard */ 583 wizard()->setEnabled(false); 343 584 344 585 /* Set busy cursor */ 345 setCursor (QCursor (Qt::BusyCursor)); 346 347 /* Perform connection handshake */ 348 QTimer::singleShot (0, this, SLOT (handshakeStart())); 349 } 350 351 void VBoxRegistrationDlg::reject() 352 { 353 /* Decrement the triesLeft. */ 354 VBoxRegistrationData data (vboxGlobal().virtualBox(). 355 GetExtraData (VBoxDefs::GUI_RegistrationData), false); 356 if (!data.isValid() || !data.isRegistered()) 357 { 358 uint triesLeft = data.triesLeft(); 359 if (triesLeft) 360 { 361 -- triesLeft; 362 vboxGlobal().virtualBox().SetExtraData (VBoxDefs::GUI_RegistrationData, 363 QString ("triesLeft=%1") 364 .arg (triesLeft)); 365 } 366 } 367 368 QIAbstractWizard::reject(); 369 } 370 371 void VBoxRegistrationDlg::reinit() 372 { 373 /* Read all the dirty data */ 374 mHttp->disconnect (this); 375 mHttp->readAll(); 376 377 /* Enable control elements */ 378 radioButtonToggled(); 379 finishButton()->setEnabled (true); 380 cancelButton()->setEnabled (true); 381 382 /* Return 'default' attribute loosed 383 * when button was disabled... */ 384 finishButton()->setDefault (true); 385 finishButton()->setFocus(); 386 387 /* Unset busy cursor */ 586 setCursor(QCursor(Qt::BusyCursor)); 587 588 /* Perform registration routine */ 589 engine.start(); 590 591 /* Restore cursor */ 388 592 unsetCursor(); 389 } 390 391 void VBoxRegistrationDlg::handshakeStart() 392 { 393 /* Compose query */ 394 QUrl url (mUrl); 395 url.addQueryItem ("version", vboxGlobal().virtualBox().GetVersion()); 396 397 /* Handshake */ 398 connect (mHttp, SIGNAL (allIsDone (bool)), this, SLOT (handshakeResponse (bool))); 399 mHttp->post (url.toEncoded()); 400 } 401 402 void VBoxRegistrationDlg::handshakeResponse (bool aError) 403 { 404 /* Block all the other incoming signals */ 405 mHttp->disconnect (this); 406 407 /* Process error if present */ 408 if (aError) 409 return abortRequest (mHttp->errorString()); 410 411 /* Read received data */ 412 mKey = mHttp->readAll(); 413 414 /* Verifying key correctness */ 415 if (QString (mKey).indexOf (QRegExp ("^[a-zA-Z0-9]{32}$"))) 416 return abortRequest (tr ("Could not perform connection handshake.")); 417 418 /* Perform registration */ 419 QTimer::singleShot (0, this, SLOT (registrationStart())); 420 } 421 422 void VBoxRegistrationDlg::registrationStart() 423 { 424 /* Compose query */ 425 QUrl url (mUrl); 426 427 /* Basic set */ 428 url.addQueryItem ("version", vboxGlobal().virtualBox().GetVersion()); 429 url.addQueryItem ("key", mKey); 430 url.addQueryItem ("platform", vboxGlobal().platformInfo()); 431 432 if (mRbOld->isChecked()) 433 { 434 /* Light set */ 435 url.addQueryItem ("email", mLeOldEmail->text()); 436 url.addQueryItem ("password", mLeOldPassword->text()); 437 } 438 else if (mRbNew->isChecked()) 439 { 440 /* Full set */ 441 url.addQueryItem ("email", mLeNewEmail->text()); 442 url.addQueryItem ("password", mLeNewPassword->text()); 443 url.addQueryItem ("firstname", mLeNewFirstName->text()); 444 url.addQueryItem ("lastname", mLeNewLastName->text()); 445 url.addQueryItem ("company", mLeNewCompany->text()); 446 url.addQueryItem ("country", mCbNewCountry->currentText()); 447 } 448 449 /* Registration */ 450 connect (mHttp, SIGNAL (allIsDone (bool)), this, SLOT (registrationResponse (bool))); 451 mHttp->post (url.toEncoded()); 452 } 453 454 void VBoxRegistrationDlg::registrationResponse (bool aError) 455 { 456 /* Block all the other incoming signals */ 457 mHttp->disconnect (this); 458 459 /* Process error if present */ 460 if (aError) 461 return abortRequest (mHttp->errorString()); 462 463 /* Read received data */ 464 QString data (mHttp->readAll()); 465 466 /* Show registration result */ 467 vboxProblem().showRegisterResult (this, data); 468 469 /* Close the dialog */ 470 data == "OK" ? finish() : reinit(); 471 } 472 473 void VBoxRegistrationDlg::revalidate (QIWidgetValidator *aWval) 474 { 475 bool valid = true; 476 477 if (mRbOld->isChecked()) 478 { 479 /* Check for fields correctness */ 480 if (!isFieldValid (mLeOldEmail) || !isFieldValid (mLeOldPassword)) 481 valid = false; 482 } 483 if (mRbNew->isChecked()) 484 { 485 /* Check for fields correctness */ 486 if (!isFieldValid (mLeNewFirstName) || !isFieldValid (mLeNewLastName) || 487 !isFieldValid (mLeNewCompany) || !isFieldValid (mCbNewCountry) || 488 !isFieldValid (mLeNewEmail) || 489 !isFieldValid (mLeNewPassword) || !isFieldValid (mLeNewPassword2)) 490 valid = false; 491 492 /* Check for password correctness */ 493 if (mLeNewPassword->text() != mLeNewPassword2->text()) 494 valid = false; 495 } 496 497 aWval->setOtherValid (valid); 498 } 499 500 void VBoxRegistrationDlg::enableNext (const QIWidgetValidator *aWval) 501 { 502 /* Validate all the subscribed widgets */ 503 aWval->isValid(); 504 /* But control dialog only with necessary */ 505 finishButton()->setEnabled (aWval->isOtherValid()); 506 /* Return 'default' attribute loosed 507 * when button was disabled... */ 508 finishButton()->setDefault (true); 509 } 510 511 void VBoxRegistrationDlg::onPageShow() 512 { 513 Assert (mPageStack->currentWidget() == mPageReg); 514 mLeOldEmail->setFocus(); 515 } 516 517 void VBoxRegistrationDlg::populateCountries() 518 { 519 QStringList list ("Empty"); 593 594 /* Enable wizard */ 595 wizard()->setEnabled(true); 596 597 /* Save accepted account name */ 598 if (engine.result()) 599 { 600 /* Store registration data */ 601 QString strAccount = m_pRbPresent->isChecked() ? m_pLeOldEmail->text() : 602 m_pRbCreate->isChecked() ? m_pLeNewEmail->text() : QString(); 603 RegistrationData data(strAccount, true); 604 vboxGlobal().virtualBox().SetExtraData(VBoxDefs::GUI_RegistrationData, data.data()); 605 } 606 607 return engine.result(); 608 } 609 610 void UIRegistrationWzdPage1::sltAccountTypeChanged() 611 { 612 bool bPresentChosen = m_pRbPresent->isChecked(); 613 bool bCreateChosen = m_pRbCreate->isChecked(); 614 615 m_pLeOldEmail->setEnabled(bPresentChosen); 616 m_pLeOldPassword->setEnabled(bPresentChosen); 617 m_pLeNewFirstName->setEnabled(bCreateChosen); 618 m_pLeNewLastName->setEnabled(bCreateChosen); 619 m_pLeNewCompany->setEnabled(bCreateChosen); 620 m_pCbNewCountry->setEnabled(bCreateChosen); 621 m_pLeNewEmail->setEnabled(bCreateChosen); 622 m_pLeNewPassword->setEnabled(bCreateChosen); 623 m_pLeNewConfirmPassword->setEnabled(bCreateChosen); 624 625 emit completeChanged(); 626 } 627 628 void UIRegistrationWzdPage1::populateCountries() 629 { 630 QStringList list("Empty"); 520 631 list << "Afghanistan" 521 632 << "Albania" … … 755 866 << "Zambia" 756 867 << "Zimbabwe"; 757 mCbNewCountry->addItems (list); 758 } 759 760 /* This wrapper displays an error message box (unless aReason is QString::null) 761 * with the cause of the request-send procedure termination. After the message 762 * box dismissed, the registration dialog signals to close itself on the next 763 * event loop iteration. */ 764 void VBoxRegistrationDlg::abortRequest (const QString &aReason) 765 { 766 if (!aReason.isNull()) 767 vboxProblem().cannotConnectRegister (this, mUrl.toString(), aReason); 768 769 /* Allows all the queued signals to be processed before quit. */ 770 QTimer::singleShot (0, this, SLOT (reinit())); 771 } 772 773 void VBoxRegistrationDlg::finish() 774 { 775 QString acc (mRbOld->isChecked() ? mLeOldEmail->text() : 776 mRbNew->isChecked() ? mLeNewEmail->text() : QString::null); 777 778 VBoxRegistrationData data (acc, true); 779 vboxGlobal().virtualBox().SetExtraData (VBoxDefs::GUI_RegistrationData, 780 data.data()); 781 782 QIAbstractWizard::accept(); 783 } 784 785 bool VBoxRegistrationDlg::isFieldValid (QWidget *aWidget) const 786 { 787 if (QLineEdit *le = qobject_cast <QLineEdit*> (aWidget)) 788 { 789 QString text (le->text()); 790 int position; 791 return le->validator()->validate (text, position) == QValidator::Acceptable; 792 } 793 else if (QComboBox *cb = qobject_cast <QComboBox*> (aWidget)) 794 { 795 return cb->currentIndex() > 0; 868 m_pCbNewCountry->addItems(list); 869 } 870 871 bool UIRegistrationWzdPage1::isFieldValid(QWidget *pWidget) const 872 { 873 if (QLineEdit *pLineEdit = qobject_cast<QLineEdit*>(pWidget)) 874 { 875 QString strText(pLineEdit->text()); 876 int iPosition; 877 return pLineEdit->validator()->validate(strText, iPosition) == QValidator::Acceptable; 878 } 879 else if (QComboBox *pComboBox = qobject_cast<QComboBox*>(pWidget)) 880 { 881 return pComboBox->currentIndex() > 0; 796 882 } 797 883 return false; 798 884 } 799 885 886 #include "UIRegistrationWzd.moc" -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/registration/UIRegistrationWzd.h
r25432 r26079 2 2 * 3 3 * VBox frontends: Qt4 GUI ("VirtualBox"): 4 * VBoxRegistrationDlgclass declaration4 * UIRegistrationWzd class declaration 5 5 */ 6 6 7 7 /* 8 * Copyright (C) 200 6-2008Sun Microsystems, Inc.8 * Copyright (C) 2008-2010 Sun Microsystems, Inc. 9 9 * 10 10 * This file is part of VirtualBox Open Source Edition (OSE), as … … 21 21 */ 22 22 23 #ifndef __ VBoxRegistrationDlg_h__24 #define __ VBoxRegistrationDlg_h__23 #ifndef __UIRegistrationWzd_h__ 24 #define __UIRegistrationWzd_h__ 25 25 26 #include "QIAbstractWizard.h" 27 #include "QIWidgetValidator.h" 28 #include "QIWithRetranslateUI.h" 29 #include "VBoxRegistrationDlg.gen.h" 26 /* Local includes */ 27 #include "QIWizard.h" 30 28 31 /* Qtincludes */32 #include <QUrl>29 /* Generated includes */ 30 #include "UIRegistrationWzdPage1.gen.h" 33 31 34 class QIHttp; 35 36 class VBoxRegistrationDlg : public QIWithRetranslateUI <QIAbstractWizard>, 37 public Ui::VBoxRegistrationDlg 32 class UIRegistrationWzd : public QIWizard 38 33 { 39 34 Q_OBJECT; … … 43 38 static bool hasToBeShown(); 44 39 45 VBoxRegistrationDlg (VBoxRegistrationDlg **aSelf, QWidget *aParent = 0);46 ~ VBoxRegistrationDlg();40 UIRegistrationWzd(UIRegistrationWzd **ppThis); 41 ~UIRegistrationWzd(); 47 42 48 43 protected: … … 52 47 private slots: 53 48 54 void r adioButtonToggled();49 void reject(); 55 50 56 void accept(); 57 void reject(); 58 void reinit(); 51 private: 59 52 60 void handshakeStart();61 void handshakeResponse (bool aError);53 UIRegistrationWzd **m_ppThis; 54 }; 62 55 63 void registrationStart(); 64 void registrationResponse (bool aError); 56 class UIRegistrationWzdPage1 : public QIWizardPage, public Ui::UIRegistrationWzdPage1 57 { 58 Q_OBJECT; 65 59 66 void revalidate (QIWidgetValidator *aWval); 67 void enableNext (const QIWidgetValidator *aWval); 68 void onPageShow(); 60 public: 61 62 UIRegistrationWzdPage1(); 63 64 protected: 65 66 void retranslateUi(); 67 68 bool isComplete() const; 69 bool validatePage(); 70 71 private slots: 72 73 void sltAccountTypeChanged(); 69 74 70 75 private: 71 76 72 77 void populateCountries(); 73 void abortRequest (const QString &aReason);74 void finish();75 78 76 bool isFieldValid (QWidget *aWidget) const; 77 78 VBoxRegistrationDlg **mSelf; 79 QIWidgetValidator *mWvalReg; 80 QUrl mUrl; 81 QIHttp *mHttp; 82 QString mKey; 79 bool isFieldValid(QWidget *pWidget) const; 83 80 }; 84 81 85 #endif // __VBoxRegistrationDlg_h__ 86 82 #endif // __UIRegistrationWzd_h__ -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/registration/UIRegistrationWzdPage1.ui
r25432 r26079 1 < ui version="4.0">2 <class>VBoxRegistrationDlg</class>1 <?xml version="1.0" encoding="UTF-8"?> 2 <ui version="4.0"> 3 3 <comment> 4 4 VBox frontends: Qt4 GUI ("VirtualBox"): 5 5 6 Copyright (C) 2008 Sun Microsystems, Inc.6 Copyright (C) 2008-2010 Sun Microsystems, Inc. 7 7 8 8 This file is part of VirtualBox Open Source Edition (OSE), as … … 18 18 additional information or have any questions. 19 19 </comment> 20 <widget class="QDialog" name="VBoxRegistrationDlg" > 21 <property name="geometry" > 20 <class>UIRegistrationWzdPage1</class> 21 <widget class="QWidget" name="UIRegistrationWzdPage1"> 22 <property name="geometry"> 22 23 <rect> 23 24 <x>0</x> 24 25 <y>0</y> 25 <width> 639</width>26 <height> 513</height>26 <width>800</width> 27 <height>600</height> 27 28 </rect> 28 29 </property> 29 <property name="windowTitle" > 30 <string>VirtualBox Registration Dialog</string> 30 <property name="sizePolicy"> 31 <sizepolicy hsizetype="Minimum" vsizetype="Minimum"> 32 <horstretch>0</horstretch> 33 <verstretch>0</verstretch> 34 </sizepolicy> 31 35 </property> 32 <layout class="QVBoxLayout" > 33 <property name="leftMargin" > 34 <number>0</number> 35 </property> 36 <property name="topMargin" > 37 <number>0</number> 38 </property> 39 <property name="rightMargin" > 40 <number>0</number> 41 </property> 36 <layout class="QGridLayout" name="m_pLayout1"> 42 37 <property name="bottomMargin" > 43 38 <number>0</number> 44 39 </property> 45 <item> 46 <widget class="QStackedWidget" name="mPageStack" > 47 <property name="currentIndex" > 48 <number>0</number> 49 </property> 50 <widget class="QWidget" name="mPageReg" > 51 <layout class="QGridLayout" name="gridLayout" > 52 <item row="0" column="0" colspan="4" > 53 <widget class="QLabel" name="mPageSummaryHdr" > 54 <property name="font" > 55 <font> 56 <family>Arial</family> 57 <pointsize>12</pointsize> 58 <weight>75</weight> 59 <bold>true</bold> 60 </font> 61 </property> 62 <property name="text" > 63 <string>Welcome to the VirtualBox Registration Form!</string> 64 </property> 65 </widget> 66 </item> 67 <item row="1" column="0" colspan="4" > 68 <widget class="Line" name="line11" > 69 <property name="orientation" > 70 <enum>Qt::Horizontal</enum> 71 </property> 72 </widget> 73 </item> 74 <item rowspan="15" row="2" column="0" > 75 <widget class="QLabel" name="mLogoSummary" > 76 <property name="sizePolicy" > 77 <sizepolicy vsizetype="Minimum" hsizetype="Maximum" > 78 <horstretch>0</horstretch> 79 <verstretch>0</verstretch> 80 </sizepolicy> 81 </property> 82 <property name="autoFillBackground" > 83 <bool>true</bool> 84 </property> 85 <property name="pixmap" > 86 <pixmap resource="../VirtualBox1.qrc" >:/vmw_new_user.png</pixmap> 87 </property> 88 <property name="alignment" > 89 <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set> 90 </property> 91 </widget> 92 </item> 93 <item row="2" column="1" colspan="3" > 94 <widget class="QILabel" name="mTextRegInfo" > 95 <property name="sizePolicy" > 96 <sizepolicy vsizetype="Minimum" hsizetype="Minimum" > 97 <horstretch>0</horstretch> 98 <verstretch>0</verstretch> 99 </sizepolicy> 100 </property> 101 <property name="minimumSize" > 102 <size> 103 <width>500</width> 104 <height>0</height> 105 </size> 106 </property> 107 <property name="text" > 108 <string><p>Please fill out this registration form to let us know that you use VirtualBox and, optionally, to keep you informed about VirtualBox news and updates.</p><p>Please use Latin characters only to fill in the fields below. Sun Microsystems will use this information only to gather product usage statistics and to send you VirtualBox newsletters. In particular, Sun Microsystems will never pass your data to third parties. Detailed information about how we use your personal data can be found in the <b>Privacy Policy</b> section of the VirtualBox Manual or on the <a href=http://www.virtualbox.org/wiki/PrivacyPolicy>Privacy Policy</a> page of the VirtualBox web-site.</p></string> 109 </property> 110 <property name="wordWrap" > 111 <bool>true</bool> 112 </property> 113 </widget> 114 </item> 115 <item row="3" column="1" colspan="3" > 116 <widget class="Line" name="line14" > 117 <property name="orientation" > 118 <enum>Qt::Horizontal</enum> 119 </property> 120 </widget> 121 </item> 122 <item row="4" column="1" colspan="3" > 123 <widget class="QRadioButton" name="mRbOld" > 124 <property name="text" > 125 <string>I &already have a Sun Online account:</string> 126 </property> 127 <property name="checked" > 128 <bool>true</bool> 129 </property> 130 </widget> 131 </item> 132 <item rowspan="2" row="5" column="1" > 133 <spacer name="mHorizontalSpacer1" > 134 <property name="orientation" > 135 <enum>Qt::Horizontal</enum> 136 </property> 137 <property name="sizeType" > 138 <enum>QSizePolicy::Fixed</enum> 139 </property> 140 <property name="sizeHint" stdset="0" > 141 <size> 142 <width>20</width> 143 <height>0</height> 144 </size> 145 </property> 146 </spacer> 147 </item> 148 <item row="5" column="2" > 149 <widget class="QLabel" name="mTxOldEmail" > 150 <property name="text" > 151 <string>&E-mail:</string> 152 </property> 153 <property name="alignment" > 154 <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> 155 </property> 156 <property name="buddy" > 157 <cstring>mLeOldEmail</cstring> 158 </property> 159 </widget> 160 </item> 161 <item row="5" column="3" > 162 <widget class="QLineEdit" name="mLeOldEmail" > 163 <property name="whatsThis" > 164 <string>Enter your e-mail address. Please use a valid address here.</string> 165 </property> 166 </widget> 167 </item> 168 <item row="6" column="2" > 169 <widget class="QLabel" name="mTxOldPassword" > 170 <property name="text" > 171 <string>&Password:</string> 172 </property> 173 <property name="alignment" > 174 <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> 175 </property> 176 <property name="buddy" > 177 <cstring>mLeOldPassword</cstring> 178 </property> 179 </widget> 180 </item> 181 <item row="6" column="3" > 182 <widget class="QLineEdit" name="mLeOldPassword" > 183 <property name="whatsThis" > 184 <string>Enter your e-mail address. Please use a valid address here.</string> 185 </property> 186 <property name="echoMode" > 187 <enum>QLineEdit::Password</enum> 188 </property> 189 </widget> 190 </item> 191 <item row="7" column="1" colspan="3" > 192 <widget class="Line" name="line13" > 193 <property name="orientation" > 194 <enum>Qt::Horizontal</enum> 195 </property> 196 </widget> 197 </item> 198 <item row="8" column="1" colspan="3" > 199 <widget class="QRadioButton" name="mRbNew" > 200 <property name="text" > 201 <string>I &would like to create a new Sun Online account:</string> 202 </property> 203 </widget> 204 </item> 205 <item rowspan="8" row="9" column="1" > 206 <spacer name="mHorizontalSpacer2" > 207 <property name="orientation" > 208 <enum>Qt::Horizontal</enum> 209 </property> 210 <property name="sizeType" > 211 <enum>QSizePolicy::Fixed</enum> 212 </property> 213 <property name="sizeHint" stdset="0" > 214 <size> 215 <width>20</width> 216 <height>0</height> 217 </size> 218 </property> 219 </spacer> 220 </item> 221 <item row="9" column="2" > 222 <widget class="QLabel" name="mTxNewFirstName" > 223 <property name="text" > 224 <string>&First Name:</string> 225 </property> 226 <property name="alignment" > 227 <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> 228 </property> 229 <property name="buddy" > 230 <cstring>mLeNewFirstName</cstring> 231 </property> 232 </widget> 233 </item> 234 <item row="9" column="3" > 235 <widget class="QLineEdit" name="mLeNewFirstName" > 236 <property name="whatsThis" > 237 <string>Enter your full name using Latin characters.</string> 238 </property> 239 </widget> 240 </item> 241 <item row="10" column="2" > 242 <widget class="QLabel" name="mTxNewLastName" > 243 <property name="text" > 244 <string>&Last Name:</string> 245 </property> 246 <property name="alignment" > 247 <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> 248 </property> 249 <property name="buddy" > 250 <cstring>mLeNewLastName</cstring> 251 </property> 252 </widget> 253 </item> 254 <item row="10" column="3" > 255 <widget class="QLineEdit" name="mLeNewLastName" > 256 <property name="whatsThis" > 257 <string>Enter your full name using Latin characters.</string> 258 </property> 259 </widget> 260 </item> 261 <item row="11" column="2" > 262 <widget class="QLabel" name="mTxNewCompany" > 263 <property name="text" > 264 <string>&Company:</string> 265 </property> 266 <property name="alignment" > 267 <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> 268 </property> 269 <property name="buddy" > 270 <cstring>mLeNewCompany</cstring> 271 </property> 272 </widget> 273 </item> 274 <item row="11" column="3" > 275 <widget class="QLineEdit" name="mLeNewCompany" > 276 <property name="whatsThis" > 277 <string>Enter your full name using Latin characters.</string> 278 </property> 279 </widget> 280 </item> 281 <item row="12" column="2" > 282 <widget class="QLabel" name="mTxNewCountry" > 283 <property name="text" > 284 <string>Co&untry:</string> 285 </property> 286 <property name="alignment" > 287 <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> 288 </property> 289 <property name="buddy" > 290 <cstring>mCbNewCountry</cstring> 291 </property> 292 </widget> 293 </item> 294 <item row="12" column="3" > 295 <widget class="QComboBox" name="mCbNewCountry" > 296 <property name="whatsThis" > 297 <string>Enter your full name using Latin characters.</string> 298 </property> 299 </widget> 300 </item> 301 <item row="13" column="2" colspan="2" > 302 <spacer name="mVerticalSpacer2" > 303 <property name="orientation" > 304 <enum>Qt::Vertical</enum> 305 </property> 306 <property name="sizeType" > 307 <enum>QSizePolicy::Fixed</enum> 308 </property> 309 <property name="sizeHint" stdset="0" > 310 <size> 311 <width>0</width> 312 <height>5</height> 313 </size> 314 </property> 315 </spacer> 316 </item> 317 <item row="14" column="2" > 318 <widget class="QLabel" name="mTxNewEmail" > 319 <property name="text" > 320 <string>E-&mail:</string> 321 </property> 322 <property name="alignment" > 323 <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> 324 </property> 325 <property name="buddy" > 326 <cstring>mLeNewEmail</cstring> 327 </property> 328 </widget> 329 </item> 330 <item row="14" column="3" > 331 <widget class="QLineEdit" name="mLeNewEmail" > 332 <property name="whatsThis" > 333 <string>Enter your full name using Latin characters.</string> 334 </property> 335 </widget> 336 </item> 337 <item row="15" column="2" > 338 <widget class="QLabel" name="mTxNewPassword" > 339 <property name="text" > 340 <string>P&assword:</string> 341 </property> 342 <property name="alignment" > 343 <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> 344 </property> 345 <property name="buddy" > 346 <cstring>mLeNewPassword</cstring> 347 </property> 348 </widget> 349 </item> 350 <item row="15" column="3" > 351 <widget class="QLineEdit" name="mLeNewPassword" > 352 <property name="whatsThis" > 353 <string>Enter your full name using Latin characters.</string> 354 </property> 355 <property name="echoMode" > 356 <enum>QLineEdit::Password</enum> 357 </property> 358 </widget> 359 </item> 360 <item row="16" column="2" > 361 <widget class="QLabel" name="mTxNewPassword2" > 362 <property name="text" > 363 <string>Co&nfirm Password:</string> 364 </property> 365 <property name="alignment" > 366 <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> 367 </property> 368 <property name="buddy" > 369 <cstring>mLeNewPassword2</cstring> 370 </property> 371 </widget> 372 </item> 373 <item row="16" column="3" > 374 <widget class="QLineEdit" name="mLeNewPassword2" > 375 <property name="whatsThis" > 376 <string>Enter your full name using Latin characters.</string> 377 </property> 378 <property name="echoMode" > 379 <enum>QLineEdit::Password</enum> 380 </property> 381 </widget> 382 </item> 383 <item row="17" column="0" colspan="4" > 384 <widget class="Line" name="line12" > 385 <property name="orientation" > 386 <enum>Qt::Horizontal</enum> 387 </property> 388 </widget> 389 </item> 390 <item row="18" column="0" colspan="4" > 391 <layout class="QHBoxLayout" > 392 <item> 393 <spacer name="mHorizontalSpacer1" > 394 <property name="orientation" > 395 <enum>Qt::Horizontal</enum> 396 </property> 397 <property name="sizeHint" stdset="0" > 398 <size> 399 <width>0</width> 400 <height>0</height> 401 </size> 402 </property> 403 </spacer> 404 </item> 405 <item> 406 <widget class="QPushButton" name="mBtnFinish" > 407 <property name="text" > 408 <string>&Register</string> 409 </property> 410 <property name="default" > 411 <bool>true</bool> 412 </property> 413 </widget> 414 </item> 415 <item> 416 <spacer name="mHorizontalSpacer2" > 417 <property name="orientation" > 418 <enum>Qt::Horizontal</enum> 419 </property> 420 <property name="sizeType" > 421 <enum>QSizePolicy::Fixed</enum> 422 </property> 423 <property name="sizeHint" stdset="0" > 424 <size> 425 <width>5</width> 426 <height>0</height> 427 </size> 428 </property> 429 </spacer> 430 </item> 431 <item> 432 <widget class="QPushButton" name="mBtnCancel" > 433 <property name="text" > 434 <string>Cancel</string> 435 </property> 436 </widget> 437 </item> 438 </layout> 439 </item> 440 </layout> 441 </widget> 40 <item row="1" column="0" colspan="3"> 41 <widget class="Line" name="m_pLine1"> 42 <property name="orientation"> 43 <enum>Qt::Horizontal</enum> 44 </property> 45 </widget> 46 </item> 47 <item row="2" column="0" colspan="3"> 48 <widget class="QRadioButton" name="m_pRbPresent"> 49 <property name="text"> 50 <string>I &already have a Sun Online account:</string> 51 </property> 52 </widget> 53 </item> 54 <item row="3" column="0" rowspan="2"> 55 <spacer name="m_pSpacer1"> 56 <property name="orientation"> 57 <enum>Qt::Horizontal</enum> 58 </property> 59 <property name="sizeType"> 60 <enum>QSizePolicy::Fixed</enum> 61 </property> 62 <property name="sizeHint" stdset="0"> 63 <size> 64 <width>17</width> 65 <height>0</height> 66 </size> 67 </property> 68 </spacer> 69 </item> 70 <item row="3" column="1"> 71 <widget class="QLabel" name="m_pLbOldEmail"> 72 <property name="text"> 73 <string>&E-mail:</string> 74 </property> 75 <property name="alignment"> 76 <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> 77 </property> 78 <property name="buddy"> 79 <cstring>m_pLeOldEmail</cstring> 80 </property> 81 </widget> 82 </item> 83 <item row="3" column="2"> 84 <widget class="QLineEdit" name="m_pLeOldEmail"> 85 <property name="whatsThis"> 86 <string>Enter your e-mail address. Please use a valid address here.</string> 87 </property> 88 </widget> 89 </item> 90 <item row="4" column="1"> 91 <widget class="QLabel" name="m_pLbOldPassword"> 92 <property name="text"> 93 <string>&Password:</string> 94 </property> 95 <property name="alignment"> 96 <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> 97 </property> 98 <property name="buddy"> 99 <cstring>m_pLeOldPassword</cstring> 100 </property> 101 </widget> 102 </item> 103 <item row="4" column="2"> 104 <widget class="QLineEdit" name="m_pLeOldPassword"> 105 <property name="whatsThis"> 106 <string>Enter your e-mail address. Please use a valid address here.</string> 107 </property> 108 <property name="echoMode"> 109 <enum>QLineEdit::Password</enum> 110 </property> 111 </widget> 112 </item> 113 <item row="5" column="0" colspan="3"> 114 <widget class="Line" name="m_pLine2"> 115 <property name="orientation"> 116 <enum>Qt::Horizontal</enum> 117 </property> 118 </widget> 119 </item> 120 <item row="6" column="0" colspan="3"> 121 <widget class="QRadioButton" name="m_pRbCreate"> 122 <property name="text"> 123 <string>I &would like to create a new Sun Online account:</string> 124 </property> 125 </widget> 126 </item> 127 <item row="7" column="0" rowspan="8"> 128 <spacer name="m_pSpacer2"> 129 <property name="orientation"> 130 <enum>Qt::Horizontal</enum> 131 </property> 132 <property name="sizeType"> 133 <enum>QSizePolicy::Fixed</enum> 134 </property> 135 <property name="sizeHint" stdset="0"> 136 <size> 137 <width>17</width> 138 <height>0</height> 139 </size> 140 </property> 141 </spacer> 142 </item> 143 <item row="7" column="1"> 144 <widget class="QLabel" name="m_pLbNewFirstName"> 145 <property name="text"> 146 <string>&First Name:</string> 147 </property> 148 <property name="alignment"> 149 <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> 150 </property> 151 <property name="buddy"> 152 <cstring>m_pLeNewFirstName</cstring> 153 </property> 154 </widget> 155 </item> 156 <item row="7" column="2"> 157 <widget class="QLineEdit" name="m_pLeNewFirstName"> 158 <property name="whatsThis"> 159 <string>Enter your full name using Latin characters.</string> 160 </property> 161 </widget> 162 </item> 163 <item row="8" column="1"> 164 <widget class="QLabel" name="m_pLbNewLastName"> 165 <property name="text"> 166 <string>&Last Name:</string> 167 </property> 168 <property name="alignment"> 169 <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> 170 </property> 171 <property name="buddy"> 172 <cstring>m_pLeNewLastName</cstring> 173 </property> 174 </widget> 175 </item> 176 <item row="8" column="2"> 177 <widget class="QLineEdit" name="m_pLeNewLastName"> 178 <property name="whatsThis"> 179 <string>Enter your full name using Latin characters.</string> 180 </property> 181 </widget> 182 </item> 183 <item row="9" column="1"> 184 <widget class="QLabel" name="m_pLbNewCompany"> 185 <property name="text"> 186 <string>&Company:</string> 187 </property> 188 <property name="alignment"> 189 <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> 190 </property> 191 <property name="buddy"> 192 <cstring>m_pLeNewCompany</cstring> 193 </property> 194 </widget> 195 </item> 196 <item row="9" column="2"> 197 <widget class="QLineEdit" name="m_pLeNewCompany"> 198 <property name="whatsThis"> 199 <string>Enter your full name using Latin characters.</string> 200 </property> 201 </widget> 202 </item> 203 <item row="10" column="1"> 204 <widget class="QLabel" name="m_pLbNewCountry"> 205 <property name="text"> 206 <string>Co&untry:</string> 207 </property> 208 <property name="alignment"> 209 <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> 210 </property> 211 <property name="buddy"> 212 <cstring>m_pCbNewCountry</cstring> 213 </property> 214 </widget> 215 </item> 216 <item row="10" column="2"> 217 <widget class="QComboBox" name="m_pCbNewCountry"> 218 <property name="whatsThis"> 219 <string>Enter your full name using Latin characters.</string> 220 </property> 221 </widget> 222 </item> 223 <item row="11" column="1" colspan="2"> 224 <spacer name="m_pSpacer3"> 225 <property name="sizeType"> 226 <enum>QSizePolicy::Fixed</enum> 227 </property> 228 <property name="sizeHint" stdset="0"> 229 <size> 230 <width>0</width> 231 <height>0</height> 232 </size> 233 </property> 234 </spacer> 235 </item> 236 <item row="12" column="1"> 237 <widget class="QLabel" name="m_pLbNewEmail"> 238 <property name="text"> 239 <string>E-&mail:</string> 240 </property> 241 <property name="alignment"> 242 <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> 243 </property> 244 <property name="buddy"> 245 <cstring>m_pLeNewEmail</cstring> 246 </property> 247 </widget> 248 </item> 249 <item row="12" column="2"> 250 <widget class="QLineEdit" name="m_pLeNewEmail"> 251 <property name="whatsThis"> 252 <string>Enter your full name using Latin characters.</string> 253 </property> 254 </widget> 255 </item> 256 <item row="13" column="1"> 257 <widget class="QLabel" name="m_pLbNewPassword"> 258 <property name="text"> 259 <string>P&assword:</string> 260 </property> 261 <property name="alignment"> 262 <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> 263 </property> 264 <property name="buddy"> 265 <cstring>m_pLeNewPassword</cstring> 266 </property> 267 </widget> 268 </item> 269 <item row="13" column="2"> 270 <widget class="QLineEdit" name="m_pLeNewPassword"> 271 <property name="whatsThis"> 272 <string>Enter your full name using Latin characters.</string> 273 </property> 274 <property name="echoMode"> 275 <enum>QLineEdit::Password</enum> 276 </property> 277 </widget> 278 </item> 279 <item row="14" column="1"> 280 <widget class="QLabel" name="m_pLbNewConfirmPassword"> 281 <property name="text"> 282 <string>Co&nfirm Password:</string> 283 </property> 284 <property name="alignment"> 285 <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> 286 </property> 287 <property name="buddy"> 288 <cstring>m_pLeNewConfirmPassword</cstring> 289 </property> 290 </widget> 291 </item> 292 <item row="14" column="2"> 293 <widget class="QLineEdit" name="m_pLeNewConfirmPassword"> 294 <property name="whatsThis"> 295 <string>Enter your full name using Latin characters.</string> 296 </property> 297 <property name="echoMode"> 298 <enum>QLineEdit::Password</enum> 299 </property> 300 </widget> 301 </item> 302 <item row="15" column="0" colspan="3"> 303 <spacer name="m_pSpacer4"> 304 <property name="orientation"> 305 <enum>Qt::Vertical</enum> 306 </property> 307 <property name="sizeHint" stdset="0"> 308 <size> 309 <width>0</width> 310 <height>0</height> 311 </size> 312 </property> 313 </spacer> 314 </item> 315 <item row="0" column="0" colspan="3"> 316 <widget class="QILabel" name="m_pPage1Text1"> 317 <property name="text"> 318 <string><p>Please fill out this registration form to let us know that you use VirtualBox and, optionally, to keep you informed about VirtualBox news and updates.</p><p>Please use Latin characters only to fill in the fields below. Sun Microsystems will use this information only to gather product usage statistics and to send you VirtualBox newsletters. In particular, Sun Microsystems will never pass your data to third parties. Detailed information about how we use your personal data can be found in the <b>Privacy Policy</b> section of the VirtualBox Manual or on the <a href=http://www.virtualbox.org/wiki/PrivacyPolicy>Privacy Policy</a> page of the VirtualBox web-site.</p></string> 319 </property> 320 <property name="wordWrap"> 321 <bool>true</bool> 322 </property> 442 323 </widget> 443 324 </item> … … 451 332 </customwidget> 452 333 </customwidgets> 453 <tabstops> 454 <tabstop>mBtnFinish</tabstop> 455 <tabstop>mBtnCancel</tabstop> 456 </tabstops> 457 <resources> 458 <include location="../VirtualBox1.qrc" /> 459 </resources> 334 <resources/> 460 335 <connections/> 461 336 </ui>
Note:
See TracChangeset
for help on using the changeset viewer.