VirtualBox

source: vbox/trunk/src/VBox/Frontends/VirtualBox/src/widgets/UIPaneContainer.h@ 103977

Last change on this file since 103977 was 103923, checked in by vboxsync, 9 months ago

FE/Qt. bugref:10622. Using new UITranslationEventListener in log viewer classes.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 2.2 KB
Line 
1/* $Id: UIPaneContainer.h 103923 2024-03-19 17:01:11Z vboxsync $ */
2/** @file
3 * VBox Qt GUI - UIVMLogViewer class declaration.
4 */
5
6/*
7 * Copyright (C) 2010-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_widgets_UIPaneContainer_h
29#define FEQT_INCLUDED_SRC_widgets_UIPaneContainer_h
30#ifndef RT_WITHOUT_PRAGMA_ONCE
31# pragma once
32#endif
33
34/* Qt includes: */
35#include <QWidget>
36#include <QKeySequence>
37
38/* GUI includes: */
39#include "QIManagerDialog.h"
40
41/* Forward declarations: */
42class QAbstractButton;
43class QHBoxLayout;
44class QIDialogButtonBox;
45
46/** QWidget extension acting as the base class for all the dialog panels like file manager, logviewer etc. */
47class SHARED_LIBRARY_STUFF UIPaneContainer : public QWidget
48{
49 Q_OBJECT;
50
51signals:
52
53 void sigCurrentTabChanged(int iIndex);
54 void sigHidden();
55 void sigDetach();
56
57public:
58
59 UIPaneContainer(QWidget *pParent, EmbedTo enmEmbedTo = EmbedTo_Stack, bool fDetachAllowed = false);
60 void setCurrentIndex(int iIndex);
61 int currentIndex() const;
62
63protected:
64
65 virtual void prepare();
66 void insertTab(int iIndex, QWidget *pPage, const QString &strLabel = QString());
67 void setTabText(int iIndex, const QString &strText);
68
69private slots:
70
71 void sltHide();
72 void sltHandleButtonBoxClick(QAbstractButton *pButton);
73 void sltRetranslateUI();
74
75private:
76
77 EmbedTo m_enmEmbedTo;
78 bool m_fDetachAllowed;
79
80 QTabWidget *m_pTabWidget;
81
82 QIDialogButtonBox *m_pButtonBox;
83};
84
85#endif /* !FEQT_INCLUDED_SRC_widgets_UIPaneContainer_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