Index: /trunk/src/VBox/Frontends/VirtualBox/src/manager/UIToolbarTools.cpp
===================================================================
--- /trunk/src/VBox/Frontends/VirtualBox/src/manager/UIToolbarTools.cpp	(revision 73551)
+++ /trunk/src/VBox/Frontends/VirtualBox/src/manager/UIToolbarTools.cpp	(revision 73552)
@@ -34,7 +34,4 @@
 # include "UIToolbarTools.h"
 
-/* Other VBox includes: */
-# include "iprt/assert.h"
-
 #endif /* !VBOX_WITH_PRECOMPILED_HEADERS */
 
@@ -46,33 +43,18 @@
     , m_pTabBarGlobal(0)
     , m_pLayoutMain(0)
-    , m_pToolBar(0)
-{
-    /* Prepare: */
+{
     prepare();
 }
 
-void UIToolbarTools::setTabBars(UITabBar *pTabBarMachine, UITabBar *pTabBarGlobal)
-{
-    /* Remember the new tab-bars: */
-    m_pTabBarMachine = pTabBarMachine;
-    m_pTabBarGlobal = pTabBarGlobal;
-
-    /* Configure tab-bar connections: */
-    connect(m_pTabBarMachine, &UITabBar::sigTabRequestForClosing,
-            this, &UIToolbarTools::sltHandleCloseToolMachine);
-    connect(m_pTabBarMachine, &UITabBar::sigCurrentTabChanged,
-            this, &UIToolbarTools::sltHandleToolChosenMachine);
-    connect(m_pTabBarGlobal, &UITabBar::sigTabRequestForClosing,
-            this, &UIToolbarTools::sltHandleCloseToolGlobal);
-    connect(m_pTabBarGlobal, &UITabBar::sigCurrentTabChanged,
-            this, &UIToolbarTools::sltHandleToolChosenGlobal);
-
-    /* Let the tab-bars know our opinion: */
-    sltHandleActionToggle();
-}
-
-void UIToolbarTools::setToolButtonStyle(Qt::ToolButtonStyle enmStyle)
-{
-    m_pToolBar->setToolButtonStyle(enmStyle);
+void UIToolbarTools::setTabBarEnabledMachine(bool fEnabled)
+{
+    /* Update Machine tab-bar availability: */
+    m_pTabBarMachine->setEnabled(fEnabled);
+}
+
+void UIToolbarTools::setTabBarEnabledGlobal(bool fEnabled)
+{
+    /* Update Global tab-bar availability: */
+    m_pTabBarGlobal->setEnabled(fEnabled);
 }
 
@@ -185,7 +167,17 @@
     /* Handle known actions: */
     if (m_pActionPool->action(UIActionIndexST_M_Tools_T_Machine)->isChecked())
-        emit sigShowTabBarMachine();
+    {
+        if (m_pTabBarGlobal)
+            m_pTabBarGlobal->setVisible(false);
+        if (m_pTabBarMachine)
+            m_pTabBarMachine->setVisible(true);
+    }
     else if (m_pActionPool->action(UIActionIndexST_M_Tools_T_Global)->isChecked())
-        emit sigShowTabBarGlobal();
+    {
+        if (m_pTabBarMachine)
+            m_pTabBarMachine->setVisible(false);
+        if (m_pTabBarGlobal)
+            m_pTabBarGlobal->setVisible(true);
+    }
 }
 
@@ -205,5 +197,5 @@
     /* Configure 'Machine' menu: */
     UIMenu *pMenuMachine = m_pActionPool->action(UIActionIndexST_M_Tools_M_Machine)->menu();
-    AssertPtrReturnVoid(pMenuMachine);
+    if (pMenuMachine)
     {
         /* Add 'Details' action: */
@@ -236,5 +228,5 @@
     /* Configure 'Global' menu: */
     UIMenu *pMenuGlobal = m_pActionPool->action(UIActionIndexST_M_Tools_M_Global)->menu();
-    AssertPtrReturnVoid(pMenuGlobal);
+    if (pMenuGlobal)
     {
         /* Add 'Virtual Media Manager' action: */
@@ -266,26 +258,38 @@
     /* Create main layout: */
     m_pLayoutMain = new QHBoxLayout(this);
-    AssertPtrReturnVoid(m_pLayoutMain);
+    if (m_pLayoutMain)
     {
         /* Configure layout: */
         m_pLayoutMain->setContentsMargins(0, 0, 0, 0);
 
-        /* Create toolbar: */
-        m_pToolBar = new UIToolBar;
-        AssertPtrReturnVoid(m_pToolBar);
+        /* Create Machine tab-bar: */
+        m_pTabBarMachine = new UITabBar(UITabBar::Align_Left);
+        if (m_pTabBarMachine)
         {
-            /* Configure toolbar: */
-            const int iIconMetric = QApplication::style()->pixelMetric(QStyle::PM_LargeIconSize);
-            m_pToolBar->setIconSize(QSize(iIconMetric, iIconMetric));
-            m_pToolBar->setToolButtonStyle(Qt::ToolButtonTextUnderIcon);
-
-            /* Add actions: */
-            m_pToolBar->addAction(m_pActionPool->action(UIActionIndexST_M_Tools_T_Machine));
-            m_pToolBar->addAction(m_pActionPool->action(UIActionIndexST_M_Tools_T_Global));
+            connect(m_pTabBarMachine, &UITabBar::sigTabRequestForClosing,
+                    this, &UIToolbarTools::sltHandleCloseToolMachine);
+            connect(m_pTabBarMachine, &UITabBar::sigCurrentTabChanged,
+                    this, &UIToolbarTools::sltHandleToolChosenMachine);
 
             /* Add into layout: */
-            m_pLayoutMain->addWidget(m_pToolBar);
+            m_pLayoutMain->addWidget(m_pTabBarMachine);
         }
-    }
-}
-
+
+        /* Create Global tab-bar: */
+        m_pTabBarGlobal = new UITabBar(UITabBar::Align_Left);
+        if (m_pTabBarGlobal)
+        {
+            /* Configure tab-bar connections: */
+            connect(m_pTabBarGlobal, &UITabBar::sigTabRequestForClosing,
+                    this, &UIToolbarTools::sltHandleCloseToolGlobal);
+            connect(m_pTabBarGlobal, &UITabBar::sigCurrentTabChanged,
+                    this, &UIToolbarTools::sltHandleToolChosenGlobal);
+
+            /* Add into layout: */
+            m_pLayoutMain->addWidget(m_pTabBarGlobal);
+        }
+
+        /* Let the tab-bars know our opinion: */
+        sltHandleActionToggle();
+    }
+}
Index: /trunk/src/VBox/Frontends/VirtualBox/src/manager/UIToolbarTools.h
===================================================================
--- /trunk/src/VBox/Frontends/VirtualBox/src/manager/UIToolbarTools.h	(revision 73551)
+++ /trunk/src/VBox/Frontends/VirtualBox/src/manager/UIToolbarTools.h	(revision 73552)
@@ -45,9 +45,4 @@
 signals:
 
