Skip to content

Commit

Permalink
Add docs and indentation
Browse files Browse the repository at this point in the history
  • Loading branch information
stev-0 committed Dec 23, 2019
1 parent 7554408 commit 7226d34
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 1 deletion.
1 change: 1 addition & 0 deletions src/gui/editorwidgets/qgstexteditwrapper.cpp
Expand Up @@ -295,6 +295,7 @@ void QgsTextEditWrapper::setWidgetValue( const QVariant &val )
}
}
else if ( val.type() == QVariant::Double && std::isnan( val.toDouble() ) )
{
v = QgsApplication::nullRepresentation();
}
else
Expand Down
6 changes: 6 additions & 0 deletions src/gui/editorwidgets/qgstexteditwrapper.h
Expand Up @@ -59,6 +59,12 @@ class GUI_EXPORT QgsTextEditWrapper : public QgsEditorWidgetWrapper
public:
QVariant value() const override;
void showIndeterminateState() override;


/**
* Returns whether the text edit widget contains Invalid JSON
* \since QGIS 3.12
*/
bool isInvalidJSON();

/**
Expand Down
3 changes: 2 additions & 1 deletion src/gui/qgsfieldvalidator.cpp
Expand Up @@ -154,7 +154,8 @@ QValidator::State QgsFieldValidator::validate( QString &s, int &i ) const
{
return QDate::fromString( s, mDateFormat ).isValid() ? Acceptable : Intermediate;
}
else if ( mField.type() == QVariant::Map ) {
else if ( mField.type() == QVariant::Map )
{
return Acceptable;
}
else
Expand Down

0 comments on commit 7226d34

Please sign in to comment.