Index: /trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerBookmarksPanel.cpp
===================================================================
--- /trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerBookmarksPanel.cpp	(revision 76953)
+++ /trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerBookmarksPanel.cpp	(revision 76954)
@@ -84,4 +84,9 @@
 }
 
+QString UIVMLogViewerBookmarksPanel::panelName() const
+{
+    return "FilterPanel";
+}
+
 void UIVMLogViewerBookmarksPanel::setBookmarkIndex(int index)
 {
Index: /trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerBookmarksPanel.h
===================================================================
--- /trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerBookmarksPanel.h	(revision 76953)
+++ /trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerBookmarksPanel.h	(revision 76954)
@@ -36,10 +36,4 @@
     Q_OBJECT;
 
-signals:
-
-    void sigDeleteBookmark(int bookmarkIndex);
-    void sigDeleteAllBookmarks();
-    void sigBookmarkSelected(int index);
-
 public:
 
@@ -55,6 +49,10 @@
     /** Disable/enable all the widget except the close button */
     void disableEnableBookmarking(bool flag);
+    virtual QString panelName() const /* override */;
+signals:
 
-public slots:
+    void sigDeleteBookmark(int bookmarkIndex);
+    void sigDeleteAllBookmarks();
+    void sigBookmarkSelected(int index);
 
 protected:
Index: /trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerFilterPanel.cpp
===================================================================
--- /trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerFilterPanel.cpp	(revision 76953)
+++ /trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerFilterPanel.cpp	(revision 76954)
@@ -259,4 +259,9 @@
 }
 
+QString UIVMLogViewerFilterPanel::panelName() const
+{
+    return "FilterPanel";
+}
+
 void UIVMLogViewerFilterPanel::applyFilter(const int iCurrentIndex /* = 0 */)
 {
Index: /trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerFilterPanel.h
===================================================================
--- /trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerFilterPanel.h	(revision 76953)
+++ /trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerFilterPanel.h	(revision 76954)
@@ -57,4 +57,5 @@
       * @param  pViewer  Specifies reference to the VM Log-Viewer this filter-panel belongs to. */
     UIVMLogViewerFilterPanel(QWidget *pParent, UIVMLogViewerWidget *pViewer);
+    virtual QString panelName() const /* override */;
 
 public slots:
@@ -113,3 +114,2 @@
 
 #endif /* !FEQT_INCLUDED_SRC_logviewer_UIVMLogViewerFilterPanel_h */
-
Index: /trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerOptionsPanel.cpp
===================================================================
--- /trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerOptionsPanel.cpp	(revision 76953)
+++ /trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerOptionsPanel.cpp	(revision 76954)
@@ -70,4 +70,9 @@
         return;
     m_pFontSizeSpinBox->setValue(fontSizeInPoints);
+}
+
+QString UIVMLogViewerOptionsPanel::panelName() const
+{
+    return "OptionsPanel";
 }
 
Index: /trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerOptionsPanel.h
===================================================================
--- /trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerOptionsPanel.h	(revision 76953)
+++ /trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerOptionsPanel.h	(revision 76954)
@@ -52,4 +52,5 @@
     void setWrapLines(bool bWrapLines);
     void setFontSizeInPoints(int fontSizeInPoints);
+    virtual QString panelName() const /* override */;
 
 public slots:
Index: /trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerPanel.cpp
===================================================================
--- /trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerPanel.cpp	(revision 76953)
+++ /trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerPanel.cpp	(revision 76954)
@@ -36,17 +36,11 @@
 
 UIVMLogViewerPanel::UIVMLogViewerPanel(QWidget *pParent, UIVMLogViewerWidget *pViewer)
-    : QIWithRetranslateUI<QWidget>(pParent)
+    : UIDialogPanel(pParent)
     , m_pViewer(pViewer)
-    , m_pMainLayout(0)
-    , m_pCloseButton(0)
 {
-    prepare();
 }
 
-void UIVMLogViewerPanel::setCloseButtonShortCut(QKeySequence shortCut)
+void UIVMLogViewerPanel::retranslateUi()
 {
-    if (!m_pCloseButton)
-        return;
-    m_pCloseButton->setShortcut(shortCut);
 }
 