-    /** Notifies listeners about Machine tab-bar should be shown. */
-    void sigShowTabBarMachine();
-    /** Notifies listeners about Global tab-bar should be shown. */
-    void sigShowTabBarGlobal();
-
     /** Notifies listeners about Machine tool of particular @a enmType opened. */
     void sigToolOpenedMachine(const ToolTypeMachine enmType);
@@ -66,9 +61,8 @@
     UIToolbarTools(UIActionPool *pActionPool, QWidget *pParent = 0);
 
-    /** Defines the tab-bars to control. */
-    void setTabBars(UITabBar *pTabBarMachine, UITabBar *pTabBarGlobal);
-
-    /** Defines toolbar tool button @a enmStyle. */
-    void setToolButtonStyle(Qt::ToolButtonStyle enmStyle);
+    /** Defines whether Machine tab-bar is @a fEnabled. */
+    void setTabBarEnabledMachine(bool fEnabled);
+    /** Defines whether Global tab-bar is @a fEnabled. */
+    void setTabBarEnabledGlobal(bool fEnabled);
 
     /** Returns Machine tab-bar order. */
@@ -109,13 +103,10 @@
     UIActionPool *m_pActionPool;
 
-    /** Holds the Machine tab-bar instance. */
-    UITabBar *m_pTabBarMachine;
-    /** Holds the Global tab-bar instance. */
-    UITabBar *m_pTabBarGlobal;
-
     /** Holds the main layout instance. */
     QHBoxLayout *m_pLayoutMain;
