1 | /** @file
|
---|
2 | *
|
---|
3 | * VBox frontends: Qt GUI ("VirtualBox"):
|
---|
4 | * UIMediumTypeChangeDialog class declaration
|
---|
5 | */
|
---|
6 |
|
---|
7 | /*
|
---|
8 | * Copyright (C) 2011 Oracle Corporation
|
---|
9 | *
|
---|
10 | * This file is part of VirtualBox Open Source Edition (OSE), as
|
---|
11 | * available from http://www.virtualbox.org. This file is free software;
|
---|
12 | * you can redistribute it and/or modify it under the terms of the GNU
|
---|
13 | * General Public License (GPL) as published by the Free Software
|
---|
14 | * Foundation, in version 2 as it comes in the "COPYING" file of the
|
---|
15 | * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
|
---|
16 | * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
|
---|
17 | */
|
---|
18 |
|
---|
19 | #ifndef __UIMediumTypeChangeDialog_h__
|
---|
20 | #define __UIMediumTypeChangeDialog_h__
|
---|
21 |
|
---|
22 | /* GUI includes: */
|
---|
23 | #include "QIDialog.h"
|
---|
24 | #include "QIWithRetranslateUI.h"
|
---|
25 |
|
---|
26 | /* COM includes: */
|
---|
27 | #include "COMEnums.h"
|
---|
28 | #include "CMedium.h"
|
---|
29 |
|
---|
30 | /* Forward declarations: */
|
---|
31 | class QVBoxLayout;
|
---|
32 | class QILabel;
|
---|
33 | class QGroupBox;
|
---|
34 | class QRadioButton;
|
---|
35 | class QIDialogButtonBox;
|
---|
36 |
|
---|
37 | /* Dialog providing user with possibility to change medium type: */
|
---|
38 | class UIMediumTypeChangeDialog : public QIWithRetranslateUI<QIDialog>
|
---|
39 | {
|
---|
40 | Q_OBJECT;
|
---|
41 |
|
---|
42 | public:
|
---|
43 |
|
---|
44 | /* Constructor: */
|
---|
45 | UIMediumTypeChangeDialog(QWidget *pParent, const QString &strMediumId);
|
---|
46 |
|
---|
47 | protected:
|
---|
48 |
|
---|
49 | /* Translation stuff: */
|
---|
50 | void retranslateUi();
|
---|
51 |
|
---|
52 | protected slots:
|
---|
53 |
|
---|
54 | /* Finisher(s): */
|
---|
55 | void sltAccept();
|
---|
56 | void sltReject();
|
---|
57 |
|
---|
58 | /* Validation stuff: */
|
---|
59 | void sltValidate();
|
---|
60 |
|
---|
61 | private:
|
---|
62 |
|
---|
63 | /* Various helping stuff: */
|
---|
64 | void createMediumTypeButtons();
|
---|
65 | void createMediumTypeButton(KMediumType mediumType);
|
---|
66 |
|
---|
67 | /* Widgets: */
|
---|
68 | QILabel *m_pLabel;
|
---|
69 | QGroupBox *m_pGroupBox;
|
---|
70 | QVBoxLayout *m_pGroupBoxLayout;
|
---|
71 | QIDialogButtonBox *m_pButtonBox;
|
---|
72 |
|
---|
73 | /* Variables: */
|
---|
74 | CMedium m_medium;
|
---|
75 | KMediumType m_oldMediumType;
|
---|
76 | KMediumType m_newMediumType;
|
---|
77 | };
|
---|
78 |
|
---|
79 | #endif // __UIMediumTypeChangeDialog_h__
|
---|