all: less QScopedPointer

Change-Id: I536bdb4d4f0c10fa858560f3c160fc0fff8da9b2
Reviewed-on: http://codereview.qt-project.org/5116
Reviewed-by: hjk <qthjk@ovi.com>
This commit is contained in:
hjk
2011-09-16 15:00:41 +02:00
committed by hjk
parent dbe1653775
commit 58cb19e55e
59 changed files with 123 additions and 125 deletions

View File

@@ -159,8 +159,8 @@ FutureProgress::FutureProgress(QWidget *parent) :
connect(&d->m_watcher, SIGNAL(finished()), this, SLOT(setFinished()));
connect(&d->m_watcher, SIGNAL(progressRangeChanged(int,int)), this, SLOT(setProgressRange(int,int)));
connect(&d->m_watcher, SIGNAL(progressValueChanged(int)), this, SLOT(setProgressValue(int)));
connect(&d->m_watcher, SIGNAL(progressTextChanged(const QString&)),
this, SLOT(setProgressText(const QString&)));
connect(&d->m_watcher, SIGNAL(progressTextChanged(QString)),
this, SLOT(setProgressText(QString)));
connect(d->m_progress, SIGNAL(clicked()), this, SLOT(cancel()));
}
@@ -170,8 +170,8 @@ FutureProgress::FutureProgress(QWidget *parent) :
*/
FutureProgress::~FutureProgress()
{
if (d->m_widget)
delete d->m_widget;
delete d->m_widget;
delete d;
}
/*!
@@ -182,8 +182,7 @@ FutureProgress::~FutureProgress()
*/
void FutureProgress::setWidget(QWidget *widget)
{
if (d->m_widget)
delete d->m_widget;
delete d->m_widget;
QSizePolicy sp = widget->sizePolicy();
sp.setHorizontalPolicy(QSizePolicy::Ignored);
widget->setSizePolicy(sp);