29 cboFileOptions->addItem( tr(
"Function file" ) );
30 cboFileOptions->addItem( tr(
"Project functions" ), QStringLiteral(
"project" ) );
33 if ( !enableProjectFunctions )
35 QStandardItem *item = qobject_cast<QStandardItemModel *>( cboFileOptions->model() )->item( 1 );
36 item->setFlags( item->flags() & ~Qt::ItemIsEnabled );
39 connect( cboFileOptions, qOverload<int>( &QComboBox::currentIndexChanged ),
this, &QgsExpressionAddFunctionFileDialog::cboFileOptions_currentIndexChanged );
40 connect( txtNewFileName, &QLineEdit::textChanged,
this, [
this](
const QString & ) { updateOkButtonStatus(); } );
41 connect( buttonBox, &QDialogButtonBox::helpRequested,
this, [] {
42 QgsHelp::openHelp( QStringLiteral(
"expressions/expression.html#function-editor" ) );
45 updateOkButtonStatus();