@@ -59,78 +53,4 @@
 {
     return m_pViewer;
-}
-
-QHBoxLayout* UIVMLogViewerPanel::mainLayout()
-{
-    return m_pMainLayout;
-}
-
-void UIVMLogViewerPanel::prepare()
-{
-    prepareWidgets();
-    prepareConnections();
-    retranslateUi();
-}
-
-void UIVMLogViewerPanel::prepareWidgets()
-{
-    m_pMainLayout = new QHBoxLayout(this);
-    if (m_pMainLayout)
-    {
-#ifdef VBOX_WS_MAC
-        m_pMainLayout->setContentsMargins(5 /* since there is always a button */, 0, 10 /* standard */, 0);
-        m_pMainLayout->setSpacing(10);
-#else
-        m_pMainLayout->setContentsMargins(qApp->style()->pixelMetric(QStyle::PM_LayoutLeftMargin) / 2, 0,
-                                          qApp->style()->pixelMetric(QStyle::PM_LayoutRightMargin) / 2,
-                                          qApp->style()->pixelMetric(QStyle::PM_LayoutBottomMargin) / 2);
-        m_pMainLayout->setSpacing(qApp->style()->pixelMetric(QStyle::PM_LayoutHorizontalSpacing));
-#endif
-    }
-    m_pCloseButton = new QIToolButton;
-    if (m_pCloseButton)
-    {
-        m_pCloseButton->setIcon(UIIconPool::iconSet(":/close_16px.png"));
-        m_pMainLayout->addWidget(m_pCloseButton, 0, Qt::AlignLeft);
-    }
-}
-
-void UIVMLogViewerPanel::prepareConnections()
-{
-    if (m_pCloseButton)
-        connect(m_pCloseButton, &QIToolButton::clicked, this, &UIVMLogViewerPanel::hide);
-}
-
-void UIVMLogViewerPanel::retranslateUi()
-{
-    if (m_pCloseButton)
-        m_pCloseButton->setToolTip(UIVMLogViewerWidget::tr("Close the pane"));
-}
-
-bool UIVMLogViewerPanel::eventFilter(QObject *pObject, QEvent *pEvent)
-{
-    Q_UNUSED(pObject);
-    Q_UNUSED(pEvent);
-    /* Dont consume this event. Pass it back to Qt's event system: */
-    return false;
-}
-
-void UIVMLogViewerPanel::showEvent(QShowEvent *pEvent)
-{
-    QWidget::showEvent(pEvent);
-}
-
-void UIVMLogViewerPanel::hideEvent(QHideEvent *pEvent)
-{
-    /* Get focused widget: */
-    QWidget *pFocus = QApplication::focusWidget();
-    /* If focus-widget is valid and child-widget of search-panel,
-     * focus next child-widget in line: */
-    if (pFocus && pFocus->parent() == this)
-        focusNextPrevChild(true);
-    if (m_pViewer)
-        m_pViewer->hidePanel(this);
-
-    QWidget::hideEvent(pEvent);
 }
 
@@ -162,3 +82,2 @@
     return &(page->logString());
 }
-
Index: /trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerPanel.h
===================================================================
--- /trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerPanel.h	(revision 76953)
+++ /trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerPanel.h	(revision 76954)
@@ -23,19 +23,17 @@
 
 /* Qt includes: */
-#include <QWidget>
 #include <QKeySequence>
+
 /* GUI includes: */
-#include "QIWithRetranslateUI.h"
+#include "UIDialogPanel.h"
 
 /* Forward declarations: */
-class QHBoxLayout;
 class QPlainTextEdit;
 class QTextDocument;
-class QIToolButton;
 class UIVMLogViewerWidget;
 
 
-/** QWidget extension acting as the base class for UIVMLogViewerXXXPanel widgets. */
-class UIVMLogViewerPanel : public QIWithRetranslateUI<QWidget>
+/** UIDialonPanel extension acting as the base class for UIVMLogViewerXXXPanel widgets. */
+class UIVMLogViewerPanel : public UIDialogPanel
 {
     Q_OBJECT;
@@ -44,31 +42,16 @@
 
     UIVMLogViewerPanel(QWidget *pParent, UIVMLogViewerWidget *pViewer);
-    void setCloseButtonShortCut(QKeySequence shortCut);
 
 protected:
 
-    virtual void prepare();
-    virtual void prepareWidgets();
-    virtual void prepareConnections();
+    virtual void retranslateUi() /* override */;
 
     /* Access functions for children classes. */
-    UIVMLogViewerWidget*       viewer();
-    const UIVMLogViewerWidget* viewer() const;
-    QHBoxLayout*               mainLayout();
-
-    /** Handles the translation event. */
-    void retranslateUi() /* override */;
-
-    /** Handles Qt @a pEvent, used for keyboard processing. */
-    bool eventFilter(QObject *pObject, QEvent *pEvent);
-    /** Handles the Qt show @a pEvent. */
-    void showEvent(QShowEvent *pEvent);
-    /** Handles the Qt hide @a pEvent. */
-    void hideEvent(QHideEvent *pEvent);
-
+    UIVMLogViewerWidget        *viewer();
+    const UIVMLogViewerWidget  *viewer() const;
     QTextDocument  *textDocument();
     QPlainTextEdit *textEdit();
     /* Return the unmodified log. */
-    const QString* logString() const;
+    const QString *logString() const;
 
 private:
@@ -76,6 +59,4 @@
     /** Holds the reference to VM Log-Viewer this panel belongs to. */
     UIVMLogViewerWidget *m_pViewer;
-    QHBoxLayout         *m_pMainLayout;
-    QIToolButton        *m_pCloseButton;
 };
 
Index: /trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerSearchPanel.cpp
===================================================================
--- /trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerSearchPanel.cpp	(revision 76953)
+++ /trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerSearchPanel.cpp	(revision 76954)
@@ -108,4 +108,9 @@
 {
     return m_matchLocationVector;
+}
+
+QString UIVMLogViewerSearchPanel::panelName() const
+{
+    return "SearchPanel";
 }
 
@@ -612,3 +617,2 @@
 
 #include "UIVMLogViewerSearchPanel.moc"
-
Index: /trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerSearchPanel.h
===================================================================
--- /trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerSearchPanel.h	(revision 76953)
+++ /trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerSearchPanel.h	(revision 76954)
@@ -56,4 +56,5 @@
     void reset();
     const QVector<float> &getMatchLocationVector() const;
+    virtual QString panelName() const /* override */;
 
 protected:
@@ -131,3 +132,2 @@
 
 #endif /* !FEQT_INCLUDED_SRC_logviewer_UIVMLogViewerSearchPanel_h */
-
