Changeset 76947 in vbox for trunk/src/VBox/Frontends
- Timestamp:
- Jan 23, 2019 9:26:31 AM (6 years ago)
- svn:sync-xref-src-repo-rev:
- 128324
- Location:
- trunk/src/VBox/Frontends/VirtualBox
- Files:
-
- 7 edited
- 2 moved
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/Makefile.kmk
r76944 r76947 805 805 src/globals/UICustomFileSystemModel.h \ 806 806 src/globals/UIDesktopWidgetWatchdog.h \ 807 src/globals/UIDialogPanel.h \ 807 808 src/globals/UIMainEventListener.h \ 808 809 src/globals/UIMessageCenter.h \ … … 832 833 src/medium/viso/UIVisoContentBrowser.h \ 833 834 src/medium/viso/UIVisoCreator.h \ 834 src/medium/viso/UIVisoCreatorPanel.h \835 835 src/medium/viso/UIVisoConfigurationPanel.h \ 836 836 src/medium/viso/UIVisoCreatorOptionsPanel.h \ … … 1266 1266 src/globals/UIDefs.cpp \ 1267 1267 src/globals/UIDesktopWidgetWatchdog.cpp \ 1268 src/globals/UIDialogPanel.cpp \ 1268 1269 src/globals/UIErrorString.cpp \ 1269 1270 src/globals/UIIconPool.cpp \ … … 1298 1299 src/medium/viso/UIVisoContentBrowser.cpp \ 1299 1300 src/medium/viso/UIVisoCreator.cpp \ 1300 src/medium/viso/UIVisoCreatorPanel.cpp \1301 1301 src/medium/viso/UIVisoConfigurationPanel.cpp \ 1302 1302 src/medium/viso/UIVisoCreatorOptionsPanel.cpp \ -
trunk/src/VBox/Frontends/VirtualBox/src/globals/UIDialogPanel.cpp
r76946 r76947 27 27 #include "QIToolButton.h" 28 28 #include "UIIconPool.h" 29 #include "UI VisoCreatorPanel.h"29 #include "UIDialogPanel.h" 30 30 #ifdef VBOX_WS_MAC 31 31 # include "VBoxUtils-darwin.h" … … 33 33 34 34 35 UI VisoCreatorPanel::UIVisoCreatorPanel(QWidget *pParent)35 UIDialogPanel::UIDialogPanel(QWidget *pParent) 36 36 : QIWithRetranslateUI<QWidget>(pParent) 37 37 , m_pMainLayout(0) … … 41 41 } 42 42 43 void UI VisoCreatorPanel::setCloseButtonShortCut(QKeySequence shortCut)43 void UIDialogPanel::setCloseButtonShortCut(QKeySequence shortCut) 44 44 { 45 45 if (!m_pCloseButton) … … 48 48 } 49 49 50 QHBoxLayout* UI VisoCreatorPanel::mainLayout()50 QHBoxLayout* UIDialogPanel::mainLayout() 51 51 { 52 52 return m_pMainLayout; 53 53 } 54 54 55 void UI VisoCreatorPanel::prepare()55 void UIDialogPanel::prepare() 56 56 { 57 57 prepareWidgets(); … … 60 60 } 61 61 62 void UI VisoCreatorPanel::prepareWidgets()62 void UIDialogPanel::prepareWidgets() 63 63 { 64 64 m_pMainLayout = new QHBoxLayout(this); … … 83 83 } 84 84 85 void UI VisoCreatorPanel::prepareConnections()85 void UIDialogPanel::prepareConnections() 86 86 { 87 87 if (m_pCloseButton) 88 connect(m_pCloseButton, &QIToolButton::clicked, this, &UI VisoCreatorPanel::hide);88 connect(m_pCloseButton, &QIToolButton::clicked, this, &UIDialogPanel::hide); 89 89 } 90 90 91 void UI VisoCreatorPanel::retranslateUi()91 void UIDialogPanel::retranslateUi() 92 92 { 93 93 if (m_pCloseButton) … … 95 95 } 96 96 97 bool UI VisoCreatorPanel::eventFilter(QObject *pObject, QEvent *pEvent)97 bool UIDialogPanel::eventFilter(QObject *pObject, QEvent *pEvent) 98 98 { 99 99 Q_UNUSED(pObject); … … 103 103 } 104 104 105 void UI VisoCreatorPanel::showEvent(QShowEvent *pEvent)105 void UIDialogPanel::showEvent(QShowEvent *pEvent) 106 106 { 107 107 QWidget::showEvent(pEvent); 108 108 } 109 109 110 void UI VisoCreatorPanel::hideEvent(QHideEvent *pEvent)110 void UIDialogPanel::hideEvent(QHideEvent *pEvent) 111 111 { 112 112 /* Get focused widget: */ … … 121 121 } 122 122 123 void UI VisoCreatorPanel::addVerticalSeparator()123 void UIDialogPanel::addVerticalSeparator() 124 124 { 125 125 QFrame *pSeparator = new QFrame(); -
trunk/src/VBox/Frontends/VirtualBox/src/globals/UIDialogPanel.h
r76946 r76947 16 16 */ 17 17 18 #ifndef FEQT_INCLUDED_SRC_ medium_viso_UIVisoCreatorPanel_h19 #define FEQT_INCLUDED_SRC_ medium_viso_UIVisoCreatorPanel_h18 #ifndef FEQT_INCLUDED_SRC_globals_UIDialogPanel_h 19 #define FEQT_INCLUDED_SRC_globals_UIDialogPanel_h 20 20 #ifndef RT_WITHOUT_PRAGMA_ONCE 21 21 # pragma once … … 36 36 37 37 /** QWidget extension acting as the base class for UIVMLogViewerXXXPanel widgets. */ 38 class UI VisoCreatorPanel : public QIWithRetranslateUI<QWidget>38 class UIDialogPanel : public QIWithRetranslateUI<QWidget> 39 39 { 40 40 Q_OBJECT; … … 42 42 public: 43 43 44 UI VisoCreatorPanel(QWidget *pParent);44 UIDialogPanel(QWidget *pParent); 45 45 void setCloseButtonShortCut(QKeySequence shortCut); 46 46 virtual QString panelName() const = 0; … … 48 48 signals: 49 49 50 void sigHidePanel(UI VisoCreatorPanel *pPanel);50 void sigHidePanel(UIDialogPanel *pPanel); 51 51 52 52 protected: … … 77 77 }; 78 78 79 #endif /* !FEQT_INCLUDED_SRC_ medium_viso_UIVisoCreatorPanel_h */79 #endif /* !FEQT_INCLUDED_SRC_globals_UIDialogPanel_h */ -
trunk/src/VBox/Frontends/VirtualBox/src/medium/viso/UIVisoConfigurationPanel.cpp
r76944 r76947 35 35 36 36 UIVisoConfigurationPanel::UIVisoConfigurationPanel(QWidget *pParent /* =0 */) 37 : UI VisoCreatorPanel(pParent)37 : UIDialogPanel(pParent) 38 38 , m_pVisoNameLabel(0) 39 39 , m_pCustomOptionsLabel(0) … … 137 137 } 138 138 /* Call to base-class: */ 139 return UI VisoCreatorPanel::eventFilter(pObject, pEvent);139 return UIDialogPanel::eventFilter(pObject, pEvent); 140 140 } 141 141 -
trunk/src/VBox/Frontends/VirtualBox/src/medium/viso/UIVisoConfigurationPanel.h
r76945 r76947 23 23 24 24 /* GUI includes: */ 25 #include "UI VisoCreatorPanel.h"25 #include "UIDialogPanel.h" 26 26 27 27 /* Forward declarations: */ … … 35 35 class UIVisoCreator; 36 36 37 class UIVisoConfigurationPanel : public UI VisoCreatorPanel37 class UIVisoConfigurationPanel : public UIDialogPanel 38 38 { 39 39 Q_OBJECT; -
trunk/src/VBox/Frontends/VirtualBox/src/medium/viso/UIVisoCreator.cpp
r76946 r76947 113 113 if (!pSenderAction) 114 114 return; 115 UI VisoCreatorPanel* pPanel = 0;115 UIDialogPanel* pPanel = 0; 116 116 /* Look for the sender() within the m_panelActionMap's values: */ 117 for (QMap<UI VisoCreatorPanel*, QAction*>::const_iterator iterator = m_panelActionMap.begin();117 for (QMap<UIDialogPanel*, QAction*>::const_iterator iterator = m_panelActionMap.begin(); 118 118 iterator != m_panelActionMap.end(); ++iterator) 119 119 { … … 153 153 } 154 154 155 void UIVisoCreator::sltHandleHidePanel(UI VisoCreatorPanel *pPanel)155 void UIVisoCreator::sltHandleHidePanel(UIDialogPanel *pPanel) 156 156 { 157 157 hidePanel(pPanel); … … 312 312 313 313 314 void UIVisoCreator::hidePanel(UI VisoCreatorPanel* panel)314 void UIVisoCreator::hidePanel(UIDialogPanel* panel) 315 315 { 316 316 if (panel && panel->isVisible()) 317 317 panel->setVisible(false); 318 QMap<UI VisoCreatorPanel*, QAction*>::iterator iterator = m_panelActionMap.find(panel);318 QMap<UIDialogPanel*, QAction*>::iterator iterator = m_panelActionMap.find(panel); 319 319 if (iterator != m_panelActionMap.end()) 320 320 { … … 326 326 } 327 327 328 void UIVisoCreator::showPanel(UI VisoCreatorPanel* panel)328 void UIVisoCreator::showPanel(UIDialogPanel* panel) 329 329 { 330 330 if (panel && panel->isHidden()) 331 331 panel->setVisible(true); 332 QMap<UI VisoCreatorPanel*, QAction*>::iterator iterator = m_panelActionMap.find(panel);332 QMap<UIDialogPanel*, QAction*>::iterator iterator = m_panelActionMap.find(panel); 333 333 if (iterator != m_panelActionMap.end()) 334 334 { -
trunk/src/VBox/Frontends/VirtualBox/src/medium/viso/UIVisoCreator.h
r76945 r76947 41 41 class QIDialogButtonBox; 42 42 class UIActionPool; 43 class UIDialogPanel; 43 44 class UIToolBar; 44 45 class UIVisoHostBrowser; 45 46 class UIVisoContentBrowser; 46 47 class UIVisoCreatorOptionsPanel; 47 class UIVisoCreatorPanel;48 48 class UIVisoConfigurationPanel; 49 49 … … 76 76 void sltHandleCustomVisoOptionsChanged(const QStringList &customVisoOptions); 77 77 void sltHandleShowHiddenObjectsChange(bool fShow); 78 void sltHandleHidePanel(UI VisoCreatorPanel *pPanel);78 void sltHandleHidePanel(UIDialogPanel *pPanel); 79 79 80 80 private: … … 101 101 void setTableRootIndex(QModelIndex index = QModelIndex() ); 102 102 void setTreeCurrentIndex(QModelIndex index = QModelIndex() ); 103 void hidePanel(UI VisoCreatorPanel *panel);104 void showPanel(UI VisoCreatorPanel *panel);103 void hidePanel(UIDialogPanel *panel); 104 void showPanel(UIDialogPanel *panel); 105 105 /** Makes sure escape key is assigned to only a single widget. This is done by checking 106 106 several things in the following order: … … 127 127 UIVisoCreatorOptionsPanel *m_pCreatorOptionsPanel; 128 128 UIVisoConfigurationPanel *m_pConfigurationPanel; 129 QMap<UI VisoCreatorPanel*, QAction*> m_panelActionMap;130 QList<UI VisoCreatorPanel*> m_visiblePanelsList;129 QMap<UIDialogPanel*, QAction*> m_panelActionMap; 130 QList<UIDialogPanel*> m_visiblePanelsList; 131 131 }; 132 132 -
trunk/src/VBox/Frontends/VirtualBox/src/medium/viso/UIVisoCreatorOptionsPanel.cpp
r76944 r76947 32 32 33 33 UIVisoCreatorOptionsPanel::UIVisoCreatorOptionsPanel(QWidget *pParent /* =0 */) 34 : UI VisoCreatorPanel(pParent)34 : UIDialogPanel(pParent) 35 35 , m_pShowHiddenObjectsCheckBox(0) 36 36 , m_pShowHiddenObjectsLabel(0) -
trunk/src/VBox/Frontends/VirtualBox/src/medium/viso/UIVisoCreatorOptionsPanel.h
r76945 r76947 27 27 28 28 /* GUI includes: */ 29 #include "UI VisoCreatorPanel.h"29 #include "UIDialogPanel.h" 30 30 #include "QIWithRetranslateUI.h" 31 31 32 class UIVisoCreatorOptionsPanel : public UI VisoCreatorPanel32 class UIVisoCreatorOptionsPanel : public UIDialogPanel 33 33 { 34 34 Q_OBJECT;
Note:
See TracChangeset
for help on using the changeset viewer.