1 | /* $Id: VBoxAboutDlg.h 106061 2024-09-16 14:03:52Z vboxsync $ */
|
---|
2 | /** @file
|
---|
3 | * VBox Qt GUI - VBoxAboutDlg class declaration.
|
---|
4 | */
|
---|
5 |
|
---|
6 | /*
|
---|
7 | * Copyright (C) 2006-2024 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_VBoxAboutDlg_h
|
---|
29 | #define FEQT_INCLUDED_SRC_VBoxAboutDlg_h
|
---|
30 | #ifndef RT_WITHOUT_PRAGMA_ONCE
|
---|
31 | # pragma once
|
---|
32 | #endif
|
---|
33 |
|
---|
34 | /* Qt includes: */
|
---|
35 | #include <QDialog>
|
---|
36 | #include <QPixmap>
|
---|
37 |
|
---|
38 | /* GUI includes: */
|
---|
39 | #include "UILibraryDefs.h"
|
---|
40 |
|
---|
41 | /* Forward declarations: */
|
---|
42 | class QLabel;
|
---|
43 | class QVBoxLayout;
|
---|
44 |
|
---|
45 | /** QDialog extension
|
---|
46 | * used to show the About-VirtualBox dialog. */
|
---|
47 | class SHARED_LIBRARY_STUFF VBoxAboutDlg : public QDialog
|
---|
48 | {
|
---|
49 | Q_OBJECT;
|
---|
50 |
|
---|
51 | public:
|
---|
52 |
|
---|
53 | /** Constructs dialog passing @a pParent to the base-class.
|
---|
54 | * @param strVersion Brings the version number of VirtualBox. */
|
---|
55 | VBoxAboutDlg(QWidget *pParent, const QString &strVersion);
|
---|
56 |
|
---|
57 | protected:
|
---|
58 |
|
---|
59 | /** Handles show @a pEvent. */
|
---|
60 | virtual void showEvent(QShowEvent *pEvent) RT_OVERRIDE;
|
---|
61 |
|
---|
62 | /** Handles paint @a pEvent. */
|
---|
63 | virtual void paintEvent(QPaintEvent *pEvent) RT_OVERRIDE;
|
---|
64 |
|
---|
65 | private slots:
|
---|
66 |
|
---|
67 | /** Handles translation event. */
|
---|
68 | void sltRetranslateUI();
|
---|
69 |
|
---|
70 | private:
|
---|
71 |
|
---|
72 | /** Prepares all. */
|
---|
73 | void prepare();
|
---|
74 | /** Prepares main-layout. */
|
---|
75 | void prepareMainLayout();
|
---|
76 | /** Prepares label. */
|
---|
77 | void prepareLabel();
|
---|
78 | /** Prepares close-button. */
|
---|
79 | void prepareCloseButton();
|
---|
80 |
|
---|
81 | /** Holds the pseudo-parent widget reference. */
|
---|
82 | QWidget *m_pPseudoParent;
|
---|
83 |
|
---|
84 | /** Holds whether window is polished. */
|
---|
85 | bool m_fPolished;
|
---|
86 |
|
---|
87 | /** Holds the About-VirtualBox text. */
|
---|
88 | QString m_strAboutText;
|
---|
89 | /** Holds the VirtualBox version number. */
|
---|
90 | QString m_strVersion;
|
---|
91 |
|
---|
92 | /** Holds the About-VirtualBox image. */
|
---|
93 | QPixmap m_pixmap;
|
---|
94 | /** Holds the About-VirtualBox dialog size. */
|
---|
95 | QSize m_size;
|
---|
96 |
|
---|
97 | /** Holds About-VirtualBox main-layout instance. */
|
---|
98 | QVBoxLayout *m_pMainLayout;
|
---|
99 | /** Holds About-VirtualBox text-label instance. */
|
---|
100 | QLabel *m_pLabel;
|
---|
101 | };
|
---|
102 |
|
---|
103 | #endif /* !FEQT_INCLUDED_SRC_VBoxAboutDlg_h */
|
---|