[layertree] Add expand/collapse all actions to legend menu

This commit is contained in:
Martin Dobias 2014-05-26 21:21:38 +07:00
parent 62e499e1be
commit 629cd7a873

View File

@ -33,7 +33,9 @@ QMenu* QgsAppLayerTreeViewMenuProvider::createContextMenu()
// global menu
menu->addAction( actions->actionAddGroup( menu ) );
// TODO: expand all, collapse all
menu->addAction( QgsApplication::getThemeIcon( "/mActionExpandTree.png" ), tr( "&Expand All" ), mView, SLOT( expandAll() ) );
menu->addAction( QgsApplication::getThemeIcon( "/mActionCollapseTree.png" ), tr( "&Collapse All" ), mView, SLOT( collapseAll() ) );
// TODO: update drawing order
}
else if ( QgsLayerTreeNode* node = mView->layerTreeModel()->index2node( idx ) )