Commit d9a9e34b authored by Ludovic Fauvet's avatar Ludovic Fauvet

Reordering methods

parent 192dcd6d
......@@ -27,6 +27,24 @@
#include "DockWidgetManager.h"
#include "MainWindow.h"
DockWidgetManager::DockWidgetManager( QObject *parent )
: QObject( parent )
{
QObject::connect( qApp,
SIGNAL( aboutToQuit() ),
this,
SLOT( deleteLater() ) );
}
DockWidgetManager::~DockWidgetManager()
{
QList<QDockWidget*> widgets = m_dockWidgets.values();
QDockWidget* dockWidget;
foreach( dockWidget, widgets )
delete dockWidget;
}
void DockWidgetManager::setMainWindow( MainWindow *mainWin )
{
m_mainWin = mainWin;
......@@ -53,22 +71,3 @@ QDockWidget* DockWidgetManager::addDockedWidget( QWidget *widget,
widget->show();
return dock;
}
DockWidgetManager::DockWidgetManager( QObject *parent )
: QObject( parent )
{
QObject::connect( qApp,
SIGNAL( aboutToQuit() ),
this,
SLOT( deleteLater() ) );
}
DockWidgetManager::~DockWidgetManager()
{
QList<QDockWidget*> widgets = m_dockWidgets.values();
QDockWidget* dockWidget;
foreach( dockWidget, widgets )
delete dockWidget;
}
......@@ -46,9 +46,6 @@ class DockWidgetManager : public QObject, public QSingleton<DockWidgetManager>
QDockWidget::DockWidgetFeature features,
Qt::DockWidgetArea startArea );
protected:
//virtual void changeEvent( QEvent *e );
private:
explicit DockWidgetManager( QObject *parent = 0 );
virtual ~DockWidgetManager();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment