Skip to content
Permalink
Browse files

Only set tooltip if text is not empty

  • Loading branch information
m-kuhn committed Mar 12, 2020
1 parent 23f8640 commit 3b941e4be880515fd85fea10ce8fd561bc2f9ab5
Showing with 2 additions and 1 deletion.
  1. +2 −1 src/gui/editorwidgets/qgsvaluerelationwidgetwrapper.cpp
@@ -365,7 +365,8 @@ void QgsValueRelationWidgetWrapper::populate( )
for ( const QgsValueRelationFieldFormatter::ValueRelationItem &element : qgis::as_const( mCache ) )
{
whileBlocking( mComboBox )->addItem( element.value, element.key );
mComboBox->setItemData( mComboBox->count() - 1, element.description, Qt::ToolTipRole );
if ( !element.description.isEmpty() )
mComboBox->setItemData( mComboBox->count() - 1, element.description, Qt::ToolTipRole );
}

}

0 comments on commit 3b941e4

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