fix warnings and translation strings

This commit is contained in:
Juergen E. Fischer 2017-11-12 21:55:23 +01:00
parent 68da18c0b6
commit 150a64e9ac
2 changed files with 2 additions and 7 deletions

View File

@ -472,14 +472,14 @@ class Grass7Utils(object):
'it before running GRASS GIS 7 algorithms.')
if Grass7Utils.command is None:
return Grass7Utils.tr(
'GRASS GIS 7 binary {0} can\t be found on this system from a shell.'
'GRASS GIS 7 binary {0} can\'t be found on this system from a shell. '
'Please install it or configure your PATH {1} environment variable.'.format(
'(grass.bat)' if isWindows() else '(grass.sh)',
'or OSGEO4W_ROOT' if isWindows() else ''))
# GNU/Linux
else:
return Grass7Utils.tr(
'GRASS 7 can\'t be found on this system from a shell.'
'GRASS 7 can\'t be found on this system from a shell. '
'Please install it or configure your PATH environment variable.')
@staticmethod

View File

@ -451,11 +451,6 @@ QTreeWidgetItem *QgsAttributesFormProperties::loadAttributeEditorTreeItem( QgsAt
void QgsAttributesFormProperties::onAttributeSelectionChanged()
{
bool isAddPossible = false;
if ( mFormLayoutTree->selectedItems().count() == 1 && !mAvailableWidgetsTree->selectedItems().isEmpty() )
if ( mFormLayoutTree->selectedItems()[0]->data( 0, DnDTreeRole ).value<DnDTreeItemData>().type() == DnDTreeItemData::Container )
isAddPossible = true;
storeAttributeTypeDialog();
storeAttributeRelationEdit();