Janitor : Avoid use of smart pointer on a QObject

This commit is contained in:
Magne Sjaastad
2019-12-04 13:04:44 +01:00
parent df55c5f6dc
commit 87fecb876f
2 changed files with 3 additions and 5 deletions

View File

@@ -36,7 +36,7 @@
RicSummaryCurveCreatorDialog::RicSummaryCurveCreatorDialog( QWidget* parent )
: QDialog( parent, RiuTools::defaultDialogFlags() )
{
m_curveCreatorSplitterUi.reset( new RicSummaryCurveCreatorSplitterUi( this ) );
m_curveCreatorSplitterUi = new RicSummaryCurveCreatorSplitterUi( this );
QWidget* propertyWidget = m_curveCreatorSplitterUi->getOrCreateWidget( this );
@@ -46,7 +46,7 @@ RicSummaryCurveCreatorDialog::RicSummaryCurveCreatorDialog( QWidget* parent )
setWindowTitle( "Plot Editor" );
resize( 1200, 800 );
connect( m_curveCreatorSplitterUi.get(), SIGNAL( signalCloseButtonPressed() ), this, SLOT( accept() ) );
connect( m_curveCreatorSplitterUi, SIGNAL( signalCloseButtonPressed() ), this, SLOT( accept() ) );
connect( this, SIGNAL( finished( int ) ), this, SLOT( slotDialogFinished() ) );
}

View File

@@ -20,8 +20,6 @@
#include <QDialog>
#include <memory>
namespace caf
{
class PdmObject;
@@ -49,5 +47,5 @@ private slots:
void slotDialogFinished();
private:
std::unique_ptr<RicSummaryCurveCreatorSplitterUi> m_curveCreatorSplitterUi;
RicSummaryCurveCreatorSplitterUi* m_curveCreatorSplitterUi;
};