Showing with 7 additions and 6 deletions.
  1. +2 −3 src/gui/qgsexpressionbuilderdialog.cpp
  2. +5 −3 src/gui/qgsexpressionbuilderdialog.h
5 changes: 2 additions & 3 deletions src/gui/qgsexpressionbuilderdialog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -47,11 +47,10 @@ QString QgsExpressionBuilderDialog::expressionText()
return builder->expressionText();
}

void QgsExpressionBuilderDialog::closeEvent( QCloseEvent *event )
void QgsExpressionBuilderDialog::done( int r )
{
QDialog::closeEvent( event );
QDialog::done( r );

// TODO Work out why this is not working yet.
QSettings settings;
settings.setValue( "/Windows/ExpressionBuilderDialog/geometry", saveGeometry() );
}
Expand Down
8 changes: 5 additions & 3 deletions src/gui/qgsexpressionbuilderdialog.h
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,12 @@ class GUI_EXPORT QgsExpressionBuilderDialog : public QDialog, private Ui::QgsExp

protected:
/**
* Handle closing of the window
* @param event unused
* Is called when the dialog get accepted or rejected
* Used to save geometry
*
* @param r result value (unused)
*/
void closeEvent( QCloseEvent * event );
virtual void done( int r );
};

#endif