Skip to content
Permalink
Browse files

fix #3021

git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@14266 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
jef
jef committed Sep 20, 2010
1 parent f6237a7 commit 8827efcb3870644460d6bbaaf7bb129fb66573bc
Showing with 5 additions and 1 deletion.
  1. +5 −1 src/app/legend/qgslegend.cpp
@@ -218,8 +218,12 @@ void QgsLegend::mousePressEvent( QMouseEvent * e )
else if ( e->button() == Qt::RightButton )
{
QTreeWidgetItem* item = itemAt( e->pos() );
if ( item == currentItem() )
if ( !item || item == currentItem() )
{
if ( !item )
setCurrentItem( 0 );
handleRightClickEvent( item, e->globalPos() );
}
}
QTreeWidget::mousePressEvent( e );
} // contentsMousePressEvent

0 comments on commit 8827efc

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