fixed memory leaks (thanks to David for fixing this in KDirOperator)

svn path=/trunk/KDE/kdebase/apps/; revision=746294
This commit is contained in:
Peter Penz 2007-12-08 16:16:45 +00:00
parent fc9a6701da
commit 54dfdc930a
3 changed files with 9 additions and 6 deletions

View file

@ -127,8 +127,9 @@ DolphinColumnWidget::DolphinColumnWidget(QWidget* parent,
DolphinColumnWidget::~DolphinColumnWidget() DolphinColumnWidget::~DolphinColumnWidget()
{ {
delete m_dirLister; delete m_dolphinModel;
m_dirLister = 0; m_dolphinModel = 0;
m_dirLister = 0; // deleted by m_dolphinModel
} }
void DolphinColumnWidget::setDecorationSize(const QSize& size) void DolphinColumnWidget::setDecorationSize(const QSize& size)

View file

@ -158,8 +158,9 @@ DolphinViewContainer::DolphinViewContainer(DolphinMainWindow* mainWindow,
DolphinViewContainer::~DolphinViewContainer() DolphinViewContainer::~DolphinViewContainer()
{ {
delete m_dirLister; delete m_dolphinModel;
m_dirLister = 0; m_dolphinModel = 0;
m_dirLister = 0; // deleted by m_dolphinModel
} }
void DolphinViewContainer::setUrl(const KUrl& url) void DolphinViewContainer::setUrl(const KUrl& url)

View file

@ -48,8 +48,9 @@ TreeViewSidebarPage::TreeViewSidebarPage(QWidget* parent) :
TreeViewSidebarPage::~TreeViewSidebarPage() TreeViewSidebarPage::~TreeViewSidebarPage()
{ {
delete m_dirLister; delete m_dolphinModel;
m_dirLister = 0; m_dolphinModel = 0;
m_dirLister = 0; // deleted by m_dolphinModel
} }
QSize TreeViewSidebarPage::sizeHint() const QSize TreeViewSidebarPage::sizeHint() const