-    /** Holds the toolbar instance. */
-    UIToolBar   *m_pToolBar;
+    /** Holds the Machine tab-bar instance. */
+    UITabBar    *m_pTabBarMachine;
+    /** Holds the Global tab-bar instance. */
+    UITabBar    *m_pTabBarGlobal;
 
     /** Holds the map of opened Machine tool IDs. */
Index: /trunk/src/VBox/Frontends/VirtualBox/src/manager/UIVirtualBoxManagerWidget.cpp
===================================================================
--- /trunk/src/VBox/Frontends/VirtualBox/src/manager/UIVirtualBoxManagerWidget.cpp	(revision 73551)
+++ /trunk/src/VBox/Frontends/VirtualBox/src/manager/UIVirtualBoxManagerWidget.cpp	(revision 73552)
@@ -51,6 +51,4 @@
     , m_pSplitter(0)
     , m_pToolBar(0)
-    , m_pTabBarMachine(0)
-    , m_pTabBarGlobal(0)
     , m_pToolbarTools(0)
     , m_pPaneChooser(0)
@@ -142,7 +140,4 @@
                                        ? Qt::ToolButtonTextUnderIcon
                                        : Qt::ToolButtonIconOnly);
-        m_pToolbarTools->setToolButtonStyle(  pResult->isChecked()
-                                            ? Qt::ToolButtonTextUnderIcon
-                                            : Qt::ToolButtonIconOnly);
     }
 }
@@ -221,6 +216,6 @@
     m_pPaneToolsMachine->setCurrentItem(pItem);
 
-    /* Update Machine tab-bar visibility */
-    m_pTabBarMachine->setEnabled(pItem && pItem->accessible());
+    /* Update Machine tab-bar availability: */
+    m_pToolbarTools->setTabBarEnabledMachine(pItem && pItem->accessible());
 
     /* If current item exists & accessible: */
@@ -287,16 +282,4 @@
     /* Make sure chosen item fetched: */
     sltHandleChooserPaneIndexChange(false /* update details? */, false /* update snapshots? */, false /* update the logviewer? */);
-}
-
-void UIVirtualBoxManagerWidget::sltHandleShowTabBarMachine()
-{
-    m_pTabBarGlobal->setVisible(false);
-    m_pTabBarMachine->setVisible(true);
-}
-
-void UIVirtualBoxManagerWidget::sltHandleShowTabBarGlobal()
-{
-    m_pTabBarMachine->setVisible(false);
-    m_pTabBarGlobal->setVisible(true);
 }
 
@@ -446,20 +429,4 @@
                     pLayoutRight->addWidget(m_pToolBar);
 
-                    /* Create Machine tab-bar: */
-                    m_pTabBarMachine = new UITabBar(UITabBar::Align_Left);
-                    if (m_pTabBarMachine)
-                    {
-                        /* Add into toolbar: */
-                        pLayoutRight->addWidget(m_pTabBarMachine);
-                    }
-
-                    /* Create Global tab-bar: */
-                    m_pTabBarGlobal = new UITabBar(UITabBar::Align_Left);
-                    if (m_pTabBarGlobal)
-                    {
-                        /* Add into toolbar: */
-                        pLayoutRight->addWidget(m_pTabBarGlobal);
-                    }
-
                     /* Create Tools toolbar: */
                     m_pToolbarTools = new UIToolbarTools(actionPool());
