VirtualBox

source: vbox/trunk/src/VBox/Frontends/VirtualBox/src/wizards/exportappliance/UIWizardExportAppPageVMs.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.5 KB
Line 
1/* $Id: UIWizardExportAppPageVMs.h 103982 2024-03-21 11:43:53Z vboxsync $ */
2/** @file
3 * VBox Qt GUI - UIWizardExportAppPageVMs class declaration.
4 */
5
6/*
7 * Copyright (C) 2009-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_exportappliance_UIWizardExportAppPageVMs_h
29#define FEQT_INCLUDED_SRC_wizards_exportappliance_UIWizardExportAppPageVMs_h
30#ifndef RT_WITHOUT_PRAGMA_ONCE
31# pragma once
32#endif
33
34/* Qt includes */
35#include <QUuid>
36
37/* GUI includes: */
38#include "UINativeWizardPage.h"
39
40/* Forward declarations: */
41class QListWidget;
42class QIRichTextLabel;
43class UIWizardExportApp;
44
45/** Namespace for VMs page of the Export Appliance wizard. */
46namespace UIWizardExportAppVMs
47{
48 /** Populates @a pVMSelector with items on the basis of passed @a selectedVMNames. */
49 void populateVMItems(QListWidget *pVMSelector, const QStringList &selectedVMNames);
50
51 /** Refresh a list of saved machines selected in @a pVMSelector. */
52 void refreshSavedMachines(QStringList &savedMachines, QListWidget *pVMSelector);
53
54 /** Returns a list of machine names selected in @a pVMSelector. */
55 QStringList machineNames(QListWidget *pVMSelector);
56 /** Returns a list of machine IDs selected in @a pVMSelector. */
57 QList<QUuid> machineIDs(QListWidget *pVMSelector);
58}
59
60/** UINativeWizardPage extension for VMs page of the Export Appliance wizard,
61 * based on UIWizardExportAppVMs namespace functions. */
62class UIWizardExportAppPageVMs : public UINativeWizardPage
63{
64 Q_OBJECT;
65
66public:
67
68 /** Constructs VMs page.
69 * @param selectedVMNames Brings the list of selected VM names.
70 * @param fFastTravelToNextPage Brings whether we should fast-travel to next page. */
71 UIWizardExportAppPageVMs(const QStringList &selectedVMNames, bool fFastTravelToNextPage);
72
73protected:
74
75 /** Returns wizard this page belongs to. */
76 UIWizardExportApp *wizard() const;
77
78 /** Performs page initialization. */
79 virtual void initializePage() RT_OVERRIDE RT_FINAL;
80
81 /** Returns whether page is complete. */
82 virtual bool isComplete() const RT_OVERRIDE RT_FINAL;
83
84 /** Performs page validation. */
85 virtual bool validatePage() RT_OVERRIDE RT_FINAL;
86
87private slots:
88
89 /** Handles VM item selection change. */
90 void sltHandleVMItemSelectionChanged();
91 /** Handles translation event. */
92 virtual void sltRetranslateUI() RT_OVERRIDE RT_FINAL;
93
94private:
95
96 /** Holds the list of selected VM names. */
97 const QStringList m_selectedVMNames;
98 /** Holds whether we should fast travel to next page. */
99 bool m_fFastTravelToNextPage;
100
101 /** Holds the main label instance. */
102 QIRichTextLabel *m_pLabelMain;
103
104 /** Holds the VM selector instance. */
105 QListWidget *m_pVMSelector;
106};
107
108#endif /* !FEQT_INCLUDED_SRC_wizards_exportappliance_UIWizardExportAppPageVMs_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