Skip to content
Permalink
Browse files

[processing] Destroy widgets from an algorithm dialog as soon as it i…

…s rejected
  • Loading branch information
gacarrillor authored and nyalldawson committed Mar 18, 2020
1 parent 576c2f3 commit 8a7feeddbb8ce3b0b85fc71101c718e4586db1d4
@@ -182,6 +182,9 @@ Copies the current log contents to the clipboard.
Switches the dialog to the parameters page.
%End

virtual void reject();


protected:

virtual void closeEvent( QCloseEvent *e );
@@ -662,6 +662,15 @@ void QgsProcessingAlgorithmDialogBase::setInfo( const QString &message, bool isE
processEvents();
}

void QgsProcessingAlgorithmDialogBase::reject()
{
if ( !mAlgorithmTask )
{
setAttribute( Qt::WA_DeleteOnClose );
}
QDialog::reject();
}

//
// QgsProcessingAlgorithmProgressDialog
//
@@ -230,6 +230,8 @@ class GUI_EXPORT QgsProcessingAlgorithmDialogBase : public QDialog, public QgsPr
*/
void showParameters();

void reject() override;

protected:

void closeEvent( QCloseEvent *e ) override;

0 comments on commit 8a7feed

Please sign in to comment.
You can’t perform that action at this time.