VirtualBox

source: vbox/trunk/src/VBox/Frontends/VirtualBox/src/VBoxAboutDlg.h@ 103131

Last change on this file since 103131 was 100070, checked in by vboxsync, 18 months ago

FE/Qt: bugref:10450: Cleanup and rework for VBoxAboutDlg stuff; It is necessary to work properly on Qt6.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 2.7 KB
Line 
1/* $Id: VBoxAboutDlg.h 100070 2023-06-05 14:41:33Z vboxsync $ */
2/** @file
3 * VBox Qt GUI - VBoxAboutDlg 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_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 "QIWithRetranslateUI.h"
40#include "UILibraryDefs.h"
41
42/* Forward declarations: */
43class QLabel;
44class QVBoxLayout;
45
46/** QDialog extension
47 * used to show the About-VirtualBox dialog. */
48class SHARED_LIBRARY_STUFF VBoxAboutDlg : public QIWithRetranslateUI2<QDialog>
49{
50 Q_OBJECT;
51
52public:
53
54 /** Constructs dialog passing @a pParent to the base-class.
55 * @param strVersion Brings the version number of VirtualBox. */
56 VBoxAboutDlg(QWidget *pParent, const QString &strVersion);
57
58protected:
59
60 /** Handles show @a pEvent. */
61 virtual void showEvent(QShowEvent *pEvent) RT_OVERRIDE;
62
63 /** Handles paint @a pEvent. */
64 virtual void paintEvent(QPaintEvent *pEvent) RT_OVERRIDE;
65
66 /** Handles translation event. */
67 virtual void retranslateUi() RT_OVERRIDE;
68
69private:
70
71 /** Prepares all. */
72 void prepare();
73 /** Prepares main-layout. */
74 void prepareMainLayout();
75 /** Prepares label. */
76 void prepareLabel();
77 /** Prepares close-button. */
78 void prepareCloseButton();
79
80 /** Holds the pseudo-parent widget reference. */
81 QWidget *m_pPseudoParent;
82
83 /** Holds whether window is polished. */
84 bool m_fPolished;
85
86 /** Holds the About-VirtualBox text. */
87 QString m_strAboutText;
88 /** Holds the VirtualBox version number. */
89 QString m_strVersion;
90
91 /** Holds the About-VirtualBox image. */
92 QPixmap m_pixmap;
93 /** Holds the About-VirtualBox dialog size. */
94 QSize m_size;
95
96 /** Holds About-VirtualBox main-layout instance. */
97 QVBoxLayout *m_pMainLayout;
98 /** Holds About-VirtualBox text-label instance. */
99 QLabel *m_pLabel;
100};
101
102#endif /* !FEQT_INCLUDED_SRC_VBoxAboutDlg_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