VirtualBox

source: vbox/trunk/src/VBox/Frontends/VirtualBox/src/wizards/newvm/UIWizardNewVMDiskPage.h@ 104158

Last change on this file since 104158 was 103982, checked in by vboxsync, 10 months ago

FE/Qt: bugref:10624. Replacing override and final keywords with RT_OVERRIDE and RT_FINAL defines.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 3.4 KB
Line 
1/* $Id: UIWizardNewVMDiskPage.h 103982 2024-03-21 11:43:53Z vboxsync $ */
2/** @file
3 * VBox Qt GUI - UIWizardNewVMDiskPage class declaration.
4 */
5
6/*
7 * Copyright (C) 2006-2023 Oracle and/or its affiliates.
8 *
9 * This file is part of VirtualBox base platform packages, as
10 * available from https://www.virtualbox.org.
11 *
12 * This program is free software; you can redistribute it and/or
13 * modify it under the terms of the GNU General Public License
14 * as published by the Free Software Foundation, in version 3 of the
15 * License.
16 *
17 * This program is distributed in the hope that it will be useful, but
18 * WITHOUT ANY WARRANTY; without even the implied warranty of
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
20 * General Public License for more details.
21 *
22 * You should have received a copy of the GNU General Public License
23 * along with this program; if not, see <https://www.gnu.org/licenses>.
24 *
25 * SPDX-License-Identifier: GPL-3.0-only
26 */
27
28#ifndef FEQT_INCLUDED_SRC_wizards_newvm_UIWizardNewVMDiskPage_h
29#define FEQT_INCLUDED_SRC_wizards_newvm_UIWizardNewVMDiskPage_h
30#ifndef RT_WITHOUT_PRAGMA_ONCE
31# pragma once
32#endif
33
34/* Qt includes: */
35#include <QSet>
36
37/* GUI includes: */
38#include "QIFileDialog.h"
39#include "UINativeWizardPage.h"
40
41/* COM includes: */
42#include "CMedium.h"
43
44/* Forward declarations: */
45class QButtonGroup;
46class QCheckBox;
47class QRadioButton;
48class QLabel;
49class QIRichTextLabel;
50class QIToolButton;
51class UIActionPool;
52class UIMediaComboBox;
53class UIMediumSizeEditor;
54
55namespace UIWizardNewVMDiskCommon
56{
57 QUuid getWithFileOpenDialog(const QString &strOSTypeID,
58 const QString &strMachineFolder,
59 QWidget *pCaller, UIActionPool *pActionPool);
60}
61
62
63class UIWizardNewVMDiskPage : public UINativeWizardPage
64{
65 Q_OBJECT;
66
67public:
68
69 UIWizardNewVMDiskPage(UIActionPool *pActionPool);
70
71protected:
72
73
74private slots:
75
76 void sltSelectedDiskSourceChanged();
77 void sltMediaComboBoxIndexChanged();
78 void sltGetWithFileOpenDialog();
79 void sltHandleSizeEditorChange(qulonglong uSize);
80 void sltFixedCheckBoxToggled(bool fChecked);
81 virtual void sltRetranslateUI() RT_OVERRIDE RT_FINAL;
82
83private:
84
85 void prepare();
86 void createConnections();
87 QWidget *createNewDiskWidgets();
88 void setEnableNewDiskWidgets(bool fEnable);
89 QWidget *createDiskWidgets();
90 QWidget *createMediumVariantWidgets(bool fWithLabels);
91
92 virtual void initializePage() RT_OVERRIDE RT_FINAL;
93 virtual bool isComplete() const RT_OVERRIDE RT_FINAL;
94
95 void setEnableDiskSelectionWidgets(bool fEnabled);
96 void setWidgetVisibility(const CMediumFormat &mediumFormat);
97
98 /** @name Widgets
99 * @{ */
100 QButtonGroup *m_pDiskSourceButtonGroup;
101 QRadioButton *m_pDiskEmpty;
102 QRadioButton *m_pDiskNew;
103 QRadioButton *m_pDiskExisting;
104 UIMediaComboBox *m_pDiskSelector;
105 QIToolButton *m_pDiskSelectionButton;
106 QIRichTextLabel *m_pLabel;
107 QLabel *m_pMediumSizeEditorLabel;
108 UIMediumSizeEditor *m_pMediumSizeEditor;
109 QIRichTextLabel *m_pDescriptionLabel;
110 QIRichTextLabel *m_pDynamicLabel;
111 QIRichTextLabel *m_pFixedLabel;
112 QCheckBox *m_pFixedCheckBox;
113 /** @} */
114
115 /** @name Variables
116 * @{ */
117 QSet<QString> m_userModifiedParameters;
118 bool m_fVDIFormatFound;
119 qulonglong m_uMediumSizeMin;
120 qulonglong m_uMediumSizeMax;
121 /** @} */
122 UIActionPool *m_pActionPool;
123};
124
125#endif /* !FEQT_INCLUDED_SRC_wizards_newvm_UIWizardNewVMDiskPage_h */
Note: See TracBrowser for help on using the repository browser.

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