From: Abdelrazak Younes Date: Tue, 9 Oct 2007 09:29:27 +0000 (+0000) Subject: Fix memory leak. X-Git-Tag: 1.6.10~7923 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=17ffac2ae99d52cd5d7914f9d3003a377e56e424;p=lyx.git Fix memory leak. git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20865 a592a061-630c-0410-9148-cb99ea01b6c8 --- diff --git a/src/frontends/qt4/GuiToc.cpp b/src/frontends/qt4/GuiToc.cpp index 13cd95f782..47c67604cb 100644 --- a/src/frontends/qt4/GuiToc.cpp +++ b/src/frontends/qt4/GuiToc.cpp @@ -52,6 +52,12 @@ GuiToc::GuiToc(GuiViewBase & parent, Qt::DockWidgetArea area, Qt::WindowFlags fl } +GuiToc::~GuiToc() +{ + delete widget_; +} + + int GuiToc::getTocDepth(int type) { if (type < 0) diff --git a/src/frontends/qt4/GuiToc.h b/src/frontends/qt4/GuiToc.h index a308f06ade..4c9b6d64fc 100644 --- a/src/frontends/qt4/GuiToc.h +++ b/src/frontends/qt4/GuiToc.h @@ -44,6 +44,8 @@ public: Qt::DockWidgetArea area = Qt::LeftDockWidgetArea, ///< Position of the dock (and also drawer) Qt::WindowFlags flags = 0); + ~GuiToc(); + /// bool initialiseParams(std::string const & data); ///