Skip to content

Commit

Permalink
only handle context menu event if showing tree widget
Browse files Browse the repository at this point in the history
  • Loading branch information
etiennesky committed May 20, 2014
1 parent 06c0bd2 commit 7d535b4
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/app/qgsidentifyresultsdialog.cpp
Expand Up @@ -905,6 +905,11 @@ void QgsIdentifyResultsDialog::itemClicked( QTreeWidgetItem *item, int column )
void QgsIdentifyResultsDialog::contextMenuEvent( QContextMenuEvent* event )
{
QgsDebugMsg( "Entered" );

// only handle context menu event if showing tree widget
if ( tabWidget->currentIndex() != 0 )
return;

QTreeWidgetItem *item = lstResults->itemAt( lstResults->viewport()->mapFrom( this, event->pos() ) );
// if the user clicked below the end of the attribute list, just return
if ( !item )
Expand Down

0 comments on commit 7d535b4

Please sign in to comment.