Skip to content
Permalink
Browse files

[options search] expand item when found in a tree

  • Loading branch information
3nids committed Feb 6, 2018
1 parent 9389be8 commit 90f1d7b7e7716025ba215f2664aeaab1d199b766
Showing with 2 additions and 1 deletion.
  1. +2 −1 src/gui/qgsoptionsdialoghighlightwidgetsimpl.cpp
@@ -214,13 +214,14 @@ bool QgsOptionsDialogHighlightTree::highlightText( const QString &text )
setChildrenVisible( item, true );

QTreeWidgetItem *parent = item;
while ( ( parent = parent->parent() ) )
while ( parent )
{
if ( mTreeInitialExpand.contains( parent ) )
break;
mTreeInitialExpand.insert( parent, parent->isExpanded() );
parent->setExpanded( true );
parent->setHidden( false );
parent = parent->parent();
}
}
}

0 comments on commit 90f1d7b

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