commit 832b99a3949d3efc63a7e8a95cbcb9eb994c75c1
Author: Guillaume Munch <[email protected]>
Date:   Sat Dec 31 15:16:15 2016 +0100

    Remove a redundant deletion of a QObject
---
 src/frontends/qt4/GuiToc.cpp |   11 +++--------
 src/frontends/qt4/GuiToc.h   |    2 --
 2 files changed, 3 insertions(+), 10 deletions(-)

diff --git a/src/frontends/qt4/GuiToc.cpp b/src/frontends/qt4/GuiToc.cpp
index 29ec85c..e124a46 100644
--- a/src/frontends/qt4/GuiToc.cpp
+++ b/src/frontends/qt4/GuiToc.cpp
@@ -33,20 +33,15 @@ namespace lyx {
 namespace frontend {
 
 GuiToc::GuiToc(GuiView & parent, Qt::DockWidgetArea area, Qt::WindowFlags 
flags)
-       : DockView(parent, "toc", qt_("Outline"), area, flags), 
is_closing_(false)
+       : DockView(parent, "toc", qt_("Outline"), area, flags),
+         widget_(new TocWidget(parent, this)),
+         is_closing_(false)
 {
-       widget_ = new TocWidget(parent, this);
        setWidget(widget_);
        setFocusProxy(widget_);
 }
 
 
-GuiToc::~GuiToc()
-{
-       delete widget_;
-}
-
-
 void GuiToc::updateView()
 {
        widget_->updateView();
diff --git a/src/frontends/qt4/GuiToc.h b/src/frontends/qt4/GuiToc.h
index 6c7db9d..d403bc9 100644
--- a/src/frontends/qt4/GuiToc.h
+++ b/src/frontends/qt4/GuiToc.h
@@ -34,8 +34,6 @@ public:
                Qt::DockWidgetArea area = Qt::LeftDockWidgetArea, ///< Position 
of the dock (and also drawer)
                Qt::WindowFlags flags = 0);
 
-       ~GuiToc();
-
        ///
        bool initialiseParams(std::string const & data);
        void updateView();

Reply via email to