@@ -468,24 +435,7 @@
                         /* Configure toolbar: */
                         m_pToolbarTools->setSizePolicy(QSizePolicy::Fixed, QSizePolicy::MinimumExpanding);
-                        connect(m_pToolbarTools, &UIToolbarTools::sigShowTabBarMachine,
-                                this, &UIVirtualBoxManagerWidget::sltHandleShowTabBarMachine);
-                        connect(m_pToolbarTools, &UIToolbarTools::sigShowTabBarGlobal,
-                                this, &UIVirtualBoxManagerWidget::sltHandleShowTabBarGlobal);
-                        m_pToolbarTools->setTabBars(m_pTabBarMachine, m_pTabBarGlobal);
-
-                        /* Create exclusive action-group: */
-                        QActionGroup *pActionGroupTools = new QActionGroup(m_pToolbarTools);
-                        if (pActionGroupTools)
-                        {
-                            /* Configure action-group: */
-                            pActionGroupTools->setExclusive(true);
-
-                            /* Add 'Tools' actions into action-group: */
-                            pActionGroupTools->addAction(actionPool()->action(UIActionIndexST_M_Tools_T_Machine));
-                            pActionGroupTools->addAction(actionPool()->action(UIActionIndexST_M_Tools_T_Global));
-                        }
-
-                        /* Add into toolbar: */
-                        m_pToolBar->addWidget(m_pToolbarTools);
+
+                        /* Add into layout: */
+                        pLayoutRight->addWidget(m_pToolbarTools);
                     }
 
@@ -583,8 +533,7 @@
     /* Restore toolbar settings: */
     {
-        m_pToolBar->setToolButtonStyle(gEDataManager->selectorWindowToolBarTextVisible()
-                                       ? Qt::ToolButtonTextUnderIcon : Qt::ToolButtonIconOnly);
-        m_pToolbarTools->setToolButtonStyle(gEDataManager->selectorWindowToolBarTextVisible()
-                                            ? Qt::ToolButtonTextUnderIcon : Qt::ToolButtonIconOnly);
+        m_pToolBar->setToolButtonStyle(  gEDataManager->selectorWindowToolBarTextVisible()
+                                       ? Qt::ToolButtonTextUnderIcon
+                                       : Qt::ToolButtonIconOnly);
     }
 
Index: /trunk/src/VBox/Frontends/VirtualBox/src/manager/UIVirtualBoxManagerWidget.h
===================================================================
--- /trunk/src/VBox/Frontends/VirtualBox/src/manager/UIVirtualBoxManagerWidget.h	(revision 73551)
+++ /trunk/src/VBox/Frontends/VirtualBox/src/manager/UIVirtualBoxManagerWidget.h	(revision 73552)
@@ -134,9 +134,4 @@
         void sltHandleToolsTypeSwitch();
 
-        /** Handles request to show Machine tab-bar. */
-        void sltHandleShowTabBarMachine();
-        /** Handles request to show Global tab-bar. */
-        void sltHandleShowTabBarGlobal();
-
         /** Handles rquest to open Machine tool of passed @a enmType. */
         void sltHandleToolOpenedMachine(ToolTypeMachine enmType);
@@ -186,9 +181,4 @@
     UIToolBar *m_pToolBar;
 
-    /** Holds the Machine tab-bar instance. */
-    UITabBar *m_pTabBarMachine;
-    /** Holds the Global tab-bar instance. */
-    UITabBar *m_pTabBarGlobal;
-
     /** Holds the Tools-toolbar instance. */
     UIToolbarTools *m_pToolbarTools;
